[llvm] r332096 - [X86][SLM] Vector stores only use the MEC port.

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Fri May 11 08:16:15 PDT 2018


Author: rksimon
Date: Fri May 11 08:16:15 2018
New Revision: 332096

URL: http://llvm.org/viewvc/llvm-project?rev=332096&view=rev
Log:
[X86][SLM] Vector stores only use the MEC port.

Confirmed by both Agner and Intel's AOM - the IEC/FPC are not required for pure load/stores (even if its a partial update).

Can't fix WriteStore until all RMW instructions are cleaned up though....

Modified:
    llvm/trunk/lib/Target/X86/X86ScheduleSLM.td
    llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse1.s
    llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse2.s

Modified: llvm/trunk/lib/Target/X86/X86ScheduleSLM.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ScheduleSLM.td?rev=332096&r1=332095&r2=332096&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ScheduleSLM.td (original)
+++ llvm/trunk/lib/Target/X86/X86ScheduleSLM.td Fri May 11 08:16:15 2018
@@ -137,11 +137,11 @@ def  : WriteRes<WriteFLoadX,        [SLM
 def  : WriteRes<WriteFLoadY,        [SLM_MEC_RSV]> { let Latency = 3; }
 def  : WriteRes<WriteFMaskedLoad,   [SLM_MEC_RSV]> { let Latency = 3; }
 def  : WriteRes<WriteFMaskedLoadY,  [SLM_MEC_RSV]> { let Latency = 3; }
-def  : WriteRes<WriteFStore,        [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteFStoreX,       [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteFStoreY,       [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteFMaskedStore,  [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteFMaskedStoreY, [SLM_FPC_RSV01, SLM_MEC_RSV]>;
+def  : WriteRes<WriteFStore,        [SLM_MEC_RSV]>;
+def  : WriteRes<WriteFStoreX,       [SLM_MEC_RSV]>;
+def  : WriteRes<WriteFStoreY,       [SLM_MEC_RSV]>;
+def  : WriteRes<WriteFMaskedStore,  [SLM_MEC_RSV]>;
+def  : WriteRes<WriteFMaskedStoreY, [SLM_MEC_RSV]>;
 def  : WriteRes<WriteFMove,         [SLM_FPC_RSV01]>;
 def  : WriteRes<WriteFMoveX,        [SLM_FPC_RSV01]>;
 def  : WriteRes<WriteFMoveY,        [SLM_FPC_RSV01]>;
@@ -215,11 +215,11 @@ def  : WriteRes<WriteVecLoadX,        [S
 def  : WriteRes<WriteVecLoadY,        [SLM_MEC_RSV]> { let Latency = 3; }
 def  : WriteRes<WriteVecMaskedLoad,   [SLM_MEC_RSV]> { let Latency = 3; }
 def  : WriteRes<WriteVecMaskedLoadY,  [SLM_MEC_RSV]> { let Latency = 3; }
-def  : WriteRes<WriteVecStore,        [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteVecStoreX,       [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteVecStoreY,       [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteVecMaskedStore,  [SLM_FPC_RSV01, SLM_MEC_RSV]>;
-def  : WriteRes<WriteVecMaskedStoreY, [SLM_FPC_RSV01, SLM_MEC_RSV]>;
+def  : WriteRes<WriteVecStore,        [SLM_MEC_RSV]>;
+def  : WriteRes<WriteVecStoreX,       [SLM_MEC_RSV]>;
+def  : WriteRes<WriteVecStoreY,       [SLM_MEC_RSV]>;
+def  : WriteRes<WriteVecMaskedStore,  [SLM_MEC_RSV]>;
+def  : WriteRes<WriteVecMaskedStoreY, [SLM_MEC_RSV]>;
 def  : WriteRes<WriteVecMove,         [SLM_FPC_RSV01]>;
 def  : WriteRes<WriteVecMoveX,        [SLM_FPC_RSV01]>;
 def  : WriteRes<WriteVecMoveY,        [SLM_FPC_RSV01]>;

Modified: llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse1.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse1.s?rev=332096&r1=332095&r2=332096&view=diff
==============================================================================
--- llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse1.s (original)
+++ llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse1.s Fri May 11 08:16:15 2018
@@ -331,7 +331,7 @@ xorps       (%rax), %xmm2
 
 # CHECK:      Resource pressure per iteration:
 # CHECK-NEXT: [0]    [1]    [2]    [3]    [4]    [5]    [6]    [7]
-# CHECK-NEXT:  -     232.00 8.00   62.50  47.50  2.50   2.50   67.00
+# CHECK-NEXT:  -     232.00 8.00   61.00  46.00  2.50   2.50   67.00
 
 # CHECK:      Resource pressure by instruction:
 # CHECK-NEXT: [0]    [1]    [2]    [3]    [4]    [5]    [6]    [7]    	Instructions:
@@ -382,7 +382,7 @@ xorps       (%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	minss	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -     1.00   	minss	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movaps	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movaps	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movaps	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movaps	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     1.00    -      -      -      -     	movhlps	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -     1.00    -      -      -      -     	movlhps	%xmm0, %xmm2
@@ -391,13 +391,13 @@ xorps       (%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movlps	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -     1.00    -      -      -     1.00   	movlps	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	movmskps	%xmm0, %ecx
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movntps	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movntps	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movntq	%mm0, (%rax)
 # CHECK-NEXT:  -      -      -     1.00    -      -      -      -     	movss	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movss	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movss	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movups	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movups	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movups	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movups	(%rax), %xmm2
 # CHECK-NEXT:  -      -     2.00   1.00    -      -      -      -     	mulps	%xmm0, %xmm2
 # CHECK-NEXT:  -      -     2.00   1.00    -      -      -     1.00   	mulps	(%rax), %xmm2

Modified: llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse2.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse2.s?rev=332096&r1=332095&r2=332096&view=diff
==============================================================================
--- llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse2.s (original)
+++ llvm/trunk/test/tools/llvm-mca/X86/SLM/resources-sse2.s Fri May 11 08:16:15 2018
@@ -674,7 +674,7 @@ xorpd       (%rax), %xmm2
 
 # CHECK:      Resource pressure per iteration:
 # CHECK-NEXT: [0]    [1]    [2]    [3]    [4]    [5]    [6]    [7]
-# CHECK-NEXT:  -     412.00 8.00   154.00 90.00  4.50   4.50   130.00
+# CHECK-NEXT:  -     412.00 8.00   150.50 86.50  4.50   4.50   130.00
 
 # CHECK:      Resource pressure by instruction:
 # CHECK-NEXT: [0]    [1]    [2]    [3]    [4]    [5]    [6]    [7]    	Instructions:
@@ -736,7 +736,7 @@ xorpd       (%rax), %xmm2
 # CHECK-NEXT:  -     32.00   -     1.00    -      -      -      -     	divsd	%xmm0, %xmm2
 # CHECK-NEXT:  -     32.00   -     1.00    -      -      -     1.00   	divsd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	lfence
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	maskmovdqu	%xmm0, %xmm1
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	maskmovdqu	%xmm0, %xmm1
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	maxpd	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -     1.00   	maxpd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	maxsd	%xmm0, %xmm2
@@ -746,17 +746,17 @@ xorpd       (%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	minsd	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -     1.00   	minsd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movapd	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movapd	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movapd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movapd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50    -     	movd	%eax, %xmm2
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50    -     	movd	%xmm0, %ecx
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movdqa	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movdqa	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movdqa	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movdqa	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movdqu	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movdqu	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movdqu	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movdqu	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movdq2q	%xmm0, %mm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movhpd	%xmm0, (%rax)
@@ -764,8 +764,8 @@ xorpd       (%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movlpd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -     1.00    -      -      -     1.00   	movlpd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -     1.00    -      -      -     	movmskpd	%xmm0, %ecx
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movntdq	%xmm0, (%rax)
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movntpd	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movntdq	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movntpd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movq	%xmm0, %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50    -     	movq	%rax, %xmm2
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movq	(%rax), %xmm2
@@ -776,7 +776,7 @@ xorpd       (%rax), %xmm2
 # CHECK-NEXT:  -      -      -      -      -     0.50   0.50   1.00   	movsd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movsd	(%rax), %xmm2
 # CHECK-NEXT:  -      -      -     0.50   0.50    -      -      -     	movupd	%xmm0, %xmm2
-# CHECK-NEXT:  -      -      -     0.50   0.50    -      -     1.00   	movupd	%xmm0, (%rax)
+# CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movupd	%xmm0, (%rax)
 # CHECK-NEXT:  -      -      -      -      -      -      -     1.00   	movupd	(%rax), %xmm2
 # CHECK-NEXT:  -      -     2.00   1.00    -      -      -      -     	mulpd	%xmm0, %xmm2
 # CHECK-NEXT:  -      -     2.00   1.00    -      -      -     1.00   	mulpd	(%rax), %xmm2




More information about the llvm-commits mailing list