Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(272)

Unified Diff: test/NaCl/Bitcode/inttoptr-elide.ll

Issue 1151093004: Changes from 3.7 merge to files not in upstream (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: test/NaCl/Bitcode/inttoptr-elide.ll
diff --git a/test/NaCl/Bitcode/inttoptr-elide.ll b/test/NaCl/Bitcode/inttoptr-elide.ll
index c772b5715253edd7219a79fdecc8424b68e2c1ce..2ccc47b4ecfbf1915ab972a2e9e5f8317210a78f 100644
--- a/test/NaCl/Bitcode/inttoptr-elide.ll
+++ b/test/NaCl/Bitcode/inttoptr-elide.ll
@@ -13,13 +13,13 @@
; Test that we elide the simple case of inttoptr of a load.
define void @SimpleLoad(i32 %i) {
%1 = inttoptr i32 %i to i32*
- %2 = load i32* %1, align 4
+ %2 = load i32, i32* %1, align 4
ret void
}
; TD2: define void @SimpleLoad(i32 %i) {
; TD2-NEXT: %1 = inttoptr i32 %i to i32*
-; TD2-NEXT: %2 = load i32* %1, align 4
+; TD2-NEXT: %2 = load i32, i32* %1, align 4
; TD2-NEXT: ret void
; TD2-NEXT: }
@@ -34,17 +34,17 @@ define void @SimpleLoad(i32 %i) {
; Test that we can handle multiple inttoptr of loads.
define i32 @TwoLoads(i32 %i) {
%1 = inttoptr i32 %i to i32*
- %2 = load i32* %1, align 4
+ %2 = load i32, i32* %1, align 4
%3 = inttoptr i32 %i to i32*
- %4 = load i32* %3, align 4
+ %4 = load i32, i32* %3, align 4
%5 = add i32 %2, %4
ret i32 %5
}
; TD2: define i32 @TwoLoads(i32 %i) {
; TD2-NEXT: %1 = inttoptr i32 %i to i32*
-; TD2-NEXT: %2 = load i32* %1, align 4
-; TD2-NEXT: %3 = load i32* %1, align 4
+; TD2-NEXT: %2 = load i32, i32* %1, align 4
+; TD2-NEXT: %3 = load i32, i32* %1, align 4
; TD2-NEXT: %4 = add i32 %2, %3
; TD2-NEXT: ret i32 %4
; TD2-NEXT: }
@@ -63,16 +63,16 @@ define i32 @TwoLoads(i32 %i) {
; case tests within a single block.
define i32 @TwoLoadOptOneBlock(i32 %i) {
%1 = inttoptr i32 %i to i32*
- %2 = load i32* %1, align 4
- %3 = load i32* %1, align 4
+ %2 = load i32, i32* %1, align 4
+ %3 = load i32, i32* %1, align 4
%4 = add i32 %2, %3
ret i32 %4
}
; TD2: define i32 @TwoLoadOptOneBlock(i32 %i) {
; TD2-NEXT: %1 = inttoptr i32 %i to i32*
-; TD2-NEXT: %2 = load i32* %1, align 4
-; TD2-NEXT: %3 = load i32* %1, align 4
+; TD2-NEXT: %2 = load i32, i32* %1, align 4
+; TD2-NEXT: %3 = load i32, i32* %1, align 4
; TD2-NEXT: %4 = add i32 %2, %3
; TD2-NEXT: ret i32 %4
; TD2-NEXT: }
@@ -91,28 +91,28 @@ define i32 @TwoLoadOptOneBlock(i32 %i) {
; case tests accross blocks.
define i32 @TwoLoadOptTwoBlocks(i32 %i) {
%1 = inttoptr i32 %i to i32*
- %2 = load i32* %1, align 4
- %3 = load i32* %1, align 4
+ %2 = load i32, i32* %1, align 4
+ %3 = load i32, i32* %1, align 4
%4 = add i32 %2, %3
br label %BB
BB:
- %5 = load i32* %1, align 4
- %6 = load i32* %1, align 4
+ %5 = load i32, i32* %1, align 4
+ %6 = load i32, i32* %1, align 4
%7 = add i32 %5, %6
ret i32 %7
}
; TD2: define i32 @TwoLoadOptTwoBlocks(i32 %i) {
; TD2-NEXT: %1 = inttoptr i32 %i to i32*
-; TD2-NEXT: %2 = load i32* %1, align 4
-; TD2-NEXT: %3 = load i32* %1, align 4
+; TD2-NEXT: %2 = load i32, i32* %1, align 4
+; TD2-NEXT: %3 = load i32, i32* %1, align 4
; TD2-NEXT: %4 = add i32 %2, %3
; TD2-NEXT: br label %BB
; TD2: BB:
; TD2-NEXT: %5 = inttoptr i32 %i to i32*
-; TD2-NEXT: %6 = load i32* %5, align 4
-; TD2-NEXT: %7 = load i32* %5, align 4
+; TD2-NEXT: %6 = load i32, i32* %5, align 4
+; TD2-NEXT: %7 = load i32, i32* %5, align 4
; TD2-NEXT: %8 = add i32 %6, %7
; TD2-NEXT: ret i32 %8
; TD2-NEXT: }

Powered by Google App Engine
This is Rietveld 408576698