base/asm-common.h: Provide default frame pointer registers.
[catacomb] / base / asm-common.h
index 3560ec5..1dfb633 100644 (file)
@@ -453,7 +453,7 @@ name:
 #define WHOLE(reg) _REGFORM(reg, r)
 
 // Stack management and unwinding.
-.macro setfp   fp, offset=0
+.macro setfp   fp=R_bp(r), offset=0
   .if \offset == 0
        mov     \fp, R_sp(r)
 #if __ELF__
@@ -989,7 +989,7 @@ name:
 #define QQ(qlo, qhi) D0(qlo)-D1(qhi)
 
 // Stack management and unwinding.
-.macro setfp   fp, offset=0
+.macro setfp   fp=r11, offset=0
   .if \offset == 0
        mov     \fp, sp
          .setfp \fp, sp
@@ -1074,7 +1074,7 @@ name:
 .endm
 
 // Stack management and unwinding.
-.macro setfp   fp, offset=0
+.macro setfp   fp=x29, offset=0
   // If you're just going through the motions with a fixed-size stack frame,
   // then you want to say `add x29, sp, #OFFSET' directly, which will avoid
   // pointlessly restoring sp later.