• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=x86-64 -mattr=+adx | FileCheck %s --check-prefix=CHECK --check-prefix=GENERIC
3; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=broadwell | FileCheck %s --check-prefix=CHECK --check-prefix=BROADWELL
4; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=skylake | FileCheck %s --check-prefix=CHECK --check-prefix=SKYLAKE --check-prefix=SKL
5; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=skx     | FileCheck %s --check-prefix=CHECK --check-prefix=SKYLAKE --check-prefix=SKX
6; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=knl     | FileCheck %s --check-prefix=CHECK --check-prefix=KNL
7; RUN: llc < %s -mtriple=x86_64-unknown-unknown -print-schedule -mcpu=znver1  | FileCheck %s --check-prefix=CHECK --check-prefix=ZNVER1
8
9define void @test_adcx(i32 %a0, i32* %a1, i64 %a2, i64* %a3) optsize {
10; GENERIC-LABEL: test_adcx:
11; GENERIC:       # %bb.0:
12; GENERIC-NEXT:    #APP
13; GENERIC-NEXT:    adcxl %edi, %edi # sched: [2:0.67]
14; GENERIC-NEXT:    adcxq %rdx, %rdx # sched: [2:0.67]
15; GENERIC-NEXT:    adcxl (%rsi), %edi # sched: [7:0.67]
16; GENERIC-NEXT:    adcxq (%rcx), %rdx # sched: [7:0.67]
17; GENERIC-NEXT:    #NO_APP
18; GENERIC-NEXT:    retq # sched: [1:1.00]
19;
20; BROADWELL-LABEL: test_adcx:
21; BROADWELL:       # %bb.0:
22; BROADWELL-NEXT:    #APP
23; BROADWELL-NEXT:    adcxl %edi, %edi # sched: [1:0.50]
24; BROADWELL-NEXT:    adcxq %rdx, %rdx # sched: [1:0.50]
25; BROADWELL-NEXT:    adcxl (%rsi), %edi # sched: [6:0.50]
26; BROADWELL-NEXT:    adcxq (%rcx), %rdx # sched: [6:0.50]
27; BROADWELL-NEXT:    #NO_APP
28; BROADWELL-NEXT:    retq # sched: [7:1.00]
29;
30; SKYLAKE-LABEL: test_adcx:
31; SKYLAKE:       # %bb.0:
32; SKYLAKE-NEXT:    #APP
33; SKYLAKE-NEXT:    adcxl %edi, %edi # sched: [1:0.50]
34; SKYLAKE-NEXT:    adcxq %rdx, %rdx # sched: [1:0.50]
35; SKYLAKE-NEXT:    adcxl (%rsi), %edi # sched: [6:0.50]
36; SKYLAKE-NEXT:    adcxq (%rcx), %rdx # sched: [6:0.50]
37; SKYLAKE-NEXT:    #NO_APP
38; SKYLAKE-NEXT:    retq # sched: [7:1.00]
39;
40; KNL-LABEL: test_adcx:
41; KNL:       # %bb.0:
42; KNL-NEXT:    #APP
43; KNL-NEXT:    adcxl %edi, %edi # sched: [2:0.50]
44; KNL-NEXT:    adcxq %rdx, %rdx # sched: [2:0.50]
45; KNL-NEXT:    adcxl (%rsi), %edi # sched: [7:0.50]
46; KNL-NEXT:    adcxq (%rcx), %rdx # sched: [7:0.50]
47; KNL-NEXT:    #NO_APP
48; KNL-NEXT:    retq # sched: [7:1.00]
49;
50; ZNVER1-LABEL: test_adcx:
51; ZNVER1:       # %bb.0:
52; ZNVER1-NEXT:    #APP
53; ZNVER1-NEXT:    adcxl %edi, %edi # sched: [1:0.25]
54; ZNVER1-NEXT:    adcxq %rdx, %rdx # sched: [1:0.25]
55; ZNVER1-NEXT:    adcxl (%rsi), %edi # sched: [5:0.50]
56; ZNVER1-NEXT:    adcxq (%rcx), %rdx # sched: [5:0.50]
57; ZNVER1-NEXT:    #NO_APP
58; ZNVER1-NEXT:    retq # sched: [1:0.50]
59  tail call void asm "adcx $0, $0 \0A\09 adcx $2, $2 \0A\09 adcx $1, $0 \0A\09 adcx $3, $2", "r,*m,r,*m"(i32 %a0, i32* %a1, i64 %a2, i64* %a3) nounwind
60  ret void
61}
62define void @test_adox(i32 %a0, i32* %a1, i64 %a2, i64* %a3) optsize {
63; GENERIC-LABEL: test_adox:
64; GENERIC:       # %bb.0:
65; GENERIC-NEXT:    #APP
66; GENERIC-NEXT:    adoxl %edi, %edi # sched: [2:0.67]
67; GENERIC-NEXT:    adoxq %rdx, %rdx # sched: [2:0.67]
68; GENERIC-NEXT:    adoxl (%rsi), %edi # sched: [7:0.67]
69; GENERIC-NEXT:    adoxq (%rcx), %rdx # sched: [7:0.67]
70; GENERIC-NEXT:    #NO_APP
71; GENERIC-NEXT:    retq # sched: [1:1.00]
72;
73; BROADWELL-LABEL: test_adox:
74; BROADWELL:       # %bb.0:
75; BROADWELL-NEXT:    #APP
76; BROADWELL-NEXT:    adoxl %edi, %edi # sched: [1:0.50]
77; BROADWELL-NEXT:    adoxq %rdx, %rdx # sched: [1:0.50]
78; BROADWELL-NEXT:    adoxl (%rsi), %edi # sched: [6:0.50]
79; BROADWELL-NEXT:    adoxq (%rcx), %rdx # sched: [6:0.50]
80; BROADWELL-NEXT:    #NO_APP
81; BROADWELL-NEXT:    retq # sched: [7:1.00]
82;
83; SKYLAKE-LABEL: test_adox:
84; SKYLAKE:       # %bb.0:
85; SKYLAKE-NEXT:    #APP
86; SKYLAKE-NEXT:    adoxl %edi, %edi # sched: [1:0.50]
87; SKYLAKE-NEXT:    adoxq %rdx, %rdx # sched: [1:0.50]
88; SKYLAKE-NEXT:    adoxl (%rsi), %edi # sched: [6:0.50]
89; SKYLAKE-NEXT:    adoxq (%rcx), %rdx # sched: [6:0.50]
90; SKYLAKE-NEXT:    #NO_APP
91; SKYLAKE-NEXT:    retq # sched: [7:1.00]
92;
93; KNL-LABEL: test_adox:
94; KNL:       # %bb.0:
95; KNL-NEXT:    #APP
96; KNL-NEXT:    adoxl %edi, %edi # sched: [2:0.50]
97; KNL-NEXT:    adoxq %rdx, %rdx # sched: [2:0.50]
98; KNL-NEXT:    adoxl (%rsi), %edi # sched: [7:0.50]
99; KNL-NEXT:    adoxq (%rcx), %rdx # sched: [7:0.50]
100; KNL-NEXT:    #NO_APP
101; KNL-NEXT:    retq # sched: [7:1.00]
102;
103; ZNVER1-LABEL: test_adox:
104; ZNVER1:       # %bb.0:
105; ZNVER1-NEXT:    #APP
106; ZNVER1-NEXT:    adoxl %edi, %edi # sched: [1:0.25]
107; ZNVER1-NEXT:    adoxq %rdx, %rdx # sched: [1:0.25]
108; ZNVER1-NEXT:    adoxl (%rsi), %edi # sched: [5:0.50]
109; ZNVER1-NEXT:    adoxq (%rcx), %rdx # sched: [5:0.50]
110; ZNVER1-NEXT:    #NO_APP
111; ZNVER1-NEXT:    retq # sched: [1:0.50]
112  tail call void asm "adox $0, $0 \0A\09 adox $2, $2 \0A\09 adox $1, $0 \0A\09 adox $3, $2", "r,*m,r,*m"(i32 %a0, i32* %a1, i64 %a2, i64* %a3) nounwind
113  ret void
114}
115