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

Unified Diff: tests_lit/assembler/arm32/vstr-vector.ll

Issue 1663053008: Fix vector load/stores in the ARM assembler. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix nits. Created 4 years, 10 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 | « tests_lit/assembler/arm32/vldr-vector.ll ('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/vstr-vector.ll
diff --git a/tests_lit/assembler/arm32/vstr-vector.ll b/tests_lit/assembler/arm32/vstr-vector.ll
new file mode 100644
index 0000000000000000000000000000000000000000..ea810bcd22d0e6e5c0be37a01c271643365c950b
--- /dev/null
+++ b/tests_lit/assembler/arm32/vstr-vector.ll
@@ -0,0 +1,78 @@
+; Show that we know how to translate vector store instructions.
+
+; Note: Uses -O2 to remove unnecessary loads/stores, resulting in only one VST1
+; instruction per function.
+
+; REQUIRES: allow_dump
+
+; Compile using standalone assembler.
+; RUN: %p2i --filetype=asm -i %s --target=arm32 --args -O2 \
+; RUN: -reg-use=q11,r5 \
+; RUN: | FileCheck %s --check-prefix=ASM
+
+; Show bytes in assembled standalone code.
+; RUN: %p2i --filetype=asm -i %s --target=arm32 --assemble --disassemble \
+; RUN: --args -O2 \
+; RUN: -reg-use=q11,r5 \
+; RUN: | FileCheck %s --check-prefix=DIS
+
+; Compile using integrated assembler.
+; RUN: %p2i --filetype=iasm -i %s --target=arm32 --args -O2 \
+; RUN: -reg-use=q11,r5 \
+; RUN: | FileCheck %s --check-prefix=IASM
+
+; Show bytes in assembled integrated code.
+; RUN: %p2i --filetype=iasm -i %s --target=arm32 --assemble --disassemble \
+; RUN: --args -O2 \
+; RUN: -reg-use=q11,r5 \
+; RUN: | FileCheck %s --check-prefix=DIS
+
+define internal void @testDerefFloat4(<4 x float>* %p, <4 x float> %v) {
+; ASM-LABEL: testDerefFloat4:
+; DIS-LABEL: {{.+}} <testDerefFloat4>:
+
+entry:
+ store <4 x float> %v, <4 x float>* %p, align 4
+; ASM: vst1.32 q11, [r5]
+; DIS: {{.+}}: f4456a8f
+; IASM-NOT: vst1.32
+
+ ret void
+}
+
+define internal void @testDeref4i32(<4 x i32> *%p, <4 x i32> %v) {
+; ASM-LABEL: testDeref4i32:
+; DIS-LABEL: {{.+}} <testDeref4i32>:
+
+entry:
+ store <4 x i32> %v, <4 x i32>* %p, align 4
+; ASM: vst1.32 q11, [r5]
+; DIS: {{.+}}: f4456a8f
+; IASM-NOT: vst1.32
+
+ ret void
+}
+
+define internal void @testDeref8i16(<8 x i16> *%p, <8 x i16> %v) {
+; ASM-LABEl: testDeref8i16:
+; DIS-LABEL: {{.+}} <testDeref8i16>:
+
+ store <8 x i16> %v, <8 x i16>* %p, align 2
+; ASM: vst1.16 q11, [r5]
+; DIS: {{.+}}: f4456a4f
+; IASM-NOT: vst1.16
+
+ ret void
+}
+
+define internal void @testDeref16i8(<16 x i8> *%p, <16 x i8> %v) {
+; ASM-LABEL: testDeref16i8:
+; DIS-LABEL: {{.+}} <testDeref16i8>:
+
+ store <16 x i8> %v, <16 x i8>* %p, align 1
+; ASM: vst1.8 q11, [r5]
+; DIS: {{.+}}: f4456a0f
+; IASM-NOT: vst1.8
+
+ ret void
+}
« no previous file with comments | « tests_lit/assembler/arm32/vldr-vector.ll ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698