mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 20:32:21 +00:00
Add AVX non-temporal stores
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107178 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
af0824701b
commit
721ef73d88
@ -2023,6 +2023,47 @@ defm RCP : sse1_fp_unop_s<0x53, "rcp", X86frcp, int_x86_sse_rcp_ss>,
|
||||
// SSE 1 & 2 - Non-temporal stores
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
let isAsmParserOnly = 1 in {
|
||||
def VMOVNTPSmr_Int : VPSI<0x2B, MRMDestMem, (outs),
|
||||
(ins i128mem:$dst, VR128:$src),
|
||||
"movntps\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse_movnt_ps addr:$dst, VR128:$src)]>, VEX;
|
||||
def VMOVNTPDmr_Int : VPDI<0x2B, MRMDestMem, (outs),
|
||||
(ins i128mem:$dst, VR128:$src),
|
||||
"movntpd\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_pd addr:$dst, VR128:$src)]>, VEX;
|
||||
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def VMOVNTDQmr_Int : VPDI<0xE7, MRMDestMem, (outs),
|
||||
(ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_dq addr:$dst, VR128:$src)]>, VEX;
|
||||
|
||||
let AddedComplexity = 400 in { // Prefer non-temporal versions
|
||||
def VMOVNTPSmr : VPSI<0x2B, MRMDestMem, (outs),
|
||||
(ins f128mem:$dst, VR128:$src),
|
||||
"movntps\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v4f32 VR128:$src),
|
||||
addr:$dst)]>, VEX;
|
||||
def VMOVNTPDmr : VPDI<0x2B, MRMDestMem, (outs),
|
||||
(ins f128mem:$dst, VR128:$src),
|
||||
"movntpd\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v2f64 VR128:$src),
|
||||
addr:$dst)]>, VEX;
|
||||
def VMOVNTDQ_64mr : VPDI<0xE7, MRMDestMem, (outs),
|
||||
(ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v2f64 VR128:$src),
|
||||
addr:$dst)]>, VEX;
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def VMOVNTDQmr : VPDI<0xE7, MRMDestMem, (outs),
|
||||
(ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v4f32 VR128:$src),
|
||||
addr:$dst)]>, VEX;
|
||||
}
|
||||
}
|
||||
|
||||
def MOVNTPSmr_Int : PSI<0x2B, MRMDestMem, (outs), (ins i128mem:$dst, VR128:$src),
|
||||
"movntps\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse_movnt_ps addr:$dst, VR128:$src)]>;
|
||||
@ -2030,6 +2071,11 @@ def MOVNTPDmr_Int : PDI<0x2B, MRMDestMem, (outs), (ins i128mem:$dst, VR128:$src)
|
||||
"movntpd\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_pd addr:$dst, VR128:$src)]>;
|
||||
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def MOVNTDQmr_Int : PDI<0xE7, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_dq addr:$dst, VR128:$src)]>;
|
||||
|
||||
let AddedComplexity = 400 in { // Prefer non-temporal versions
|
||||
def MOVNTPSmr : PSI<0x2B, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntps\t{$src, $dst|$dst, $src}",
|
||||
@ -2042,6 +2088,12 @@ def MOVNTDQ_64mr : PDI<0xE7, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v2f64 VR128:$src), addr:$dst)]>;
|
||||
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def MOVNTDQmr : PDI<0xE7, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v4f32 VR128:$src), addr:$dst)]>;
|
||||
|
||||
// There is no AVX form for instructions below this point
|
||||
def MOVNTImr : I<0xC3, MRMDestMem, (outs), (ins i32mem:$dst, GR32:$src),
|
||||
"movnti\t{$src, $dst|$dst, $src}",
|
||||
[(nontemporalstore (i32 GR32:$src), addr:$dst)]>,
|
||||
@ -2052,17 +2104,7 @@ def MOVNTI_64mr : RI<0xC3, MRMDestMem, (outs), (ins i64mem:$dst, GR64:$src),
|
||||
[(nontemporalstore (i64 GR64:$src), addr:$dst)]>,
|
||||
TB, Requires<[HasSSE2]>;
|
||||
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def MOVNTDQmr : PDI<0xE7, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(alignednontemporalstore (v4f32 VR128:$src), addr:$dst)]>;
|
||||
}
|
||||
|
||||
let ExeDomain = SSEPackedInt in
|
||||
def MOVNTDQmr_Int : PDI<0xE7, MRMDestMem, (outs), (ins f128mem:$dst, VR128:$src),
|
||||
"movntdq\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_dq addr:$dst, VR128:$src)]>;
|
||||
|
||||
def MOVNTImr_Int : I<0xC3, MRMDestMem, (outs), (ins i32mem:$dst, GR32:$src),
|
||||
"movnti\t{$src, $dst|$dst, $src}",
|
||||
[(int_x86_sse2_movnt_i addr:$dst, GR32:$src)]>,
|
||||
|
@ -10938,3 +10938,15 @@
|
||||
// CHECK: encoding: [0xc5,0xea,0x53,0x18]
|
||||
vrcpss (%eax), %xmm2, %xmm3
|
||||
|
||||
// CHECK: vmovntdq %xmm1, (%eax)
|
||||
// CHECK: encoding: [0xc5,0xf9,0xe7,0x08]
|
||||
vmovntdq %xmm1, (%eax)
|
||||
|
||||
// CHECK: vmovntpd %xmm1, (%eax)
|
||||
// CHECK: encoding: [0xc5,0xf9,0x2b,0x08]
|
||||
vmovntpd %xmm1, (%eax)
|
||||
|
||||
// CHECK: vmovntps %xmm1, (%eax)
|
||||
// CHECK: encoding: [0xc5,0xf8,0x2b,0x08]
|
||||
vmovntps %xmm1, (%eax)
|
||||
|
||||
|
@ -986,3 +986,15 @@ pshufb CPI1_0(%rip), %xmm1
|
||||
// CHECK: encoding: [0xc5,0x1a,0x53,0x10]
|
||||
vrcpss (%rax), %xmm12, %xmm10
|
||||
|
||||
// CHECK: vmovntdq %xmm11, (%rax)
|
||||
// CHECK: encoding: [0xc5,0x79,0xe7,0x18]
|
||||
vmovntdq %xmm11, (%rax)
|
||||
|
||||
// CHECK: vmovntpd %xmm11, (%rax)
|
||||
// CHECK: encoding: [0xc5,0x79,0x2b,0x18]
|
||||
vmovntpd %xmm11, (%rax)
|
||||
|
||||
// CHECK: vmovntps %xmm11, (%rax)
|
||||
// CHECK: encoding: [0xc5,0x78,0x2b,0x18]
|
||||
vmovntps %xmm11, (%rax)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user