0.7.13.24:
[sbcl.git] / src / code / early-fasl.lisp
index 32161b0..06c77da 100644 (file)
 (defparameter *fasl-header-string-start-string* "# FASL")
 
 ;;; the code for a character which terminates a fasl file header
-(defconstant +fasl-header-string-stop-char-code+ 255)
-
-;;; This value should be incremented when the system changes in such
-;;; a way that it will no longer work reliably with old fasl files.
-(defconstant +fasl-file-version+ 17)
-;;; 2 = sbcl-0.6.4 uses COMPILE-OR-LOAD-DEFGENERIC.
-;;; 3 = sbcl-0.6.6 uses private symbol, not :EMPTY, for empty HASH-TABLE slot.
-;;; 4 = sbcl-0.6.7 uses HAIRY-DATA-VECTOR-REF and HAIRY-DATA-VECTOR-SET
-;;;     when array headers or data element type uncertainty exist, and
-;;;     uses DATA-VECTOR-REF and DATA-VECTOR-SET only for VOPs. (Thus,
-;;;     full calls to DATA-VECTOR-REF and DATA-VECTOR-SET from older
-;;;     fasl files would fail, because there are no DEFUNs for these
-;;;     operations any more.)
-;;; 5 = sbcl-0.6.8 has rearranged static symbols.
-;;; 6 = sbcl-0.6.9, got rid of non-ANSI %DEFCONSTANT/%%DEFCONSTANT stuff
-;;;     and deleted a slot from DEBUG-SOURCE structure.
-;;; 7 = around sbcl-0.6.9.8, merged SB-CONDITIONS package into SB-KERNEL
-;;; 8 = sbcl-0.6.10.4 revived Gray stream support, changing stream layouts.
-;;; 9 = deleted obsolete CONS-UNIQUE-TAG bytecode in sbcl-0.6.11.8
-;;; (somewhere in here also changes to AND and OR CTYPE layouts) 
-;;; 10 = new layout for CONDITION in sbcl-0.6.11.38
-;;; 11 = (a) new helper functions for MAKE-LOAD-FORM (HASH-TABLE) in
-;;;          sbcl-0.6.12.11
-;;;      (b) new address space constants for OpenBSD in 0.6.12.17
-;;;          (doesn't need separate version from (a) because the
-;;;          OpenBSD port was broken from sometime before 0.6.12.11
-;;;          until the address space was changed)
-;;; 12 = sbcl-0.6.12.22 added new SB-FASL package
-;;; 13 = sbcl-0.6.12.28 removed some elements from *STATIC-SYMBOLS* 
-;;; 14 = sbcl-0.6.12.29 removed more elements from *STATIC-SYMBOLS* 
-;;; 15 = sbcl-0.6.12.33 changed the layout of STREAM
-;;; 16 = sbcl-0.pre7.15 changed the layout of PRETTY-STREAM
-;;; 17 = sbcl-0.pre7.38 (merging many changes accumulated in
-;;;      the sbcl-0.pre7.37.flaky5.* branch back into the main branch)
-;;;      got rid of byte compiler, byte interpreter, and IR1
-;;;      interpreter, changed %DEFUN and DEFSTRUCT, changed the
-;;;      meaning of FOP-FSET, and changed the layouts of various
-;;;      internal compiler structures (e.g. DEFSTRUCT CLAMBDA)
+(def!constant +fasl-header-string-stop-char-code+ 255)
+
+;;; This value should be incremented when the system changes in such a
+;;; way that it will no longer work reliably with old fasl files. In
+;;; practice, I (WHN) fairly often forget to increment it for CVS
+;;; versions which break binary compatibility. But it certainly should
+;;; be incremented for release versions which break binary
+;;; compatibility.
+(def!constant +fasl-file-version+ 40)
+;;; (record of versions before 0.7.0 deleted in 0.7.1.41)
+;;; 23 = sbcl-0.7.0.1 deleted no-longer-used EVAL-STACK stuff,
+;;;      causing changes in *STATIC-SYMBOLS*.
+;;; 24 = sbcl-0.7.1.19 changed PCL service routines which might be
+;;;      called from macroexpanded code
+;;; 25 = sbcl-0.7.1.41 (and immediately preceding versions, actually)
+;;;      introduced new functions to check for control stack exhaustion
+;;; 26 = sbcl-0.7.2.4 or so added :VARIABLE :MACRO-EXPANSION to INFO codes
+;;; 27: (2002-04-08) added MIGHT-CONTAIN-OTHER-TYPES? slot to CTYPE
+;;; 28: (2002-05-08) new convention for foreign symbols to support
+;;;     dynamic loading in OpenBSD
+;;; 29: (2002-06-24) removed *!INITIAL-FDEFN-OBJECTS* from static symbols
+;;; 30: (2002-07-26) deleted all references to %DETECT-STACK-EXHAUSTION, 
+;;;     which was introduced in version 25, since now control stack
+;;;     is checked using mmap() page protection
+;;; 31: (2002-08-14) changed encoding of PCL internal MAKE-INSTANCE
+;;;     function names so they're insensitive to whether the class name
+;;;     is currently external to its package
+;;; 32: (2002-09-21) changes in implementation of sequence functions,
+;;;     causing old utility functions like COERCE-TO-SIMPLE-VECTOR to go away
+;;; 33: (2002-10-02) (again) changes in implementation of sequence functions,
+;;;     causing old utility functions like COERCE-TO-SIMPLE-VECTOR to go away
+;;; 34: (2002-10-05) changed implementation of DEFMACRO, so %%DEFMACRO
+;;;      was deleted
+;;; 35: (2002-11-27) (incremented version before 0.7.10 release,
+;;;     reflecting changes from a week or more ago) changed layout of
+;;;     CLOS objects to support SXHASH returning values other than 42
+;;;     for STANDARD-OBJECT
+;;; 36: (2002-12-04) DEFSTRUCT-DESCRIPTION layout changed to accommodate
+;;;     correct behaviour of colliding accessors
+;;; 37: (2002-12-09) changed implementation of DEFINE-COMPILER-MACRO,
+;;;     deleting %%DEFINE-COMPILER-MACRO
+;;; 38: (2003-01-05) changed names of internal SORT machinery
+;;; 39: (2003-02-20) in 0.7.12.1 a slot was added to
+;;;     DEFSTRUCT-SLOT-DESCRIPTION
+;;; 40: (2003-03-11) changed value of (SXHASH NIL)
 
 ;;; the conventional file extension for our fasl files
 (declaim (type simple-string *fasl-file-type*))
 (defvar *fasl-file-type* "fasl")
-
-;;; This is a sort of pun that we inherited from CMU CL. For ordinary,
-;;; non-byte-coded fasl files, the "implementation" is basically the
-;;; CPU. For byte-coded fasl files, the "implementation" is whether
-;;; the data are stored big-endianly or little-endianly.
-(defun backend-byte-fasl-file-implementation ()
-  *backend-byte-order*)
 \f
-;;; information about below-Lisp-level linkage
-;;;
+;;;; information about below-Lisp-level linkage
+
 ;;; Note:
 ;;;   Assembler routines are named by full Lisp symbols: they
 ;;;     have packages and that sort of native Lisp stuff associated
 ;;;     with them. We can compare them with EQ.
-;;;   Foreign symbols are named by Lisp strings: the Lisp package
+;;;   Foreign symbols are named by Lisp STRINGs: the Lisp package
 ;;;     system doesn't extend out to symbols in languages like C.
 ;;;     We want to use EQUAL to compare them.
 ;;;   *STATIC-FOREIGN-SYMBOLS* are static as opposed to "dynamic" (not
-;;;     as opposed to "extern"). The table contains symbols known at 
+;;;     as opposed to C's "extern"). The table contains symbols known at 
 ;;;     the time that the program was built, but not symbols defined
 ;;;     in object files which have been loaded dynamically since then.
 (declaim (type hash-table *assembler-routines* *static-foreign-symbols*))
 \f
 ;;;; the FOP database
 
-(declaim (simple-vector *fop-names* *fop-functions*))
+(declaim (simple-vector *fop-names* *fop-funs*))
 
 ;;; a vector indexed by a FaslOP that yields the FOP's name
 (defvar *fop-names* (make-array 256 :initial-element nil))
 
 ;;; a vector indexed by a FaslOP that yields a function of 0 arguments
 ;;; which will perform the operation
-(defvar *fop-functions*
+(defvar *fop-funs*
   (make-array 256
              :initial-element (lambda ()
                                 (error "corrupt fasl file: losing FOP"))))
 
 ;;; the FASL file we're reading from
 (defvar *fasl-input-stream*)
-(declaim (type lisp-stream *fasl-input-stream*))
+(declaim (type ansi-stream *fasl-input-stream*))
 
 (defvar *load-print* nil
   #!+sb-doc