1 ! Copyright (C) 2007, 2008 Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: compiler cpu.architecture vocabs.loader system sequences
4 namespaces parser kernel kernel.private classes classes.private
5 arrays hashtables vectors classes.tuple sbufs inference.dataflow
6 hashtables.private sequences.private math classes.tuple.private
7 growable namespaces.private assocs words generator command-line
8 vocabs io prettyprint libc compiler.units math.order ;
11 ! Don't bring this in when deploying, since it will store a
12 ! reference to 'eval' in a global variable
14 "alien.remote-control" require
17 "cpu." cpu word-name append require
21 : compile-uncompiled ( words -- )
22 [ compiled? not ] filter compile ;
25 "Compiling..." write flush
27 ! Compile a set of words ahead of the full compile.
28 ! This set of words was determined semi-empirically
29 ! using the profiler. It improves bootstrap time
30 ! significantly, because frequenly called words
31 ! which are also quick to compile are replaced by
32 ! compiled definitions as soon as possible.
34 roll -roll declare not
36 array? hashtable? vector?
37 tuple? sbuf? node? tombstone?
39 array-capacity array-nth set-array-nth
47 bitand bitor bitxor bitnot
53 + 1+ 1- 2/ < <= > >= shift
59 new-sequence nth push pop peek
77 malloc calloc free memcpy
80 vocabs [ words compile-uncompiled "." write flush ] each