[ruby/etc] bump up to 1.3.1
[ruby-80x24.org.git] / vm_opts.h
blobb0ca81f3043fbf0114c5c02d92a621e6a5420e1a
1 #ifndef RUBY_VM_OPTS_H/*-*-c-*-*/
2 #define RUBY_VM_OPTS_H
3 /**********************************************************************
5 vm_opts.h - VM optimize option
7 $Author$
9 Copyright (C) 2004-2007 Koichi Sasada
11 **********************************************************************/
13 /* Compile options.
14 * You can change these options at runtime by VM::CompileOption.
15 * Following definitions are default values.
18 #define OPT_TAILCALL_OPTIMIZATION 0
19 #define OPT_PEEPHOLE_OPTIMIZATION 1
20 #define OPT_SPECIALISED_INSTRUCTION 1
21 #define OPT_INLINE_CONST_CACHE 1
22 #define OPT_FROZEN_STRING_LITERAL 0
23 #define OPT_DEBUG_FROZEN_STRING_LITERAL 0
25 /* Build Options.
26 * You can't change these options at runtime.
29 /* C compiler dependent */
32 * 0: direct (using labeled goto using GCC special)
33 * 1: token (switch/case)
34 * 2: call (function call for each insn dispatch)
36 #ifndef OPT_THREADED_CODE
37 #define OPT_THREADED_CODE 0
38 #endif
40 #define OPT_DIRECT_THREADED_CODE (OPT_THREADED_CODE == 0)
41 #define OPT_TOKEN_THREADED_CODE (OPT_THREADED_CODE == 1)
42 #define OPT_CALL_THREADED_CODE (OPT_THREADED_CODE == 2)
44 /* VM running option */
45 #define OPT_CHECKED_RUN 1
46 #define OPT_INLINE_METHOD_CACHE 1
47 #define OPT_GLOBAL_METHOD_CACHE 1
48 #define OPT_BLOCKINLINING 0
50 #ifndef OPT_IC_FOR_IVAR
51 #define OPT_IC_FOR_IVAR 1
52 #endif
54 /* architecture independent, affects generated code */
55 #define OPT_OPERANDS_UNIFICATION 1
56 #define OPT_INSTRUCTIONS_UNIFICATION 0
57 #define OPT_UNIFY_ALL_COMBINATION 0
58 #define OPT_STACK_CACHING 0
60 /* misc */
61 #ifndef OPT_SUPPORT_JOKE
62 #define OPT_SUPPORT_JOKE 0
63 #endif
65 #ifndef OPT_SUPPORT_CALL_C_FUNCTION
66 #define OPT_SUPPORT_CALL_C_FUNCTION 0
67 #endif
69 #ifndef VM_COLLECT_USAGE_DETAILS
70 #define VM_COLLECT_USAGE_DETAILS 0
71 #endif
73 #endif /* RUBY_VM_OPTS_H */