[PATCH] D64710: [x86] try to keep FP casted+truncated+extracted vector element out of GPRs
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 14 13:12:22 PDT 2019
spatel created this revision.
spatel added reviewers: RKSimon, craig.topper.
Herald added subscribers: hiraditya, mcrosier.
Herald added a project: LLVM.
inttofp (trunc (extelt X, 0)) --> inttofp (extelt (bitcast X), 0)
We have pseudo-vectorization of scalar int to FP casts, so this tries to make that more likely by replacing a truncate with a bitcast. I didn't see any test diffs starting from 'uitofp', so I left that as a TODO. We can't only match the shorter trunc+extract pattern because there's an opposing transform somewhere, so we infinite loop.
A motivating case is shown in PR39975 and included in the test diffs here:
https://bugs.llvm.org/show_bug.cgi?id=39975
https://reviews.llvm.org/D64710
Files:
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/CodeGen/X86/known-bits-vector.ll
llvm/test/CodeGen/X86/known-signbits-vector.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D64710.209746.patch
Type: text/x-patch
Size: 5568 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190714/e6ff0def/attachment.bin>
More information about the llvm-commits
mailing list