[llvm] r370276 - [X86] Fix a couple isel patterns to not shrink a volatile load.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 28 16:45:10 PDT 2019
Author: ctopper
Date: Wed Aug 28 16:45:10 2019
New Revision: 370276
URL: http://llvm.org/viewvc/llvm-project?rev=370276&view=rev
Log:
[X86] Fix a couple isel patterns to not shrink a volatile load.
Also add a FIXME because I'm not sure why these patterns exist. Looks like a missing combine.
And another FIXME because the AVX512 equivalent one of the patterns is missing.
Modified:
llvm/trunk/lib/Target/X86/X86InstrSSE.td
Modified: llvm/trunk/lib/Target/X86/X86InstrSSE.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrSSE.td?rev=370276&r1=370275&r2=370276&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrSSE.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrSSE.td Wed Aug 28 16:45:10 2019
@@ -5326,11 +5326,13 @@ let ExeDomain = SSEPackedSingle in {
let Predicates = [UseAVX] in {
// If we're inserting an element from a vbroadcast of a load, fold the
// load into the X86insertps instruction.
+ // FIXME: Why are these here? This looks like a demanded bits issue.
+ // FIXME: Missing AVX512 equivalents.
def : Pat<(v4f32 (X86insertps (v4f32 VR128:$src1),
(X86VBroadcast (loadf32 addr:$src2)), imm:$src3)),
(VINSERTPSrm VR128:$src1, addr:$src2, imm:$src3)>;
def : Pat<(v4f32 (X86insertps (v4f32 VR128:$src1),
- (X86VBroadcast (loadv4f32 addr:$src2)), imm:$src3)),
+ (X86VBroadcast (v4f32 (nonvolatile_load addr:$src2))), imm:$src3)),
(VINSERTPSrm VR128:$src1, addr:$src2, imm:$src3)>;
}
@@ -7562,7 +7564,7 @@ let Predicates = [HasAVX, NoVLX] in {
def : Pat<(v2f64 (X86VBroadcast v2f64:$src)),
(VMOVDDUPrr VR128:$src)>;
- def : Pat<(v2f64 (X86VBroadcast (loadv2f64 addr:$src))),
+ def : Pat<(v2f64 (X86VBroadcast (v2f64 (nonvolatile_load addr:$src)))),
(VMOVDDUPrm addr:$src)>;
def : Pat<(v2f64 (X86VBroadcast (v2f64 (X86vzload64 addr:$src)))),
(VMOVDDUPrm addr:$src)>;
More information about the llvm-commits
mailing list