- ;; When we generate collections of standard specialized array types,
- ;; what should their element types be?
- (defvar *typecheckfun-standard-element-typespecs*
- ;; Note: This table is pretty arbitrary, just things I use a lot
- ;; or see used a lot. If someone has ideas for better values,
- ;; lemme know. -- WHN 2001-10-15
- #(t
- character
- bit fixnum (unsigned-byte 32) (signed-byte 32)
- single-float double-float))
- ;; What are the standard testable types? (If a slot accessor looks
- ;; up one of these types, it doesn't need to supply a compiled TYPEP
- ;; function to initialize the possibly-empty entry: instead it's
- ;; guaranteed that the entry is there. This should save some compile
- ;; time and object file bloat.)
- (defvar *typecheckfun-standard-typespecs*
- (coerce (remove-duplicates
- (mapcar (lambda (typespec)
- (type-specifier (specifier-type typespec)))
- ;; Note: This collection of input values is
- ;; pretty arbitrary, just inspired by things I
- ;; use a lot or see being used a lot in the
- ;; system. If someone has ideas for better
- ;; values, lemme know. -- WHN 2001-10-15
- (concatenate
- 'list
- ;; non-array types
- '(bit
- boolean
- character
- cons
- double-float
- fixnum
- hash-table
- index
- integer
- list
- package
- signed-byte
- (signed-byte 8)
- single-float
- structure-object
- symbol
- unsigned-byte
- (unsigned-byte 8)
- (unsigned-byte 32))
- ;; systematic names for array types
- (map 'list
- (lambda (element-type)
- `(simple-array ,element-type 1))
- *typecheckfun-standard-element-typespecs*)
- (map 'list
- (lambda (element-type)
- `(vector ,element-type))
- *typecheckfun-standard-element-typespecs*)
- ;; idiosyncratic names for array types
- '(simple-vector
- bit-vector simple-bit-vector
- string simple-string)))
- :test #'equal)
- 'simple-vector)))
+ (defvar *compile-time-common-typespecs*
+ (let (;; When we generate collections of common specialized
+ ;; array types, what should their element types be?
+ (common-element-typespecs
+ ;; Note: This table is pretty arbitrary, just things I use a lot
+ ;; or see used a lot. If someone has ideas for better values,
+ ;; lemme know. -- WHN 2001-10-15
+ #(t
+ character
+ bit fixnum
+ #!+#.(cl:if (cl:= 32 sb!vm:n-word-bits) '(and) '(or))
+ (unsigned-byte 32)
+ #!+#.(cl:if (cl:= 64 sb!vm:n-word-bits) '(and) '(or))
+ (unsigned-byte 64)
+ #!+#.(cl:if (cl:= 32 sb!vm:n-word-bits) '(and) '(or))
+ (signed-byte 32)
+ #!+#.(cl:if (cl:= 64 sb!vm:n-word-bits) '(and) '(or))
+ (signed-byte 64)
+ single-float double-float)))
+ (coerce (remove-duplicates
+ (mapcar (lambda (typespec)
+ (type-specifier (specifier-type typespec)))
+ ;; Note: This collection of input values is
+ ;; pretty arbitrary, just inspired by things I
+ ;; use a lot or see being used a lot in the
+ ;; system. If someone has ideas for better
+ ;; values, lemme know. -- WHN 2001-10-15
+ (concatenate
+ 'list
+ ;; non-array types
+ '(bit
+ boolean
+ character
+ cons
+ double-float
+ fixnum
+ hash-table
+ index
+ integer
+ list
+ package
+ signed-byte
+ (signed-byte 8)
+ single-float
+ structure-object
+ symbol
+ unsigned-byte
+ (unsigned-byte 8)
+ #!+#.(cl:if (cl:= 32 sb!vm:n-word-bits) '(and) '(or))
+ (unsigned-byte 32)
+ #!+#.(cl:if (cl:= 64 sb!vm:n-word-bits) '(and) '(or))
+ (unsigned-byte 64))
+ ;; systematic names for array types
+ (map 'list
+ (lambda (element-type)
+ `(simple-array ,element-type 1))
+ common-element-typespecs)
+ (map 'list
+ (lambda (element-type)
+ `(vector ,element-type))
+ common-element-typespecs)
+ ;; idiosyncratic names for array types
+ '(simple-vector
+ bit-vector simple-bit-vector
+ string simple-string)))
+ :test #'equal)
+ 'simple-vector))))