summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2018-09-28 17:47:09 +0000
committerAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2018-09-28 17:47:09 +0000
commit6e218d0a571b637dd1400d701270f5b89cd7aa1b (patch)
treeb090979000396120d50b5e3c023f16ba5aea67c6 /llvm
parent58aed9fb2ec827cf339c96a18083e0c16185c482 (diff)
downloadbcm5719-llvm-6e218d0a571b637dd1400d701270f5b89cd7aa1b.tar.gz
bcm5719-llvm-6e218d0a571b637dd1400d701270f5b89cd7aa1b.zip
[llvm-mca] Add a test for zero-idiom VPERM2F128rr. NFC
We don't correctly model the latency and resource usage information for zero-idiom VPERM2F128rr on Jaguar. This is demonstrated by the incorrect numbers in the resource pressure view, and the timeline view. A follow up patch will fix this problem. llvm-svn: 343346
Diffstat (limited to 'llvm')
-rw-r--r--llvm/test/tools/llvm-mca/X86/BtVer2/zero-idioms-avx-256.s75
1 files changed, 75 insertions, 0 deletions
diff --git a/llvm/test/tools/llvm-mca/X86/BtVer2/zero-idioms-avx-256.s b/llvm/test/tools/llvm-mca/X86/BtVer2/zero-idioms-avx-256.s
index af589af84e9..7600368c7c0 100644
--- a/llvm/test/tools/llvm-mca/X86/BtVer2/zero-idioms-avx-256.s
+++ b/llvm/test/tools/llvm-mca/X86/BtVer2/zero-idioms-avx-256.s
@@ -31,6 +31,11 @@ vaddps %ymm0, %ymm1, %ymm2
vandnps %ymm2, %ymm2, %ymm3
# LLVM-MCA-END
+# LLVM-MCA-BEGIN ZERO-IDIOM-5
+vperm2f128 $136, %ymm0, %ymm0, %ymm1
+vaddps %ymm1, %ymm1, %ymm0
+# LLVM-MCA-END
+
# CHECK: [0] Code Region - ZERO-IDIOM-1
# CHECK: Iterations: 100
@@ -320,3 +325,73 @@ vandnps %ymm2, %ymm2, %ymm3
# CHECK: [0] [1] [2] [3]
# CHECK-NEXT: 0. 3 1.0 1.0 0.0 vaddps %ymm0, %ymm1, %ymm2
# CHECK-NEXT: 1. 3 1.0 1.0 1.0 vandnps %ymm2, %ymm2, %ymm3
+
+# CHECK: [4] Code Region - ZERO-IDIOM-5
+
+# CHECK: Iterations: 100
+# CHECK-NEXT: Instructions: 200
+# CHECK-NEXT: Total Cycles: 403
+# CHECK-NEXT: Total uOps: 400
+
+# CHECK: Dispatch Width: 2
+# CHECK-NEXT: uOps Per Cycle: 0.99
+# CHECK-NEXT: IPC: 0.50
+# CHECK-NEXT: Block RThroughput: 2.0
+
+# CHECK: Instruction Info:
+# CHECK-NEXT: [1]: #uOps
+# CHECK-NEXT: [2]: Latency
+# CHECK-NEXT: [3]: RThroughput
+# CHECK-NEXT: [4]: MayLoad
+# CHECK-NEXT: [5]: MayStore
+# CHECK-NEXT: [6]: HasSideEffects (U)
+
+# CHECK: [1] [2] [3] [4] [5] [6] Instructions:
+# CHECK-NEXT: 2 1 1.00 vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: 2 3 2.00 vaddps %ymm1, %ymm1, %ymm0
+
+# CHECK: Resources:
+# CHECK-NEXT: [0] - JALU0
+# CHECK-NEXT: [1] - JALU1
+# CHECK-NEXT: [2] - JDiv
+# CHECK-NEXT: [3] - JFPA
+# CHECK-NEXT: [4] - JFPM
+# CHECK-NEXT: [5] - JFPU0
+# CHECK-NEXT: [6] - JFPU1
+# CHECK-NEXT: [7] - JLAGU
+# CHECK-NEXT: [8] - JMul
+# CHECK-NEXT: [9] - JSAGU
+# CHECK-NEXT: [10] - JSTC
+# CHECK-NEXT: [11] - JVALU0
+# CHECK-NEXT: [12] - JVALU1
+# CHECK-NEXT: [13] - JVIMUL
+
+# CHECK: Resource pressure per iteration:
+# CHECK-NEXT: [0] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]
+# CHECK-NEXT: - - - 2.00 2.00 2.00 2.00 - - - - - - -
+
+# CHECK: Resource pressure by instruction:
+# CHECK-NEXT: [0] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] Instructions:
+# CHECK-NEXT: - - - - 2.00 - 2.00 - - - - - - - vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: - - - 2.00 - 2.00 - - - - - - - - vaddps %ymm1, %ymm1, %ymm0
+
+# CHECK: Timeline view:
+# CHECK-NEXT: 01234
+# CHECK-NEXT: Index 0123456789
+
+# CHECK: [0,0] DeER . . . vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: [0,1] .DeeeER . . vaddps %ymm1, %ymm1, %ymm0
+# CHECK-NEXT: [1,0] . D==eER . . vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: [1,1] . D==eeeER . vaddps %ymm1, %ymm1, %ymm0
+# CHECK-NEXT: [2,0] . D====eER . vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: [2,1] . D====eeeER vaddps %ymm1, %ymm1, %ymm0
+
+# CHECK: Average Wait times (based on the timeline view):
+# CHECK-NEXT: [0]: Executions
+# CHECK-NEXT: [1]: Average time spent waiting in a scheduler's queue
+# CHECK-NEXT: [2]: Average time spent waiting in a scheduler's queue while ready
+# CHECK-NEXT: [3]: Average time elapsed from WB until retire stage
+
+# CHECK: [0] [1] [2] [3]
+# CHECK-NEXT: 0. 3 3.0 0.3 0.0 vperm2f128 $136, %ymm0, %ymm0, %ymm1
+# CHECK-NEXT: 1. 3 3.0 0.0 0.0 vaddps %ymm1, %ymm1, %ymm0
OpenPOWER on IntegriCloud