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

Unified Diff: tests_lit/llvm2ice_tests/address-mode-opt.ll

Issue 2124973005: Selectively invert ICMP operands for better address optimization (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Address Comments Created 4 years, 5 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
« no previous file with comments | « src/IceTargetLoweringX86BaseImpl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests_lit/llvm2ice_tests/address-mode-opt.ll
diff --git a/tests_lit/llvm2ice_tests/address-mode-opt.ll b/tests_lit/llvm2ice_tests/address-mode-opt.ll
index ccd301c4e8789d780060af78194f09db5fe0fd21..fd15998bde4b28e8948106077dd310a1c9f02f33 100644
--- a/tests_lit/llvm2ice_tests/address-mode-opt.ll
+++ b/tests_lit/llvm2ice_tests/address-mode-opt.ll
@@ -187,3 +187,20 @@ entry:
; CHECK: or
; CHECK-NOT: movss xmm{{[0-9]+}},DWORD PTR [{{e..}}*4+0xFFFF]
}
+
+define internal void @invert_icmp(i32* %arg1, i32* %arg2) {
+entry:
+ %addr.other = load i32, i32* %arg2, align 1
+ br label %next
+next:
+ %addr.load = load i32, i32* %arg1, align 1
+ %cond = icmp slt i32 %addr.load, %addr.other
+ br i1 %cond, label %if.then, label %if.else
+if.then:
+ ret void
+if.else:
+ ret void
+; CHECK-LABEL: invert_icmp
+; CHECK: cmp {{e..}},DWORD PTR [{{e..}}]
+; CHECK: jle
+}
« no previous file with comments | « src/IceTargetLoweringX86BaseImpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698