diff --git a/compiler/generic/new-genesis.lisp b/compiler/generic/new-genesis.lisp index 0f92646a82854ba1f722bf871116b2ca5f7155e0..f520af075a9815b4f463b6a417531527ae7a67a2 100644 --- a/compiler/generic/new-genesis.lisp +++ b/compiler/generic/new-genesis.lisp @@ -4,7 +4,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/generic/new-genesis.lisp,v 1.81 2008/09/12 21:02:56 rtoy Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/generic/new-genesis.lisp,v 1.82 2008/09/12 21:09:07 rtoy Exp $") ;;; ;;; ********************************************************************** ;;; @@ -2443,6 +2443,16 @@ (format t "#define ~A ~D~@[ /* ~A */~]~%" (first const) (third const) (fourth const)))))) + ;; Write out the values of real-lra-slot and friend for breakpoint + ;; handling so we don't have to maintain it in the C code. + + (format t "~%#define REAL_LRA_SLOT ~D~%" + (- di::real-lra-slot vm::code-constants-offset)) + (format t "#define KNOWN_RETURN_P_SLOT ~D~%" + (- di::known-return-p-slot vm::code-constants-offset)) + (format t "#define BOGUS_LRA_CONSTANTS ~D~%" + di::bogus-lra-constants vm::code-constants-offset) + ;; Write out internal error codes and error descriptions (terpri) (loop for (error-name . rest) across (c:backend-internal-errors c:*backend*) diff --git a/lisp/breakpoint.c b/lisp/breakpoint.c index 153b1040724356716a5147c720980faf535a51f8..bd9025df6939c360d3561c7d709c1a194f2be778 100644 --- a/lisp/breakpoint.c +++ b/lisp/breakpoint.c @@ -1,6 +1,6 @@ /* - $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/breakpoint.c,v 1.25 2008/09/10 13:46:43 rtoy Exp $ + $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/breakpoint.c,v 1.26 2008/09/12 21:09:07 rtoy Rel $ This code was written as part of the CMU Common Lisp project at Carnegie Mellon University, and has been placed in the public domain. @@ -26,19 +26,29 @@ /* * See MAKE-BOGUS-LRA in code/debug-int.lisp for these values. * - * Note: In debug-int.lisp, real-lra-slot and known-return-p-slot are - * offsets from the start of the code object. But in the C code here, - * it is the offset from the constants vector in the code object. The - * difference between the two is vm:code-constants-offset. + * Ideally, internals.h should have the correct values. We leave + * these defaults here for now. */ +#ifndef REAL_LRA_SLOT #define REAL_LRA_SLOT 0 +#endif + +#ifndef KNOWN_RETURN_P_SLOT #ifndef i386 #define KNOWN_RETURN_P_SLOT 1 -#define BOGUS_LRA_CONSTANTS 2 #else #define KNOWN_RETURN_P_SLOT 2 +#endif +#endif + +#ifndef BOGUS_LRA_CONSTANTS +#ifndef i386 +#define BOGUS_LRA_CONSTANTS 2 +#else #define BOGUS_LRA_CONSTANTS 3 #endif +#endif + static void * compute_pc(lispobj code_obj, int pc_offset)