Further speed up GC scavenging.
[sbcl.git] / tests / vm.before-xc.lisp
blob7471802af7e45b1aab666dd5b97effb9fc108d46
1 ;;;; tests of the compiler vm internal consistency intended to be
2 ;;;; executed as soon as the cross-compiler is built.
4 ;;;; This software is part of the SBCL system. See the README file for
5 ;;;; more information.
6 ;;;;
7 ;;;; While most of SBCL is derived from the CMU CL system, the test
8 ;;;; files (like this one) were written from scratch after the fork
9 ;;;; from CMU CL.
10 ;;;;
11 ;;;; This software is in the public domain and is provided with
12 ;;;; absolutely no warranty. See the COPYING and CREDITS files for
13 ;;;; more information.
15 (in-package "SB!VM")
17 (/show "beginning tests/vm.before-xc.lisp")
19 (flet ((yes (x)
20 (assert
21 (eql (sc-number-or-lose 'immediate)
22 (immediate-constant-sc x))))
23 (no (x)
24 (assert
25 (not (immediate-constant-sc x)))))
26 ;; target fixnums can be dealt with as immediates; target bignums
27 ;; can not.
28 (yes #.sb-xc:most-positive-fixnum)
29 (yes #.sb-xc:most-negative-fixnum)
30 (no #.(1+ sb-xc:most-positive-fixnum))
31 (no #.(1- sb-xc:most-negative-fixnum)))
33 (/show "done with tests/vm.before-xc.lisp")