Skip to content

Commit

Permalink
MSVC: Disable ICF for optimize=speed_trace
Browse files Browse the repository at this point in the history
  • Loading branch information
RedworkDE committed Jun 11, 2023
1 parent 37d1dfe commit e2aee1a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -572,9 +572,12 @@ if selected_platform in platform_list:
env.Append(CCFLAGS=["/Zi", "/FS"])
env.Append(LINKFLAGS=["/DEBUG:FULL"])

if env["optimize"] == "speed" or env["optimize"] == "speed_trace":
if env["optimize"] == "speed":
env.Append(CCFLAGS=["/O2"])
env.Append(LINKFLAGS=["/OPT:REF"])
elif env["optimize"] == "speed_trace":
env.Append(CCFLAGS=["/O2"])
env.Append(LINKFLAGS=["/OPT:REF", "/OPT:NOICF"])
elif env["optimize"] == "size":
env.Append(CCFLAGS=["/O1"])
env.Append(LINKFLAGS=["/OPT:REF"])
Expand Down

0 comments on commit e2aee1a

Please sign in to comment.