[PATCH] D95373: Replace vector intrinsics with call to vector library

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 26 11:32:37 PST 2021


craig.topper added a comment.

In D95373#2523383 <https://reviews.llvm.org/D95373#2523383>, @spatel wrote:

> In D95373#2523207 <https://reviews.llvm.org/D95373#2523207>, @craig.topper wrote:
>
>> In D95373#2522607 <https://reviews.llvm.org/D95373#2522607>, @fhahn wrote:
>>
>>> In D95373#2522603 <https://reviews.llvm.org/D95373#2522603>, @spatel wrote:
>>>
>>>> I haven't looked at the trade-offs, but if we can do this transform later ( SelectionDAGLegalize::ConvertNodeToLibcall() ? ) that would seem to be more flexible...and smaller patch? 
>>>> For reference:
>>>> D8131 <https://reviews.llvm.org/D8131> - added support for external vector library calls
>>>> D70107 <https://reviews.llvm.org/D70107> - added inject-tli-mappings
>>>
>>> +1 on doing this as late as possible. Ideally we would then just get rid of the logic in LV/SLP that inserts the library calls.
>>
>> I think SelectionDAG would scalarize the operation in LegalizeVectorOps before they reach LegalizeDAG.
>
> So an IR codegen pass that runs after the optimizer would be best? If the patch is small enough, we could glom this into CGP?

Does GlobalISel also use CGP? Do we want to emit vector libcalls for vector IR intrinsics at O0? If I recall, CGP is disabled at O0.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D95373/new/

https://reviews.llvm.org/D95373



More information about the llvm-commits mailing list