mirror of
https://github.com/RPCSX/SPIRV-Tools.git
synced 2024-11-30 06:40:36 +00:00
Use SPIRV_PERF=1 when performance tuning.
It tells the compiler to keep frame pointers, so you have good call stacks in your profiles.
This commit is contained in:
parent
980b7cb95e
commit
005a11a4ac
@ -52,6 +52,12 @@ endif()
|
||||
|
||||
if(UNIX)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-exceptions -fno-rtti")
|
||||
|
||||
# For good call stacks in profiles, keep the frame pointers.
|
||||
if(NOT SPIRV_PERF STREQUAL "")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-omit-frame-pointer")
|
||||
endif()
|
||||
|
||||
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fcolor-diagnostics")
|
||||
set(SPIRV_USE_SANITIZER "" CACHE STRING
|
||||
|
Loading…
Reference in New Issue
Block a user