[PATCH] D147558: [IR] Add a ConstantInt::getAllOnes wrapper around ConstantInt::get/getSigned.
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 5 05:48:43 PDT 2023
nikic added a comment.
In D147558#4244195 <https://reviews.llvm.org/D147558#4244195>, @craig.topper wrote:
> getAllOnesValue has to reinspect the type to determine int vs FP.
Is there reason to believe that this has any non-negligible cost?
> We also can't override on IntegerType* to return a ConstantInt*. Not sure if any of the callers of ConstantInt::get/getSigned was using that feature.
We pretty much always handle int or vector of int, so specializing on ConstantInt return doesn't seem like something that would commonly be needed.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D147558/new/
https://reviews.llvm.org/D147558
More information about the llvm-commits
mailing list