mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-11 13:30:47 -04:00
Document that -O3 is still a bad idea for gcc-12
This commit is contained in:
parent
6fe8b393a8
commit
28d5de33e6
@ -84,6 +84,7 @@ endif()
|
|||||||
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
|
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
|
||||||
add_compile_options(-fdiagnostics-color=always)
|
add_compile_options(-fdiagnostics-color=always)
|
||||||
# For gcc, -O3 is *much* worse than -O2
|
# For gcc, -O3 is *much* worse than -O2
|
||||||
|
# Update: This is still true for gcc-12
|
||||||
set(CMAKE_C_FLAGS_RELEASE "-DNDEBUG -O2 -g")
|
set(CMAKE_C_FLAGS_RELEASE "-DNDEBUG -O2 -g")
|
||||||
set(CMAKE_CXX_FLAGS_RELEASE "-DNDEBUG -O2 -g")
|
set(CMAKE_CXX_FLAGS_RELEASE "-DNDEBUG -O2 -g")
|
||||||
elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user