summaryrefslogtreecommitdiff
path: root/test/CodeGen/PowerPC/tls_get_addr_stackframe.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/PowerPC/tls_get_addr_stackframe.ll')
-rw-r--r--test/CodeGen/PowerPC/tls_get_addr_stackframe.ll21
1 files changed, 8 insertions, 13 deletions
diff --git a/test/CodeGen/PowerPC/tls_get_addr_stackframe.ll b/test/CodeGen/PowerPC/tls_get_addr_stackframe.ll
index 4a235983e6f7b..5ce7dfc54117a 100644
--- a/test/CodeGen/PowerPC/tls_get_addr_stackframe.ll
+++ b/test/CodeGen/PowerPC/tls_get_addr_stackframe.ll
@@ -9,24 +9,19 @@
@tls_var = external thread_local global %struct1.2.41*, align 8
-define void @foo_test() {
+define i32 @foo_test() {
%1 = load %struct1.2.41*, %struct1.2.41** @tls_var, align 8
- br i1 undef, label %foo.exit, label %2
-; <label>:2 ; preds = %0
- br i1 undef, label %foo.exit, label %3
+ %2 = getelementptr inbounds %struct1.2.41, %struct1.2.41* %1, i64 0, i32 0, i32 3
+ %3 = load i32, i32* %2, align 8
+ %4 = add nsw i32 %3, -1
+ %5 = icmp eq i32 %4, 0
+ br i1 %5, label %bb7, label %foo.exit
-; <label>:3 ; preds = %2
- %4 = getelementptr inbounds %struct1.2.41, %struct1.2.41* %1, i64 0, i32 0, i32 3
- %5 = load i32, i32* %4, align 8
- %6 = add nsw i32 %5, -1
- %7 = icmp eq i32 %6, 0
- br i1 %7, label %8, label %foo.exit
-
-; <label>:8 ; preds = %3
+bb7: ; preds = %3
tail call void undef(%struct1.2.41* undef, %struct1.2.41* nonnull undef)
br label %foo.exit
foo.exit: ; preds = %8, %3, %2, %0
- ret void
+ ret i32 %4
}