• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; All of these routines should be perform optimal load of constants.
2; RUN: llc -verify-machineinstrs < %s -mtriple=ppc32-- | \
3; RUN:   grep lis | count 5
4; RUN: llc -verify-machineinstrs < %s -mtriple=ppc32-- | \
5; RUN:   grep ori | count 3
6; RUN: llc -verify-machineinstrs < %s -mtriple=ppc32-- | \
7; RUN:   grep "li " | count 4
8
9define i32 @f1() {
10entry:
11	ret i32 1
12}
13
14define i32 @f2() {
15entry:
16	ret i32 -1
17}
18
19define i32 @f3() {
20entry:
21	ret i32 0
22}
23
24define i32 @f4() {
25entry:
26	ret i32 32767
27}
28
29define i32 @f5() {
30entry:
31	ret i32 65535
32}
33
34define i32 @f6() {
35entry:
36	ret i32 65536
37}
38
39define i32 @f7() {
40entry:
41	ret i32 131071
42}
43
44define i32 @f8() {
45entry:
46	ret i32 2147483647
47}
48
49define i32 @f9() {
50entry:
51	ret i32 -2147483648
52}
53