Skip to content

Commit

Permalink
Enable LTO in release virtual and SNP (#5857)
Browse files Browse the repository at this point in the history
  • Loading branch information
achamayou authored Dec 8, 2023
1 parent f138828 commit d4ce993
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .daily_canary
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
-^- ___ ___
(- -) (= =) | Y & +--?
( V ) / . \ | +---=---'
/--x-m- /--n-n---xXx--/--yY------>>>----<<<>>]]{{}}---||-/\
/--x-m- /--n-n---xXx--/--yY------>>>----<<<>>]]{{}}---||-/\-
2 changes: 1 addition & 1 deletion .snpcc_canary
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
___ ___ ___
(. =) Y (0 0) (x X) Y
O \ o | /
/-xXx--//-----x=x--/-xXx--/---x---->>><
/-xXx--//-----x=x--/-xXx--/---x---->>>--
7 changes: 7 additions & 0 deletions cmake/preproject.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -85,4 +85,11 @@ if("${COMPILE_TARGET}" STREQUAL "snp")
endif()
endif()

if("${COMPILE_TARGET}" STREQUAL "snp" OR "${COMPILE_TARGET}" STREQUAL "virtual")
if(NOT "${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
add_compile_options(-flto)
add_link_options(-flto)
endif()
endif()

set(CMAKE_CXX_STANDARD 20)

0 comments on commit d4ce993

Please sign in to comment.