Skip to content

Commit deeb975

Browse files
committed
Fix CFI macro definitions in aarch64 assembly for Linux
The CFI macros were expanding to themselves instead of actual .cfi_* directives, causing assembly errors on Linux. Fixed to expand to proper directives.
1 parent d16342e commit deeb975

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

stackman/platforms/switch_aarch64_gcc.S

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,11 @@
2929
#define TYPE_FUNCTION(name) .type name, %function
3030
#define SIZE_FUNCTION(name) .size name, .-name
3131
#define GNU_STACK .section .note.GNU-stack,"",@progbits
32-
#define CFI_STARTPROC CFI_STARTPROC
33-
#define CFI_ENDPROC CFI_ENDPROC
34-
#define CFI_DEF_CFA_OFFSET(x) CFI_DEF_CFA_OFFSET()x
32+
#define CFI_STARTPROC .cfi_startproc
33+
#define CFI_ENDPROC .cfi_endproc
34+
#define CFI_DEF_CFA_OFFSET(x) .cfi_def_cfa_offset x
3535
#define CFI_OFFSET(r,o) .cfi_offset r, o
36-
#define CFI_RESTORE(r) CFI_RESTORE()r
36+
#define CFI_RESTORE(r) .cfi_restore r
3737
#endif
3838

3939
.arch armv8-a

0 commit comments

Comments
 (0)