[llvm-branch-commits] [clang] [MSVC] work-around for compile time issue 102513 (PR #111314)
via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Sun Oct 6 14:48:02 PDT 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-clang
Author: bd1976bris (bd1976bris)
<details>
<summary>Changes</summary>
Manual cherry-pick of #<!-- -->110986 to the LLVM 19 release branch.
---
Full diff: https://github.com/llvm/llvm-project/pull/111314.diff
1 Files Affected:
- (modified) clang/lib/AST/Interp/Interp.cpp (+8)
``````````diff
diff --git a/clang/lib/AST/Interp/Interp.cpp b/clang/lib/AST/Interp/Interp.cpp
index 6fcd90e5f58498..0f9eedc3f38ea1 100644
--- a/clang/lib/AST/Interp/Interp.cpp
+++ b/clang/lib/AST/Interp/Interp.cpp
@@ -925,6 +925,10 @@ void diagnoseEnumValue(InterpState &S, CodePtr OpPC, const EnumDecl *ED,
}
}
+// https://github.com/llvm/llvm-project/issues/102513
+#if defined(_WIN32) && !defined(__clang__) && !defined(NDEBUG)
+#pragma optimize("", off)
+#endif
bool Interpret(InterpState &S, APValue &Result) {
// The current stack frame when we started Interpret().
// This is being used by the ops to determine wheter
@@ -949,6 +953,10 @@ bool Interpret(InterpState &S, APValue &Result) {
}
}
}
+// https://github.com/llvm/llvm-project/issues/102513
+#if defined(_WIN32) && !defined(__clang__) && !defined(NDEBUG)
+#pragma optimize("", on)
+#endif
} // namespace interp
} // namespace clang
``````````
</details>
https://github.com/llvm/llvm-project/pull/111314
More information about the llvm-branch-commits
mailing list