[PATCH] D82416: [SVE] Make Constant::getSplatValue work for scalable vector splats
Eli Friedman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 30 14:09:23 PDT 2020
efriedma added a comment.
It looks like this affects a bunch of the pattern-matchers in PatternMatch.h; for example, m_APInt. Is that right?
================
Comment at: llvm/lib/IR/Constants.cpp:1534
+ Constant *SplatVal = IElt->getOperand(1);
+ ConstantInt *Index = cast<ConstantInt>(IElt->getOperand(2));
+
----------------
I don't see any reason the index here would be a ConstantInt, in general. (I mean, the result here would be pretty silly if it wasn't, but nothing is actually enforcing it.)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D82416/new/
https://reviews.llvm.org/D82416
More information about the llvm-commits
mailing list