[InstCombine] Signed saturation patterns
[llvm-complete.git] / test / tools / llvm-mca / X86 / BtVer2 / dependency-breaking-cmp.s
blob25762ec14ad3b3f5d623898dd3bbddfb17ba69ff
1 # NOTE: Assertions have been autogenerated by utils/update_mca_test_checks.py
2 # RUN: llvm-mca -mtriple=x86_64-unknown-unknown -mcpu=btver2 -timeline -timeline-max-iterations=3 -iterations=1500 < %s | FileCheck %s
4 # Perf stat reports an IPC of 1.97 for this block of code.
6 # The CMP instruction doesn't depend on the value of EAX. It can set the flags
7 # without having to read the inputs.
9 cmp %eax, %eax
10 cmovae %ebx, %eax
12 # CHECK: Iterations: 1500
13 # CHECK-NEXT: Instructions: 3000
14 # CHECK-NEXT: Total Cycles: 1504
15 # CHECK-NEXT: Total uOps: 3000
17 # CHECK: Dispatch Width: 2
18 # CHECK-NEXT: uOps Per Cycle: 1.99
19 # CHECK-NEXT: IPC: 1.99
20 # CHECK-NEXT: Block RThroughput: 1.0
22 # CHECK: Instruction Info:
23 # CHECK-NEXT: [1]: #uOps
24 # CHECK-NEXT: [2]: Latency
25 # CHECK-NEXT: [3]: RThroughput
26 # CHECK-NEXT: [4]: MayLoad
27 # CHECK-NEXT: [5]: MayStore
28 # CHECK-NEXT: [6]: HasSideEffects (U)
30 # CHECK: [1] [2] [3] [4] [5] [6] Instructions:
31 # CHECK-NEXT: 1 1 0.50 cmpl %eax, %eax
32 # CHECK-NEXT: 1 1 0.50 cmovael %ebx, %eax
34 # CHECK: Resources:
35 # CHECK-NEXT: [0] - JALU0
36 # CHECK-NEXT: [1] - JALU1
37 # CHECK-NEXT: [2] - JDiv
38 # CHECK-NEXT: [3] - JFPA
39 # CHECK-NEXT: [4] - JFPM
40 # CHECK-NEXT: [5] - JFPU0
41 # CHECK-NEXT: [6] - JFPU1
42 # CHECK-NEXT: [7] - JLAGU
43 # CHECK-NEXT: [8] - JMul
44 # CHECK-NEXT: [9] - JSAGU
45 # CHECK-NEXT: [10] - JSTC
46 # CHECK-NEXT: [11] - JVALU0
47 # CHECK-NEXT: [12] - JVALU1
48 # CHECK-NEXT: [13] - JVIMUL
50 # CHECK: Resource pressure per iteration:
51 # CHECK-NEXT: [0] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]
52 # CHECK-NEXT: 1.00 1.00 - - - - - - - - - - - -
54 # CHECK: Resource pressure by instruction:
55 # CHECK-NEXT: [0] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] Instructions:
56 # CHECK-NEXT: - 1.00 - - - - - - - - - - - - cmpl %eax, %eax
57 # CHECK-NEXT: 1.00 - - - - - - - - - - - - - cmovael %ebx, %eax
59 # CHECK: Timeline view:
60 # CHECK-NEXT: Index 0123456
62 # CHECK: [0,0] DeER .. cmpl %eax, %eax
63 # CHECK-NEXT: [0,1] D=eER.. cmovael %ebx, %eax
64 # CHECK-NEXT: [1,0] .DeER.. cmpl %eax, %eax
65 # CHECK-NEXT: [1,1] .D=eER. cmovael %ebx, %eax
66 # CHECK-NEXT: [2,0] . DeER. cmpl %eax, %eax
67 # CHECK-NEXT: [2,1] . D=eER cmovael %ebx, %eax
69 # CHECK: Average Wait times (based on the timeline view):
70 # CHECK-NEXT: [0]: Executions
71 # CHECK-NEXT: [1]: Average time spent waiting in a scheduler's queue
72 # CHECK-NEXT: [2]: Average time spent waiting in a scheduler's queue while ready
73 # CHECK-NEXT: [3]: Average time elapsed from WB until retire stage
75 # CHECK: [0] [1] [2] [3]
76 # CHECK-NEXT: 0. 3 1.0 1.0 0.0 cmpl %eax, %eax
77 # CHECK-NEXT: 1. 3 2.0 0.0 0.0 cmovael %ebx, %eax
78 # CHECK-NEXT: 3 1.5 0.5 0.0 <total>