From: Nikodemus S. <de...@us...> - 2008-12-18 12:23:22
|
Update of /cvsroot/sbcl/sbcl/src/code In directory fdv4jf1.ch3.sourceforge.com:/tmp/cvs-serv2200/src/code Modified Files: late-format.lisp target-format.lisp Log Message: 1.0.23.52: FORMAT performance tweaking * Handle plain ~D using explicitly bindings and OUTPUT-OBJECT to avoid paying for WRITE keyword argument parsing. * Compile format control strings when SPEED = SPACE. * Always transform FORMAT calls when the second argument is a function -- trying to save space there doesn't make much sense. Index: late-format.lisp =================================================================== RCS file: /cvsroot/sbcl/sbcl/src/code/late-format.lisp,v retrieving revision 1.36 retrieving revision 1.37 diff -u -d -r1.36 -r1.37 --- late-format.lisp 4 Mar 2007 23:52:41 -0000 1.36 +++ late-format.lisp 18 Dec 2008 11:56:47 -0000 1.37 @@ -483,8 +483,10 @@ `(format-print-integer stream ,(expand-next-arg) ,colonp ,atsignp ,base ,mincol ,padchar ,commachar ,commainterval)) - `(write ,(expand-next-arg) :stream stream :base ,base :radix nil - :escape nil))) + `(let ((*print-base* ,base) + (*print-radix* nil) + (*print-escape* nil)) + (output-object ,(expand-next-arg) stream)))) (def-format-directive #\D (colonp atsignp params) (expand-format-integer 10 colonp atsignp params)) Index: target-format.lisp =================================================================== RCS file: /cvsroot/sbcl/sbcl/src/code/target-format.lisp,v retrieving revision 1.32 retrieving revision 1.33 diff -u -d -r1.32 -r1.33 --- target-format.lisp 13 Mar 2008 13:18:49 -0000 1.32 +++ target-format.lisp 18 Dec 2008 11:56:47 -0000 1.33 @@ -290,7 +290,10 @@ params (format-print-integer stream (next-arg) colonp atsignp ,base mincol padchar commachar commainterval)) - (write (next-arg) :stream stream :base ,base :radix nil :escape nil))) + (let ((*print-base* ,base) + (*print-radix* nil) + (*print-escape* nil)) + (output-object (next-arg) stream)))) (def-format-interpreter #\D (colonp atsignp params) (interpret-format-integer 10)) |