[RISCV] Add a test case to show the bug in RISCVFrameLowering.
If the number of arguments is too large to use register passing, it needs to occupy stack space to pass the arguments to the callee. There are two scenarios. One is to reserve the space in prologue and the other is to reserve the space before the function calls. When we need to reserve the stack space before function calls, the stack pointer is adjusted. Under the scenario, we should not use stack pointer to access the stack objects. It looks like, callseq_start -> sp = sp - reserved_space // // We should not use SP to access stack objects in this area. // call @foo callseq_end -> sp = sp + reserved_space Differential Revision: https://reviews.llvm.org/D114245
Loading
Please register or sign in to comment