]> git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - doc/gmqcc.1
Arithmetic exception flag and a plethora of tests.
[xonotic/gmqcc.git] / doc / gmqcc.1
index 7ee54c01cab814924cbc17f04fa67e903cd08b86..33a0eff3fbedef27673b700dc9511176e3be2029 100644 (file)
@@ -335,7 +335,7 @@ ignored for both cases.
 When compiling original QuakeWorld QC there are instances where
 code overwrites constants. This is considered an error, however
 for QuakeWorld to compile it needs to be treated as a warning
-instead, as such this warning only works when -std=qcc.
+instead, as such this warning only works when \-std=qcc.
 .It Fl W Ns Cm directive-inmacro
 Warn about the use of preprocessor directives inside macros.
 .It Fl W Ns Cm builtins
@@ -344,6 +344,10 @@ 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.
+.It Fl W Ns Cm inexact-compares
+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.
 .El
 .Sh COMPILE FLAGS
 .Bl -tag -width Ds
@@ -577,6 +581,11 @@ breaks decompilers, but causes the output file to be better compressible.
 In commutative instructions, always put the lower-numbered operand first.
 This shaves off 1 byte of entropy from all these instructions, reducing
 compressed size of the output file.
+.It Fl f Ns Cm arithmetic-exceptions
+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.
 .El
 .Sh OPTIMIZATIONS
 .Bl -tag -width Ds