https://sourceware.org/bugzilla/show_bug.cgi?id=33756
--- Comment #1 from Sourceware Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Indu Bhagat <[email protected]>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=1674e47227965dbf85c5fee59b0858afd191284c commit 1674e47227965dbf85c5fee59b0858afd191284c Author: Indu Bhagat <[email protected]> Date: Thu Jan 8 12:11:17 2026 -0800 gas: sframe: fix PR gas/33756 Previously, sframe_xlate_do_remember_state () relied exclusively on last_fre (the last Frame Row Entry for the previous PC range block). At the start of a function (before an advance in location), last_fre is NULL. The intent of DW_CFA_remember_state, however, is to simply snapshot the state of the call frame information at the time. In terms of SFrame generation, this means that we should simply look at cur_fre (the scratchpad FRE currently being built from initial CFI instructions in the current context). Remove the common-empty-1.s which assumed that .cfi_startproc, immediately followed by a .cfi_remember_state is not present out in the wild. Its best to not make such an assumption, as such a sequence is valid CFI, FWIW. Initial CFI are arch-specific, so add a new testcase for x86_64 to check .cfi_remember_state handling for SFrame is sensible. While at at, also add a new testcase for s390x. Co-Authored-by: Jens Remus <[email protected]> Reviewed-by: Jens Remus <[email protected]> gas/ PR gas/33756 * gen-sframe.c (sframe_xlate_do_remember_state): Use cur_fre. gas/testsuite/ * gas/cfi-sframe/cfi-sframe.exp: Adjust common-empty-1 test to be repurposed as cfi-sframe-x86_64-pr33756. Add s390x testcase. * gas/cfi-sframe/common-empty-1.d: Removed. * gas/cfi-sframe/common-empty-1.s: Removed. * gas/cfi-sframe/cfi-sframe-x86_64-pr33756.d: New test. * gas/cfi-sframe/cfi-sframe-x86_64-pr33756.s: New test. * gas/cfi-sframe/cfi-sframe-s390x-pr33756.d: New test. * gas/cfi-sframe/cfi-sframe-s390x-pr33756.s: New test. -- You are receiving this mail because: You are on the CC list for the bug.
