X-Git-Url: https://git.xonotic.org/?a=blobdiff_plain;f=gmqcc.ini.example;h=ceacf289c3fd606f43c9532171c9161fa8d464b4;hb=25caf4b8e8a3dfab39ea422a5b674b965f70755c;hp=7fc19fd07bff8fcf859087875a0639bfef2b69a4;hpb=fac4e411bfeca94b3fac11d8e8a95788bed7ba74;p=xonotic%2Fgmqcc.git diff --git a/gmqcc.ini.example b/gmqcc.ini.example index 7fc19fd..ceacf28 100644 --- a/gmqcc.ini.example +++ b/gmqcc.ini.example @@ -62,6 +62,28 @@ FTEPP_PREDEFS = false + #Enable math constant definitions. This only works in combination + #with '-fftepp' and is currently not included by '-std=fteqcc'. + #The following macros will be added: + # + # M_E + # M_LOG2E + # M_LOG10E + # M_LN2 + # M_LN10 + # M_PI + # M_PI_2 + # M_PI_4 + # M_1_PI + # M_2_PI + # M_2_SQRTPI + # M_SQRT2 + # M_SQRT1_2 + # M_TAU + + FTEPP_MATHDEFS = false + + #Allow switch cases to use non constant variables. RELAXED_SWITCH = true @@ -288,6 +310,17 @@ SORT_OPERANDS = false + #Emulate OP_STATE operations in code rather than using the instruction. + #The desired fps can be set via -state-fps=NUM, defaults to 10. + + EMULATE_STATE = false + + + #Turn on arithmetic exception tests in the compiler. In constant expressions + #which trigger exceptions like division by zero, overflow, underflow, etc, + #the following flag will produce diagnostics for what triggered that + #exception. + ARITHMETIC_EXCEPTIONS = false [warnings] #Generate a warning about variables which are declared but never @@ -531,6 +564,27 @@ CONST_OVERWRITE = true + + #Warn about the use of preprocessor directives inside macros. + + DIRECTIVE_INMACRO = true + + + #When using a function that is not explicitly defined, the compiler + #will search its intrinsics table for something that matches that + #function name by appending "__builtin_" to it. This behaviour may + #be unexpected, so enabling this will produce a diagnostic when + #such a function is resolved to a builtin. + + BUILTINS = true + + + #When comparing an inexact value such as `1.0/3.0' the result is + #pathologically wrong. Enabling this will trigger a compiler warning + #on such expressions. + INEXACT_COMPARES = true + + [optimizations] #Some general peephole optimizations. For instance the code `a = b #+ c` typically generates 2 instructions, an ADD and a STORE. This @@ -561,7 +615,6 @@ OVERLAP_LOCALS = true - #This promotes locally declared variables to "temps". Meaning when #a temporary result of an operation has to be stored somewhere, a #local variable which is not 'alive' at that point can be used to @@ -644,6 +697,7 @@ CONST_FOLD_DCE = true + #For constant expressions we can fold them to immediate values. #this option cannot be disabled or enabled, the compiler forces #it to stay enabled by ignoring the value entierly. There are