[llvm] [Option] Add Condition for build-conditional library options (PR #230898)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Sun Oct 11 11:17:43 PDT 2026


================
@@ -143,6 +143,14 @@ static const unsigned MaxIVUsers = 200;
 /// the salvaging is not too expensive for the compiler.
 static const unsigned MaxSCEVSalvageExpressionSize = 64;
 
+static bool stressIVChain(const ScalarOptions &Opts) {
+#ifndef NDEBUG
+  return Opts.stress_ivchain;
+#else
+  return false;
+#endif
----------------
MaskRay wrote:

Yes, this seems overkill (for the code size benefit in non-assertion builds). I'll leave this to @fhahn though...

https://github.com/llvm/llvm-project/pull/230898


More information about the llvm-commits mailing list