[llvm] [SLP]Support for zext i1 %x modeling as select %x, 1, 0 (PR #180635)
Alexey Bataev via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 11 04:56:28 PST 2026
alexey-bataev wrote:
> I'm hitting asserts after this change. Reduced repro:
>
> ```c
> struct {
> long a;
> long b
> } *c;
> long d, e, f;
> int g;
> void h() {
> long a = 2;
> g = d == 0;
> a -= g;
> long b = g;
> if (e)
> ;
> else
> g = a -= b += f;
> c[0].a = a;
> c[0].b = b;
> }
> ```
>
> ```
> $ clang -target aarch64-w64-mingw32 -c repro.c -O2
> clang: ../lib/Transforms/Vectorize/SLPVectorizer.cpp:2690: int llvm::slpvectorizer::BoUpSLP::LookAheadHeuristics::getScoreAtLevelRec(llvm::Value*, llvm::Value*, llvm::Instruction*, llvm::Instruction*, int, llvm::ArrayRef<llvm::Value*>) const: Assertion `FromIdx <= ToIdx && "Bad index"' failed.
> ```
Fixed in 54cdd903b87211f71972f684b8532357c435aa7a
https://github.com/llvm/llvm-project/pull/180635
More information about the llvm-commits
mailing list