[PATCH] D61675: [WIP] Update IRBuilder::CreateFNeg(...) to return a UnaryOperator
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 31 09:47:15 PDT 2019
craig.topper added a comment.
In D61675#1608548 <https://reviews.llvm.org/D61675#1608548>, @cameron.mcinally wrote:
> In D61675#1601893 <https://reviews.llvm.org/D61675#1601893>, @craig.topper wrote:
>
> > Clang does not use the IRBuilder fneg entry point. When do we plan to switch clang over?
>
>
> Sorry for the delay, Craig. I missed this comment...
>
> So Clang does use the IRBuilder fneg entry point (at least in some places). That's why all these Clang tests have differences:
>
> M clang/test/CodeGen/aarch64-v8.2a-fp16-intrinsics.c (2 lines)
> M clang/test/CodeGen/avx512f-builtins.c (56 lines)
> M clang/test/CodeGen/avx512vl-builtins.c (24 lines)
> M clang/test/CodeGen/complex-math.c (6 lines)
> M clang/test/CodeGen/fma-builtins.c (8 lines)
> M clang/test/CodeGen/fma4-builtins.c (10 lines)
>
>
> There may be more places that need to be updated though, I'm not sure.
Sorry I wasn't very clear there. There are certainly places that use it, but the code for unary minus operator does not use CreateFNEG. it asks for the constant value to use for negation and the makes an fsub or sub depending on fp or int.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61675/new/
https://reviews.llvm.org/D61675
More information about the llvm-commits
mailing list