• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; Test moves between GPRs.
2;
3; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
4
5; Test 8-bit moves, which should get promoted to i32.
6define i8 @f1(i8 %a, i8 %b) {
7; CHECK-LABEL: f1:
8; CHECK: lr %r2, %r3
9; CHECK: br %r14
10  ret i8 %b
11}
12
13; Test 16-bit moves, which again should get promoted to i32.
14define i16 @f2(i16 %a, i16 %b) {
15; CHECK-LABEL: f2:
16; CHECK: lr %r2, %r3
17; CHECK: br %r14
18  ret i16 %b
19}
20
21; Test 32-bit moves.
22define i32 @f3(i32 %a, i32 %b) {
23; CHECK-LABEL: f3:
24; CHECK: lr %r2, %r3
25; CHECK: br %r14
26  ret i32 %b
27}
28
29; Test 64-bit moves.
30define i64 @f4(i64 %a, i64 %b) {
31; CHECK-LABEL: f4:
32; CHECK: lgr %r2, %r3
33; CHECK: br %r14
34  ret i64 %b
35}
36