[llvm] [HashRecognize] Check TC against bitwidth of LHSAux (PR #144881)
Piotr Fusik via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 23 06:14:39 PDT 2025
================
@@ -583,6 +577,13 @@ HashRecognize::recognizeCRC() const {
return "Recurrences not intertwined with XOR";
}
+ // Make sure that the TC doesn't exceed the bitwidth of LHSAux, or LHS.
+ Value *LHS = ConditionalRecurrence.Start;
+ Value *LHSAux = SimpleRecurrence ? SimpleRecurrence.Start : nullptr;
+ if (TC > (LHSAux ? LHSAux->getType()->getIntegerBitWidth()
+ : LHS->getType()->getIntegerBitWidth()))
----------------
pfusik wrote:
I don't see "nodata" in llvm/test/Analysis/HashRecognize/cyclic-redundancy-check.ll
https://github.com/llvm/llvm-project/pull/144881
More information about the llvm-commits
mailing list