1.0.10.48: new function TRY-RESTART
[sbcl.git] / src / compiler / late-vmdef.lisp
blob708ec0ea1ed4cacf49024107fcf7482e069b01d8
1 ;;;; a few things from the classic CMU CL "src/compiler/vmdef.lisp"
2 ;;;; file which couldn't be compiled early
4 ;;;; This software is part of the SBCL system. See the README file for
5 ;;;; more information.
6 ;;;;
7 ;;;; This software is derived from the CMU CL system, which was
8 ;;;; written at Carnegie Mellon University and released into the
9 ;;;; public domain. The software is in the public domain and is
10 ;;;; provided with absolutely no warranty. See the COPYING and CREDITS
11 ;;;; files for more information.
13 (in-package "SB!C")
15 (defun note-this-location (vop kind)
16 #!+sb-doc
17 "NOTE-THIS-LOCATION VOP Kind
18 Note that the current code location is an interesting (to the debugger)
19 location of the specified Kind. VOP is the VOP responsible for this code.
20 This VOP must specify some non-null :SAVE-P value (perhaps :COMPUTE-ONLY) so
21 that the live set is computed."
22 (let ((lab (gen-label)))
23 (emit-label lab)
24 (note-debug-location vop lab kind)))
26 (defun note-next-instruction (vop kind)
27 #!+sb-doc
28 "NOTE-NEXT-INSTRUCTION VOP Kind
29 Similar to NOTE-THIS-LOCATION, except the use the location of the next
30 instruction for the code location, wherever the scheduler decided to put
31 it."
32 (let ((loc (note-debug-location vop nil kind)))
33 (sb!assem:emit-postit (lambda (segment posn)
34 (declare (ignore segment))
35 (setf (location-info-label loc) posn))))
36 (values))