================ @@ -87,6 +87,21 @@ def getStdFlag(cfg, std): return "-std=" + fallbacks[std] return None +def getSpeedOptimizationFlag(cfg): + if _isClang(cfg) or _isAppleClang(cfg) or _isGCC(cfg): + return "-O3" + elif _isMSVC(cfg): + return "/O2" + else: + raise RuntimeError("Can't figure out what compiler is used in the configuration") + +def getSizeOptimizationFlag(cfg): + if _isClang(cfg) or _isAppleClang(cfg) or _isGCC(cfg): + return "-Os" + elif _isMSVC(cfg): + return "/O1" ---------------- philnik777 wrote:
There seems to also be `/Os`. @mstorsjo @StephanTLavavej @CaseyCarter Do you know which is the correct one? https://github.com/llvm/llvm-project/pull/68753 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits