0.9.2.47:
[sbcl/lichteblau.git] / src / compiler / policies.lisp
blobb1d2ee6e4b0c9caa68370e38a090b824d917c477
1 ;;;; aimed optimization qualities
3 ;;;; This software is part of the SBCL system. See the README file for
4 ;;;; more information.
5 ;;;;
6 ;;;; This software is derived from the CMU CL system, which was
7 ;;;; written at Carnegie Mellon University and released into the
8 ;;;; public domain. The software is in the public domain and is
9 ;;;; provided with absolutely no warranty. See the COPYING and CREDITS
10 ;;;; files for more information.
12 (in-package "SB!C")
14 (define-optimization-quality type-check
15 (cond ((= safety 0) 0)
16 ;; FIXME: It is duplicated in PROBABLE-TYPE-CHECK-P and in
17 ;; some other places.
18 ((and (<= speed safety)
19 (<= space safety)
20 (<= compilation-speed safety))
22 (t 2))
23 ("no" "maybe" "fast" "full"))
25 (define-optimization-quality check-tag-existence
26 (cond ((= safety 0) 0)
27 (t 3))
28 ("no" "maybe" "yes" "yes"))
30 (define-optimization-quality let-convertion
31 (if (<= debug speed) 3 0)
32 ("off" "maybe" "on" "on"))
34 (define-optimization-quality verify-arg-count
35 (if (zerop safety) 0 3)
36 ("no" "maybe" "yes" "yes"))
38 (define-optimization-quality merge-tail-calls
39 (if (or (> space debug)
40 (> speed debug))
43 ("no" "maybe" "yes" "yes"))
45 (define-optimization-quality insert-debug-catch
46 (if (> debug (max speed space))
49 ("no" "maybe" "yes" "yes"))
51 (define-optimization-quality recognize-self-calls
52 (if (> (max speed space) debug)
55 ("no" "maybe" "yes" "yes"))
57 (define-optimization-quality stack-allocate-dynamic-extent
58 (if (and (> (max speed space) (max debug safety))
59 (< safety 3))
62 ("no" "maybe" "yes" "yes"))
64 (define-optimization-quality stack-allocate-vector
65 (cond ((= stack-allocate-dynamic-extent 0) 0)
66 ((= safety 0) 3)
67 (t 2))
68 ("no" "maybe" "one page" "yes"))
70 (define-optimization-quality float-accuracy
72 ("degraded" "full" "full" "full"))
74 (define-optimization-quality insert-step-conditions
75 (if (> debug (max speed space compilation-speed))
76 debug
78 ("no" "no" "partial" "full"))