https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110188
--- Comment #6 from jzhgonha at 163 dot com --- thank you very much! 发自我的小米在 "kito at gcc dot gnu.org" <gcc-bugzi...@gcc.gnu.org>,2023年6月9日 下午9:51写道: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110188 Kito Cheng <kito at gcc dot gnu.org[1]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kito at gcc dot gnu.org[1] --- Comment #5 from Kito Cheng <kito at gcc dot gnu.org[1]> --- Each stack area will align to 16 byte, that could be optimized in theory, but will complicate the frame layout implementation. ----sp - 0 a9 / outgoing stack arguments area ----sp - 4 <unused> / outgoing stack arguments area ----sp - 8 <unused> / outgoing stack arguments area ----sp - 12 <unused> / outgoing stack arguments area ----sp - 16 <unused> / GPR save area ----sp - 20 <unused> / GPR save area ----sp - 24 <unused> / GPR save area ----sp - 28 ra / GPR save area ----sp - 32 Complete layout has document in riscv.cc[2]: +-------------------------------+ | | | incoming stack arguments | | | +-------------------------------+ <-- incoming stack pointer | | | callee-allocated save area | | for arguments that are | | split between registers and | | the stack | | | +-------------------------------+ <-- arg_pointer_rtx | | | callee-allocated save area | | for register varargs | | | +-------------------------------+ <-- hard_frame_pointer_rtx; | | stack_pointer_rtx + gp_sp_offset | GPR save area | + UNITS_PER_WORD | | +-------------------------------+ <-- stack_pointer_rtx + fp_sp_offset | | + UNITS_PER_HWVALUE | FPR save area | | | +-------------------------------+ <-- frame_pointer_rtx (virtual) | | | local variables | | | P +-------------------------------+ | | | outgoing stack arguments | | | +-------------------------------+ <-- stack_pointer_rtx -- You are receiving this mail because: You reported the bug. 1. http://gnu.org 2. http://riscv.cc