00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035 #ifndef GCC_PARAMS_H
00036 #define GCC_PARAMS_H
00037
00038
00039
00040 #define INVALID_PARAM_VAL (-1)
00041
00042
00043
00044 typedef struct param_info
00045 {
00046
00047
00048 const char *const option;
00049
00050 int value;
00051
00052 const char *const help;
00053 } param_info;
00054
00055
00056
00057
00058 extern param_info *compiler_params;
00059
00060
00061
00062 extern void add_params
00063 PARAMS ((const param_info params[], size_t n));
00064
00065
00066
00067 extern void set_param_value
00068 PARAMS ((const char *name, int value));
00069
00070
00071
00072
00073 typedef enum compiler_param
00074 {
00075 #define DEFPARAM(enumerator, option, msgid, default) \
00076 enumerator,
00077 #include "params.def"
00078 #undef DEFPARAM
00079 LAST_PARAM
00080 } compiler_param;
00081
00082
00083 #define PARAM_VALUE(ENUM) \
00084 (compiler_params[(int) ENUM].value)
00085
00086
00087 #define MAX_INLINE_INSNS_SINGLE \
00088 PARAM_VALUE (PARAM_MAX_INLINE_INSNS_SINGLE)
00089 #define MAX_INLINE_INSNS \
00090 PARAM_VALUE (PARAM_MAX_INLINE_INSNS)
00091 #define MAX_INLINE_SLOPE \
00092 PARAM_VALUE (PARAM_MAX_INLINE_SLOPE)
00093 #define MIN_INLINE_INSNS \
00094 PARAM_VALUE (PARAM_MIN_INLINE_INSNS)
00095 #define MAX_INLINE_INSNS_AUTO \
00096 PARAM_VALUE (PARAM_MAX_INLINE_INSNS_AUTO)
00097 #define MAX_INLINE_INSNS_RTL \
00098 PARAM_VALUE (PARAM_MAX_INLINE_INSNS_RTL)
00099 #define MAX_DELAY_SLOT_INSN_SEARCH \
00100 PARAM_VALUE (PARAM_MAX_DELAY_SLOT_INSN_SEARCH)
00101 #define MAX_DELAY_SLOT_LIVE_SEARCH \
00102 PARAM_VALUE (PARAM_MAX_DELAY_SLOT_LIVE_SEARCH)
00103 #define MAX_PENDING_LIST_LENGTH \
00104 PARAM_VALUE (PARAM_MAX_PENDING_LIST_LENGTH)
00105 #define MAX_GCSE_MEMORY \
00106 ((size_t) PARAM_VALUE (PARAM_MAX_GCSE_MEMORY))
00107 #define MAX_GCSE_PASSES \
00108 PARAM_VALUE (PARAM_MAX_GCSE_PASSES)
00109 #define MAX_UNROLLED_INSNS \
00110 PARAM_VALUE (PARAM_MAX_UNROLLED_INSNS)
00111 #endif