Some times we need to do single-operand vector shuffling. LLVM uses the form shuffle(v, undef / poison, mask), while CIR currently uses shuffle(v, v, mask) as we don't have equivalent for undef / poison. This causes different emissions of IR. Not very critical problem though.
A direct approach will be add one equivalent. In #628 Bruno mentioned that
Btw, it's possible we might need an undef attribute someday, but up to now we should be good without one!
The other approaches include unifying the two forms in CIR with canonicalization (or at least something similar). Open for other ideas.
Mentioned in #613 .
Some times we need to do single-operand vector shuffling. LLVM uses the form
shuffle(v, undef / poison, mask)
, while CIR currently usesshuffle(v, v, mask)
as we don't have equivalent forundef
/poison
. This causes different emissions of IR. Not very critical problem though.A direct approach will be add one equivalent. In #628 Bruno mentioned that
The other approaches include unifying the two forms in CIR with canonicalization (or at least something similar). Open for other ideas.