mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 19:52:54 +01:00
[X86] Pass itins.rr/itins.rm through properly for some instructions.
llvm-svn: 321452
This commit is contained in:
parent
a225ee1dea
commit
8032e9b258
@ -3734,7 +3734,7 @@ multiclass PDI_binop_rm2<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!if(Is2Addr,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1), RC:$src2)))]>,
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1), RC:$src2)))], itins.rr>,
|
||||
Sched<[itins.Sched]>;
|
||||
def rm : PDI<opc, MRMSrcMem, (outs RC:$dst),
|
||||
(ins RC:$src1, x86memop:$src2),
|
||||
@ -3742,8 +3742,8 @@ multiclass PDI_binop_rm2<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1),
|
||||
(bitconvert (memop_frag addr:$src2)))))]>,
|
||||
Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
(bitconvert (memop_frag addr:$src2)))))],
|
||||
itins.rm>, Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
}
|
||||
} // ExeDomain = SSEPackedInt
|
||||
|
||||
@ -6313,7 +6313,7 @@ multiclass SS48I_binop_rm<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!if(Is2Addr,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (OpVT (OpNode RC:$src1, RC:$src2)))]>,
|
||||
[(set RC:$dst, (OpVT (OpNode RC:$src1, RC:$src2)))], itins.rr>,
|
||||
Sched<[itins.Sched]>;
|
||||
def rm : SS48I<opc, MRMSrcMem, (outs RC:$dst),
|
||||
(ins RC:$src1, x86memop:$src2),
|
||||
@ -6321,8 +6321,8 @@ multiclass SS48I_binop_rm<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst,
|
||||
(OpVT (OpNode RC:$src1, (bitconvert (memop_frag addr:$src2)))))]>,
|
||||
Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
(OpVT (OpNode RC:$src1, (bitconvert (memop_frag addr:$src2)))))],
|
||||
itins.rm>, Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
}
|
||||
|
||||
/// SS48I_binop_rm2 - Simple SSE41 binary operator with different src and dst
|
||||
@ -6338,7 +6338,7 @@ multiclass SS48I_binop_rm2<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!if(Is2Addr,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1), RC:$src2)))]>,
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1), RC:$src2)))], itins.rr>,
|
||||
Sched<[itins.Sched]>;
|
||||
def rm : SS48I<opc, MRMSrcMem, (outs RC:$dst),
|
||||
(ins RC:$src1, x86memop:$src2),
|
||||
@ -6346,8 +6346,8 @@ multiclass SS48I_binop_rm2<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (DstVT (OpNode (SrcVT RC:$src1),
|
||||
(bitconvert (memop_frag addr:$src2)))))]>,
|
||||
Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
(bitconvert (memop_frag addr:$src2)))))],
|
||||
itins.rm>, Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
}
|
||||
|
||||
let Predicates = [HasAVX, NoVLX] in {
|
||||
@ -6924,14 +6924,15 @@ multiclass SS42I_binop_rm<bits<8> opc, string OpcodeStr, SDNode OpNode,
|
||||
!if(Is2Addr,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst, (OpVT (OpNode RC:$src1, RC:$src2)))]>, Sched<[itins.Sched]>;
|
||||
[(set RC:$dst, (OpVT (OpNode RC:$src1, RC:$src2)))], itins.rr>,
|
||||
Sched<[itins.Sched]>;
|
||||
def rm : SS428I<opc, MRMSrcMem, (outs RC:$dst),
|
||||
(ins RC:$src1, x86memop:$src2),
|
||||
!if(Is2Addr,
|
||||
!strconcat(OpcodeStr, "\t{$src2, $dst|$dst, $src2}"),
|
||||
!strconcat(OpcodeStr, "\t{$src2, $src1, $dst|$dst, $src1, $src2}")),
|
||||
[(set RC:$dst,
|
||||
(OpVT (OpNode RC:$src1, (memop_frag addr:$src2))))]>,
|
||||
(OpVT (OpNode RC:$src1, (memop_frag addr:$src2))))], itins.rm>,
|
||||
Sched<[itins.Sched.Folded, ReadAfterLd]>;
|
||||
}
|
||||
|
||||
|
@ -5624,16 +5624,8 @@ define <4 x i32> @test_pmaddwd(<8 x i16> %a0, <8 x i16> %a1, <8 x i16> *%a2) {
|
||||
;
|
||||
; ATOM-LABEL: test_pmaddwd:
|
||||
; ATOM: # %bb.0:
|
||||
; ATOM-NEXT: pmaddwd %xmm1, %xmm0
|
||||
; ATOM-NEXT: pmaddwd (%rdi), %xmm0
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: pmaddwd %xmm1, %xmm0 # sched: [5:5.00]
|
||||
; ATOM-NEXT: pmaddwd (%rdi), %xmm0 # sched: [5:5.00]
|
||||
; ATOM-NEXT: retq # sched: [79:39.50]
|
||||
;
|
||||
; SLM-LABEL: test_pmaddwd:
|
||||
@ -6241,16 +6233,8 @@ define <2 x i64> @test_pmuludq(<4 x i32> %a0, <4 x i32> %a1, <4 x i32> *%a2) {
|
||||
;
|
||||
; ATOM-LABEL: test_pmuludq:
|
||||
; ATOM: # %bb.0:
|
||||
; ATOM-NEXT: pmuludq %xmm1, %xmm0
|
||||
; ATOM-NEXT: pmuludq (%rdi), %xmm0
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: pmuludq %xmm1, %xmm0 # sched: [5:5.00]
|
||||
; ATOM-NEXT: pmuludq (%rdi), %xmm0 # sched: [5:5.00]
|
||||
; ATOM-NEXT: retq # sched: [79:39.50]
|
||||
;
|
||||
; SLM-LABEL: test_pmuludq:
|
||||
@ -6394,12 +6378,8 @@ define <2 x i64> @test_psadbw(<16 x i8> %a0, <16 x i8> %a1, <16 x i8> *%a2) {
|
||||
;
|
||||
; ATOM-LABEL: test_psadbw:
|
||||
; ATOM: # %bb.0:
|
||||
; ATOM-NEXT: psadbw %xmm1, %xmm0
|
||||
; ATOM-NEXT: psadbw (%rdi), %xmm0
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: psadbw %xmm1, %xmm0 # sched: [1:0.50]
|
||||
; ATOM-NEXT: psadbw (%rdi), %xmm0 # sched: [1:1.00]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
; ATOM-NEXT: nop # sched: [1:0.50]
|
||||
|
Loading…
Reference in New Issue
Block a user