X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Fx86-64-assem.S;h=c4f543593fb90962f45082443d01800888c78c98;hb=d94c1b4a8c534bde146823f56558faf37cd4c4d7;hp=ac420108843e9d42c27b2502f69fdf129c64236e;hpb=9184392783512f76eb971b7e316c875e2a1eb94c;p=sbcl.git diff --git a/src/runtime/x86-64-assem.S b/src/runtime/x86-64-assem.S index ac42010..c4f5435 100644 --- a/src/runtime/x86-64-assem.S +++ b/src/runtime/x86-64-assem.S @@ -67,7 +67,7 @@ * for this instruction in the SIGILL handler and if we see it, we * advance the EIP by two bytes to skip over ud2 instruction and * call sigtrap_handler. */ -#if defined(LISP_FEATURE_DARWIN) +#if defined(LISP_FEATURE_UD2_BREAKPOINTS) #define TRAP ud2 #else #define TRAP int3 @@ -194,7 +194,7 @@ Lstack: xor %rdx,%rdx # clear any descriptor registers xor %rdi,%rdi # that we can't be sure we'll xor %rsi,%rsi # initialise properly. XX do r8-r15 too? - shl $3,%rcx # (fixnumize num-args) + shl $(N_FIXNUM_TAG_BITS),%rcx # (fixnumize num-args) cmp $0,%rcx je Ldone mov 0(%rbx),%rdx # arg0 @@ -266,6 +266,7 @@ GNAME(fpu_restore): .globl GNAME(undefined_tramp) TYPE(GNAME(undefined_tramp)) GNAME(undefined_tramp): + pop 8(%rbp) # Save return PC for backtrace. TRAP .byte trap_Error .byte 2 @@ -343,6 +344,12 @@ GNAME(closure_tramp): /* * fun-end breakpoint magic */ + +/* + * For an explanation of the magic involved in function-end + * breakpoints, see the implementation in ppc-assem.S. + */ + .text .globl GNAME(fun_end_breakpoint_guts) .align align_16byte