[PATCH] D110322: [ConstantFolding] Fold constrained compare intrinsics
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 16 07:08:07 PST 2021
spatel added a comment.
I have no objections to this patch now. I'd pre-commit the baseline tests though, and let's see if there's consensus on where to house the helper function.
================
Comment at: llvm/lib/IR/ConstantFold.cpp:2021
+/// Evaluate the given predicate for the constant values.
+bool llvm::evaluatePredicate(unsigned Pred, const APFloat &Op1,
+ const APFloat &Op2) {
----------------
sepavloff wrote:
> spatel wrote:
> > This was suggested in an earlier comment - can we add this next to:
> > https://github.com/llvm/llvm-project/blob/80b1d472d6f7e10403e37cc74bfda278372ecb97/llvm/lib/IR/Instructions.cpp#L4135
> >
> > (and adjust the names/parameters for consistency)
> >
> > That can be a preliminary/NFC commit if I'm seeing it correctly.
> Previously such method existed but I was recommended to remove it: https://reviews.llvm.org/D110322?id=388475#3159399.
>
> Otherwise there is no problem to restore that implementation.
Ah, sorry I didn't see that earlier comment/revision.
@craig.topper - do you still prefer the current structure?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D110322/new/
https://reviews.llvm.org/D110322
More information about the llvm-commits
mailing list