Index: libexec/rtld-elf/mips/rtld_start.S =================================================================== --- libexec/rtld-elf/mips/rtld_start.S +++ libexec/rtld-elf/mips/rtld_start.S @@ -193,7 +193,6 @@ move t9, v0 jr t9 nop - .cfi_endproc END(_rtld_bind_start) @@ -285,5 +284,4 @@ move t9, v0 jr t9 nop - .cfi_endproc END(_rtld_pltbind_start) Index: sys/mips/include/asm.h =================================================================== --- sys/mips/include/asm.h +++ sys/mips/include/asm.h @@ -136,11 +136,15 @@ .globl sym; sym: #define ENTRY(sym) \ - .text; .globl sym; .ent sym; sym: + .text; .globl sym; .ent sym; sym: .cfi_startproc; #define ASM_ENTRY(sym) \ .text; .globl sym; .type sym,@function; sym: + +#define _FRAME_STACK_REG sp +#define _FRAME_RETURN_REG ra + /* * LEAF * A leaf routine does @@ -152,7 +156,8 @@ .globl _C_LABEL(x); \ .ent _C_LABEL(x), 0; \ _C_LABEL(x): ; \ - .frame sp, 0, ra; \ + .frame _FRAME_STACK_REG, 0, _FRAME_RETURN_REG; \ + .cfi_startproc; \ MCOUNT /* @@ -163,7 +168,8 @@ .globl _C_LABEL(x); \ .ent _C_LABEL(x), 0; \ _C_LABEL(x): ; \ - .frame sp, 0, ra + .frame _FRAME_STACK_REG, 0, _FRAME_RETURN_REG; \ + .cfi_startproc /* * XLEAF @@ -183,7 +189,8 @@ .globl _C_LABEL(x); \ .ent _C_LABEL(x), 0; \ _C_LABEL(x): ; \ - .frame sp, fsize, retpc; \ + .frame _FRAME_STACK_REG, fsize, retpc; \ + .cfi_startproc; \ MCOUNT /* @@ -194,7 +201,8 @@ .globl _C_LABEL(x); \ .ent _C_LABEL(x), 0; \ _C_LABEL(x): ; \ - .frame sp, fsize, retpc + .frame _FRAME_STACK_REG, fsize, retpc; \ + .cfi_startproc /* * XNESTED @@ -209,7 +217,8 @@ * END * Mark end of a procedure. */ -#define END(x) \ +#define END(x) \ + .cfi_endproc; \ .end _C_LABEL(x) /* @@ -233,6 +242,7 @@ #define VECTOR(x, regmask) \ .ent _C_LABEL(x),0; \ EXPORT(x); \ + .cfi_startproc #define VECTOR_END(x) \ EXPORT(x ## End); \ @@ -256,9 +266,9 @@ MSG(msg) #define MSG(msg) \ - .rdata; \ + .pushsection .rodata; \ 9: .asciiz msg; \ - .text + .popsection #define ASMSTR(str) \ .asciiz str; \