1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=x86_64-linux-gnu -run-pass=instruction-select -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=ALL
5 define i8 @test_or_i8(i8 %arg1, i8 %arg2) {
6 %ret = or i8 %arg1, %arg2
10 define i16 @test_or_i16(i16 %arg1, i16 %arg2) {
11 %ret = or i16 %arg1, %arg2
15 define i32 @test_or_i32(i32 %arg1, i32 %arg2) {
16 %ret = or i32 %arg1, %arg2
20 define i64 @test_or_i64(i64 %arg1, i64 %arg2) {
21 %ret = or i64 %arg1, %arg2
32 - { id: 0, class: gpr, preferred-register: '' }
33 - { id: 1, class: gpr, preferred-register: '' }
34 - { id: 2, class: gpr, preferred-register: '' }
43 ; ALL-LABEL: name: test_or_i8
44 ; ALL: [[COPY:%[0-9]+]]:gr8 = COPY $dil
45 ; ALL: [[COPY1:%[0-9]+]]:gr8 = COPY $sil
46 ; ALL: [[OR8rr:%[0-9]+]]:gr8 = OR8rr [[COPY]], [[COPY1]], implicit-def $eflags
47 ; ALL: $al = COPY [[OR8rr]]
48 ; ALL: RET 0, implicit $al
62 - { id: 0, class: gpr, preferred-register: '' }
63 - { id: 1, class: gpr, preferred-register: '' }
64 - { id: 2, class: gpr, preferred-register: '' }
73 ; ALL-LABEL: name: test_or_i16
74 ; ALL: [[COPY:%[0-9]+]]:gr16 = COPY $di
75 ; ALL: [[COPY1:%[0-9]+]]:gr16 = COPY $si
76 ; ALL: [[OR16rr:%[0-9]+]]:gr16 = OR16rr [[COPY]], [[COPY1]], implicit-def $eflags
77 ; ALL: $ax = COPY [[OR16rr]]
78 ; ALL: RET 0, implicit $ax
92 - { id: 0, class: gpr, preferred-register: '' }
93 - { id: 1, class: gpr, preferred-register: '' }
94 - { id: 2, class: gpr, preferred-register: '' }
103 ; ALL-LABEL: name: test_or_i32
104 ; ALL: [[COPY:%[0-9]+]]:gr32 = COPY $edi
105 ; ALL: [[COPY1:%[0-9]+]]:gr32 = COPY $esi
106 ; ALL: [[OR32rr:%[0-9]+]]:gr32 = OR32rr [[COPY]], [[COPY1]], implicit-def $eflags
107 ; ALL: $eax = COPY [[OR32rr]]
108 ; ALL: RET 0, implicit $eax
111 %2(s32) = G_OR %0, %1
120 regBankSelected: true
122 - { id: 0, class: gpr, preferred-register: '' }
123 - { id: 1, class: gpr, preferred-register: '' }
124 - { id: 2, class: gpr, preferred-register: '' }
133 ; ALL-LABEL: name: test_or_i64
134 ; ALL: [[COPY:%[0-9]+]]:gr64 = COPY $rdi
135 ; ALL: [[COPY1:%[0-9]+]]:gr64 = COPY $rsi
136 ; ALL: [[OR64rr:%[0-9]+]]:gr64 = OR64rr [[COPY]], [[COPY1]], implicit-def $eflags
137 ; ALL: $rax = COPY [[OR64rr]]
138 ; ALL: RET 0, implicit $rax
141 %2(s64) = G_OR %0, %1