1; RUN: llc -march=hexagon -hexagon-small-data-threshold=0 < %s | FileCheck %s
2
3; Check that CONST32/CONST64 instructions are 'not' generated when the
4; small data threshold is set to 0.
5
6@a = external global i32
7@b = external global i32
8@la = external global i64
9@lb = external global i64
10
11; CHECK-LABEL: test1:
12; CHECK-NOT: CONST32
13define void @test1() nounwind {
14entry:
15  br label %block
16block:
17  store i32 12345670, i32* @a, align 4
18  %q = ptrtoint i8* blockaddress (@test1, %block) to i32
19  store i32 %q, i32* @b, align 4
20  ret void
21}
22
23; CHECK-LABEL: test2:
24; CHECK-NOT: CONST64
25define void @test2() nounwind {
26entry:
27  store i64 1234567890123, i64* @la, align 8
28  store i64 1234567890123, i64* @lb, align 8
29  ret void
30}
31