Support ConstantInt::get() and Constant::getAllOnesValue() for scalable
vector type, this requires ConstantVector::getSplat() to take in 'ElementCount',
instead of 'unsigned' number of element count.
This change is needed for D73753.
Paths
| Differential D74386
[SVE] Update API ConstantVector::getSplat() to use ElementCount. ClosedPublic Authored by huihuiz on Feb 10 2020, 11:11 PM.
Details Summary Support ConstantInt::get() and Constant::getAllOnesValue() for scalable This change is needed for D73753.
Diff Detail
Event TimelineComment Actions This is sort of a large number of functional changes, but it's probably okay to skip test coverage for all the simple getNumElements->getElementCount changes; it's obvious it can't break anything.
huihuiz marked 2 inline comments as done. Comment ActionsThanks Eli for the review! Add test cases to check for size query changes in ConstantExpr::getGetElementPtr().
huihuiz marked 3 inline comments as done. Comment ActionsAddressed review comments.
This revision is now accepted and ready to land.Mar 12 2020, 12:26 PM Closed by commit rG118abf201738: [SVE] Update API ConstantVector::getSplat() to use ElementCount. (authored by huihuiz). · Explain WhyMar 12 2020, 1:34 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 250001 clang/lib/CodeGen/CGBuiltin.cpp
llvm/include/llvm/Analysis/Utils/Local.h
llvm/include/llvm/IR/Constants.h
llvm/lib/Analysis/InstructionSimplify.cpp
llvm/lib/CodeGen/CodeGenPrepare.cpp
llvm/lib/IR/ConstantFold.cpp
llvm/lib/IR/Constants.cpp
llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
llvm/test/CodeGen/AArch64/scalable-vector-promotion.ll
llvm/test/Transforms/InstSimplify/gep.ll
llvm/unittests/FuzzMutate/OperationsTest.cpp
llvm/unittests/IR/VerifierTest.cpp
|
Please write out the type ElementCOunt.