mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-12 13:00:32 +00:00
Set -fno-strict-aliasing to prevent gcc from breaking tons of code
* Technically the code is incorrect, because the C++ spec is terrible and makes completely normal things illegal. GCC decides that a couple of % more perf is worth breaking lots of code, so instead we disable this class of "optimisation".
This commit is contained in:
+1
-1
@@ -314,7 +314,7 @@ if(cmake_build_type_lower STREQUAL "release" OR
|
||||
endif()
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fstrict-aliasing")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-strict-aliasing")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
|
||||
if(ENABLE_GGP)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -gline-tables-only -fno-omit-frame-pointer")
|
||||
|
||||
Reference in New Issue
Block a user