Merge pull request #9 from jkdansereau/perf/release-opt

build: keep release -O2 instead of forcing -Og
This commit is contained in:
James Dansereau authored and GitHub committed 2026-09-03 00:26:25 -04:00
commit 6c322548d4
1 file changed
+5 -1
+5 -1
View File
@@ -225,7 +225,11 @@ add_compile_options(
# get a real backtrace of a hung/crashed game thread.
add_compile_options(-fno-omit-frame-pointer)
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
# Optimisation: the software RSP + software rasteriser in port/fast3d are the
# hot path and are very sensitive to -O level (the difference between ~1 fps
# and playable). Non-Debug builds keep the CMAKE_BUILD_TYPE optimisation
# (RelWithDebInfo => -O2); only an explicit Debug build drops to -Og.
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
add_compile_options(-Og)
endif()