[movitz-cvs] CVS movitz

ffjeld ffjeld at common-lisp.net
Mon Feb 4 08:33:41 UTC 2008


Update of /project/movitz/cvsroot/movitz
In directory clnet:/tmp/cvs-serv24213

Modified Files:
	asm.lisp 
Log Message:
Add support for incoming-symtab.


--- /project/movitz/cvsroot/movitz/asm.lisp	2008/02/04 07:45:08	1.7
+++ /project/movitz/cvsroot/movitz/asm.lisp	2008/02/04 08:33:39	1.8
@@ -6,7 +6,7 @@
 ;;;; Author:        Frode Vatvedt Fjeld <frodef at acm.org>
 ;;;; Distribution:  See the accompanying file COPYING.
 ;;;;                
-;;;; $Id: asm.lisp,v 1.7 2008/02/04 07:45:08 ffjeld Exp $
+;;;; $Id: asm.lisp,v 1.8 2008/02/04 08:33:39 ffjeld Exp $
 ;;;;                
 ;;;;------------------------------------------------------------------
 
@@ -102,11 +102,11 @@
 ;;;;;;;;;;;;
 
 
-(defun proglist-encode (proglist &key corrections (start-pc 0) (cpu-package '#:asm-x86))
+(defun proglist-encode (proglist &key ((:symtab incoming-symtab) *symtab*) corrections (start-pc 0) (cpu-package '#:asm-x86))
   "Encode a proglist, using instruction-encoder in symbol encode-instruction from cpu-package."
   (let ((encoder (find-symbol (string '#:encode-instruction) cpu-package))
 	(*pc* start-pc)
-	(*symtab* corrections)
+	(*symtab* (append incoming-symtab corrections))
 	(assumptions nil)
 	(new-corrections nil)
 	(sub-programs nil))
@@ -186,11 +186,13 @@
 		 finally
 		 (cond
 		   ((not (null assumptions))
+		    (warn "prg: ~{~%~A~}" proglist)
 		    (error "Undefined symbol~P: ~{~S~^, ~}"
 			   (length assumptions)
 			   (mapcar #'car assumptions)))
 		   ((not (null new-corrections))
 		    (return (proglist-encode proglist
+					     :symtab incoming-symtab
 					     :start-pc start-pc
 					     :cpu-package cpu-package
 					     :corrections (nconc new-corrections corrections))))))




More information about the Movitz-cvs mailing list