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

Unified Diff: tests_lit/assembler/mips32/encoding_trap.ll

Issue 2350903002: Subzero, MIPS32: lowerUnreachable (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Rebasing, addressing review comments Created 4 years, 3 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/IceTargetLoweringMIPS32.cpp ('k') | tests_lit/llvm2ice_tests/unreachable.ll » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests_lit/assembler/mips32/encoding_trap.ll
diff --git a/tests_lit/assembler/mips32/encoding_trap.ll b/tests_lit/assembler/mips32/encoding_trap.ll
new file mode 100644
index 0000000000000000000000000000000000000000..a6a86e9e4b60edc1bbdce71792bb358b216c8b39
--- /dev/null
+++ b/tests_lit/assembler/mips32/encoding_trap.ll
@@ -0,0 +1,41 @@
+; Test encoding of MIPS32 floating point arithmetic instructions
+
+; REQUIRES: allow_dump
+
+; Compile using standalone assembler.
+; RUN: %p2i --filetype=asm -i %s --target=mips32 --args -O2 \
+; RUN: --allow-externally-defined-symbols --skip-unimplemented \
+; RUN: | FileCheck %s --check-prefix=ASM
+
+; Show bytes in assembled standalone code.
+; RUN: %p2i --filetype=asm -i %s --target=mips32 --assemble --disassemble \
+; RUN: --args -O2 --allow-externally-defined-symbols --skip-unimplemented \
+; RUN: | FileCheck %s --check-prefix=DIS
+
+; Compile using integrated assembler.
+; RUN: %p2i --filetype=iasm -i %s --target=mips32 --args -O2 \
+; RUN: --allow-externally-defined-symbols --skip-unimplemented \
+; RUN: | FileCheck %s --check-prefix=IASM
+
+; Show bytes in assembled integrated code.
+; RUN: %p2i --filetype=iasm -i %s --target=mips32 --assemble --disassemble \
+; RUN: --args -O2 --allow-externally-defined-symbols --skip-unimplemented \
+; RUN: | FileCheck %s --check-prefix=DIS
+
+define internal void @encTrap() {
+ unreachable
+}
+
+; ASM-LABEL: encTrap
+; ASM-NEXT: .LencTrap$__0:
+; ASM-NEXT: teq $zero, $zero, 0
+
+; DIS-LABEL: 00000000 <encTrap>:
+; DIS-NEXT: 0: 00000034 teq zero,zero
+
+; IASM-LABEL: encTrap:
+; IASM-NEXT: .LencTrap$__0:
+; IASM-NEXT: .byte 0x34
+; IASM-NEXT: .byte 0x0
+; IASM-NEXT: .byte 0x0
+; IASM-NEXT: .byte 0x0
« no previous file with comments | « src/IceTargetLoweringMIPS32.cpp ('k') | tests_lit/llvm2ice_tests/unreachable.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698