[PATCH] D79452: [VectorCombine] scalarize binop of inserted elements into vector constants

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 7 09:05:18 PDT 2020


RKSimon added inline comments.


================
Comment at: llvm/test/Transforms/VectorCombine/X86/insert-binop.ll:102
   %i0 = insertelement <2 x i64> <i64 42, i64 -42>, i64 %x, i64 1
   %i1 = insertelement <2 x i64> <i64 -7, i64 128>, i64 %y, i32 1
   %r = sdiv <2 x i64> %i0, %i1
----------------
Can we ever have a base vector with undef elements here? sdiv/udiv won't like that but I'm not sure if we can ever get in that state.
```
  %i0 = insertelement <2 x i64> <i64 42, i64 undef>, i64 %x, i64 1
  %i1 = insertelement <2 x i64> <i64 -7, i64 undef>, i64 %y, i32 1
```


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79452/new/

https://reviews.llvm.org/D79452





More information about the llvm-commits mailing list