From: Dale Weiler Date: Sun, 25 May 2014 06:04:10 +0000 (-0400) Subject: Fix vec3_cross. Added optimization to Makefile since we've been compiling gmqcc witho... X-Git-Tag: xonotic-v0.8.1~9^2~32^2~1 X-Git-Url: https://git.xonotic.org/?p=xonotic%2Fgmqcc.git;a=commitdiff_plain;h=655c2482c97a30c3634c22a13f0ea43f946677b5 Fix vec3_cross. Added optimization to Makefile since we've been compiling gmqcc without it since forever. --- diff --git a/Makefile b/Makefile index bec603e..6f8eb9a 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ UNAME ?= $(shell uname) CYGWIN = $(findstring CYGWIN, $(UNAME)) MINGW = $(findstring MINGW, $(UNAME)) -CFLAGS += -Wall -Wextra -Werror -Wstrict-aliasing -Wno-attributes +CFLAGS += -Wall -Wextra -Werror -Wstrict-aliasing -Wno-attributes -O3 #turn on tons of warnings if clang is present # but also turn off the STUPID ONES ifeq ($(CC), clang) diff --git a/fold.c b/fold.c index 86c443d..3819074 100644 --- a/fold.c +++ b/fold.c @@ -765,6 +765,10 @@ static GMQCC_INLINE vec3_t vec3_cross(lex_ctx_t ctx, vec3_t a, vec3_t b) { if (!OPTS_FLAG(ARITHMETIC_EXCEPTIONS)) goto end; + sa = vec3_soft_convert(a); + sb = vec3_soft_convert(b); + + sfloat_init(&s[0]); sfloat_init(&s[1]); sfloat_init(&s[2]); sfloat_init(&s[3]);