X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Ftarget-dump.lisp;h=038c6458ef8fd51b28e4671fab5b23a2d513faeb;hb=076d38141d1d2689a1040dc8af71bd7fbf2b54a4;hp=26c73808defc43be3cf5bafb40c9cc6fa58ddeec;hpb=bf27595fb567015495b7131707cc85af361567fe;p=sbcl.git diff --git a/src/compiler/target-dump.lisp b/src/compiler/target-dump.lisp index 26c7380..038c645 100644 --- a/src/compiler/target-dump.lisp +++ b/src/compiler/target-dump.lisp @@ -20,7 +20,7 @@ (defun dump-characters-of-string (s fasl-output) (declare (type string s) (type fasl-output fasl-output)) (dovector (c s) - (dump-word (char-code c) fasl-output)) + (dump-unsigned-byte-32 (char-code c) fasl-output)) (values)) #!+sb-unicode (defun dump-simple-character-string (s file) @@ -33,7 +33,8 @@ ;;; vector-like thing that we can BLT from. (defun dump-raw-bytes (vec n fasl-output) (declare (type index n) (type fasl-output fasl-output)) - (sb!sys:output-raw-bytes (fasl-output-stream fasl-output) vec 0 n) + ;; FIXME: Why not WRITE-SEQUENCE? + (sb!impl::buffer-output (fasl-output-stream fasl-output) vec 0 n) (values)) ;;; Dump a multi-dimensional array. Note: any displacements are folded out. @@ -50,8 +51,8 @@ (dump-integer (array-dimension array i) file)) (with-array-data ((vector array) (start) (end)) (if (and (= start 0) (= end (length vector))) - (sub-dump-object vector file) - (sub-dump-object (subseq vector start end) file))) + (sub-dump-object vector file) + (sub-dump-object (subseq vector start end) file))) (dump-fop 'fop-array file) (dump-word rank file) (eq-save-object array file))) @@ -76,8 +77,8 @@ (dump-fop 'fop-long-float-vector file) (dump-word length file) (dump-raw-bytes vec - (* length sb!vm:n-word-bytes #!+x86 3 #!+sparc 4) - file))) + (* length sb!vm:n-word-bytes #!+x86 3 #!+sparc 4) + file))) (defun dump-complex-single-float-vector (vec file) (let ((length (length vec))) @@ -97,15 +98,15 @@ (dump-fop 'fop-complex-long-float-vector file) (dump-word length file) (dump-raw-bytes vec - (* length sb!vm:n-word-bytes #!+x86 3 #!+sparc 4 2) - file))) + (* length sb!vm:n-word-bytes #!+x86 3 #!+sparc 4 2) + file))) #!+(and long-float x86) (defun dump-long-float (float file) (declare (long-float float)) (let ((exp-bits (long-float-exp-bits float)) - (high-bits (long-float-high-bits float)) - (low-bits (long-float-low-bits float))) + (high-bits (long-float-high-bits float)) + (low-bits (long-float-low-bits float))) ;; We could get away with DUMP-WORD here, since the x86 has 4-byte words, ;; but we prefer to make things as explicit as possible. ;; --njf, 2004-08-16 @@ -117,9 +118,9 @@ (defun dump-long-float (float file) (declare (long-float float)) (let ((exp-bits (long-float-exp-bits float)) - (high-bits (long-float-high-bits float)) - (mid-bits (long-float-mid-bits float)) - (low-bits (long-float-low-bits float))) + (high-bits (long-float-high-bits float)) + (mid-bits (long-float-mid-bits float)) + (low-bits (long-float-low-bits float))) ;; We could get away with DUMP-WORD here, since the sparc has 4-byte ;; words, but we prefer to make things as explicit as possible. ;; --njf, 2004-08-16