blob: e184ce4c3b3e476308c482f09aea7db496c5b7b1 [file] [log] [blame]
Ulrich Weigand3707ba82016-03-31 15:37:06 +00001; RUN: llc -mtriple powerpc64-unknown-linux-gnu -fast-isel -O0 < %s | FileCheck %s
2
3; Verify that pointer offsets larger than 32 bits work correctly.
4
5define void @test(i32* %array) {
6; CHECK-LABEL: test:
7; CHECK: lis [[REG:[0-9]+]], 16383
8; CHECK: ori [[REG]], [[REG]], 65535
9; CHECK: sldi [[REG]], [[REG]], 3
10; CHECK: stwx {{[0-9]+}}, 3, [[REG]]
11 %element = getelementptr i32, i32* %array, i64 2147483646
12 store i32 1234, i32* %element
13 ret void
14}
15