Skip to content
Snippets Groups Projects
Commit 13a5cb22 authored by Rye Mutt's avatar Rye Mutt :bread:
Browse files

Add options for msvc to generate code favoring amd64 or intel64

parent a95146aa
No related branches found
No related tags found
No related merge requests found
...@@ -157,6 +157,16 @@ if (WINDOWS) ...@@ -157,6 +157,16 @@ if (WINDOWS)
add_compile_options(/arch:SSE2) add_compile_options(/arch:SSE2)
endif () endif ()
option(FAVOR_AMD "Favor amd64 processors in generated code" OFF)
option(FAVOR_INTEL "Favor intel64 processors in generated code" OFF)
if(FAVOR_AMD AND FAVOR_INTEL)
message(FATAL_ERROR "Cannot enable favor intel and amd at the same time")
elseif(FAVOR_AMD)
add_compile_options(/favor:AMD64)
elseif(FAVOR_INTEL)
add_compile_options(/favor:INTEL64)
endif()
if (NOT VS_DISABLE_FATAL_WARNINGS) if (NOT VS_DISABLE_FATAL_WARNINGS)
add_compile_options(/WX) add_compile_options(/WX)
endif (NOT VS_DISABLE_FATAL_WARNINGS) endif (NOT VS_DISABLE_FATAL_WARNINGS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment