summaryrefslogtreecommitdiff
path: root/xmake/modules/core/tools/cl.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/modules/core/tools/cl.lua')
-rw-r--r--xmake/modules/core/tools/cl.lua22
1 files changed, 9 insertions, 13 deletions
diff --git a/xmake/modules/core/tools/cl.lua b/xmake/modules/core/tools/cl.lua
index 177b97669..b05e35eb4 100644
--- a/xmake/modules/core/tools/cl.lua
+++ b/xmake/modules/core/tools/cl.lua
@@ -158,19 +158,15 @@ end
-- make the optimize flag
function nf_optimize(self, level)
- -- only for source kind
- local kind = self:kind()
- if language.sourcekinds()[kind] then
- local maps =
- {
- none = "-Od"
- , faster = "-Ox"
- , fastest = "-O2 -fp:fast"
- , smallest = "-O1 -GL" -- /GL and (/OPT:REF is on by default in linker), we need enable /ltcg
- , aggressive = "-O2 -fp:fast"
- }
- return maps[level]
- end
+ local maps =
+ {
+ none = "-Od"
+ , faster = "-Ox"
+ , fastest = "-O2 -fp:fast"
+ , smallest = "-O1 -GL" -- /GL and (/OPT:REF is on by default in linker), we need enable /ltcg
+ , aggressive = "-O2 -fp:fast"
+ }
+ return maps[level]
end
-- make vs runtime flag