fix: temporary disable the cse optimizations that cause kernel misbehave.
[lunaix-os.git] / lunaix-os / config / make-cc
index 7a1899c327622e7abe2fdb86482ceb0b42dc3176..ed1f6786021a640316dc2fba02a091fb78d12a61 100644 (file)
@@ -10,6 +10,13 @@ W := -Wall -Wextra -Wno-unknown-pragmas \
                -Wno-unused-parameter \
                -Wno-unused-variable\
                -Werror=incompatible-pointer-types
-               
-CFLAGS := -std=gnu99 -ffreestanding $(O) $(W) $(ARCH_OPT)
+
+OFLAGS := -fno-gcse\
+                 -fno-gcse-lm\
+                 -fno-cse-follow-jumps\
+                 -fno-cse-skip-blocks\
+                 -fno-optimize-strlen\
+                 -fno-tree-builtin-call-dce 
+
+CFLAGS := -std=gnu99 -ffreestanding $(O) $(OFLAGS) $(W) $(ARCH_OPT)
 LDFLAGS := -ffreestanding $(O) -nostdlib -lgcc
\ No newline at end of file