[llvm] [PPC] Set minimum of largest number of comparisons to use bit test for switch lowering (PR #155910)
Shimin Cui via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 22 12:14:00 PDT 2025
================
@@ -2120,6 +2126,14 @@ bool TargetLoweringBase::isJumpTableRelative() const {
return getTargetMachine().isPositionIndependent();
}
+unsigned TargetLoweringBase::getMinimumBitTestCmps() const {
+ return MinimumBitTestCmps;
+}
+
+void TargetLoweringBase::setMinimumBitTestCmps(unsigned Val) {
+ MinimumBitTestCmps = Val;
----------------
scui-ibm wrote:
Thanks for the comments. I changed to use a member variable to avoid the thread-safe issue. There are some existing code pattern like this, we can change in other PR.
https://github.com/llvm/llvm-project/pull/155910
More information about the llvm-commits
mailing list