blob: be1895cefaf84dd93c4257a25d32269cb357ef3b [file] [log] [blame]
Ehsan Amiria538b0f2016-08-03 18:17:35 +00001; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s
Tim Shenf99f0d52016-02-03 20:58:55 +00002
3; CHECK-LABEL: TestFoo:
4; CHECK: std
5; CHECK: bl TestBar
6; CHECK: stbu
7; CHECK: std
8; CHECK: blr
9
10%StructA = type <{ i64, { i64, i64 }, { i64, i64 } }>
11
12define void @TestFoo(%StructA* %this) {
13 %tmp = getelementptr inbounds %StructA, %StructA* %this, i64 0, i32 1
14 %tmp11 = getelementptr inbounds %StructA, %StructA* %this, i64 0, i32 1, i32 1
15 %tmp12 = bitcast { i64, i64 }* %tmp to i64**
16 store i64* %tmp11, i64** %tmp12
17 call void @TestBar()
18 %tmp13 = getelementptr inbounds %StructA, %StructA* %this, i64 0, i32 2, i32 1
19 store i64* %tmp13, i64** undef
20 %.cast.i.i.i = bitcast i64* %tmp13 to i8*
21 store i8 0, i8* %.cast.i.i.i
22 ret void
23}
24
25declare void @TestBar()