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

Unified Diff: tests_lit/assembler/arm32/trap.ll

Issue 1654483002: Fix nits in committed CL's for the integrated ARM assembler. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 4 years, 11 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/IceInstARM32.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests_lit/assembler/arm32/trap.ll
diff --git a/tests_lit/assembler/arm32/trap.ll b/tests_lit/assembler/arm32/trap.ll
index 5246e527ef689565be7fda485c7c1a7e87277d64..52a5a12d57be5e90d69b0f3e5c0d48c87138d725 100644
--- a/tests_lit/assembler/arm32/trap.ll
+++ b/tests_lit/assembler/arm32/trap.ll
@@ -1,8 +1,5 @@
; Show that we can translate IR instruction "trap".
-; Note: We use integer division to test this, since a trap is inserted
-; if one divides by zero.
-
; REQUIRES: allow_dump
; Compile using standalone assembler.
@@ -23,20 +20,36 @@
; RUN: --args -Om1 \
; RUN: | FileCheck %s --check-prefix=DIS
+; testUnreachable generates a trap for the unreachable instruction.
+
+define internal void @testUnreachable() {
+; ASM-LABEL: testUnreachable:
+; DIS-LABEL: 00000000 <testUnreachable>:
+
+ unreachable
+
+; ASM: .long 0xe7fedef0
+; DIS-NEXT: 0: e7fedef0
+; IASM-NOT: .long 0xe7fedef0
+}
+
+; testTrap uses integer division to test this, since a trap is
+; inserted if one divides by zero.
+
define internal i32 @testTrap(i32 %v1, i32 %v2) {
; ASM-LABEL: testTrap:
-; DIS-LABEL: 00000000 <testTrap>:
+; DIS-LABEL: 00000010 <testTrap>:
; IASM-LABEL: testTrap:
%res = udiv i32 %v1, %v2
; ASM: bne
-; DIS: 18: 1a000000
+; DIS: 28: 1a000000
; IASM-NOT: bne
; ASM-NEXT: .long 0xe7fedef0
-; DIS-NEXT: 1c: e7fedef0
-; IASM-NOT: .long
+; DIS-NEXT: 2c: e7fedef0
+; IASM-NOT: .long 0xe7fedef0
ret i32 %res
}
« no previous file with comments | « src/IceInstARM32.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698