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

Unified Diff: tests_lit/assembler/arm32/vabs-vec.ll

Issue 1697263007: Add fabs(<4 x float>) to the integrated 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 | « src/IceTargetLoweringARM32.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/vabs-vec.ll
diff --git a/tests_lit/assembler/arm32/vmrs.ll b/tests_lit/assembler/arm32/vabs-vec.ll
similarity index 55%
copy from tests_lit/assembler/arm32/vmrs.ll
copy to tests_lit/assembler/arm32/vabs-vec.ll
index f635389bf9ffbe9c226c090f9dd8cb392ddbbee8..fc47d39ed11bcd2008493a15247efd55d123c4c3 100644
--- a/tests_lit/assembler/arm32/vmrs.ll
+++ b/tests_lit/assembler/arm32/vabs-vec.ll
@@ -1,38 +1,41 @@
-; Test the "vmrs APSR_nzcv, FPSCR" form of the VMRS instruction.
+; Show that we know how to translate the fabs intrinsic on float vectors.
; REQUIRES: allow_dump
; Compile using standalone assembler.
; RUN: %p2i --filetype=asm -i %s --target=arm32 --args -Om1 \
+; RUN: -reg-use q5 \
; RUN: | FileCheck %s --check-prefix=ASM
; Show bytes in assembled standalone code.
; RUN: %p2i --filetype=asm -i %s --target=arm32 --assemble --disassemble \
; RUN: --args -Om1 \
+; RUN: -reg-use q5 \
; RUN: | FileCheck %s --check-prefix=DIS
; Compile using integrated assembler.
; RUN: %p2i --filetype=iasm -i %s --target=arm32 --args -Om1 \
+; RUN: -reg-use q5 \
; RUN: | FileCheck %s --check-prefix=IASM
; Show bytes in assembled integrated code.
; RUN: %p2i --filetype=iasm -i %s --target=arm32 --assemble --disassemble \
; RUN: --args -Om1 \
+; RUN: -reg-use q5 \
; RUN: | FileCheck %s --check-prefix=DIS
-define internal i32 @testVmrsASPR_nzcv() {
-; ASM-LABEL: testVmrsASPR_nzcv:
-; DIS-LABEL: 00000000 <testVmrsASPR_nzcv>:
+declare <4 x float> @llvm.fabs.v4f32(<4 x float>)
-entry:
-; ASM: .LtestVmrsASPR_nzcv$entry:
+define internal <4 x float> @_Z6myFabsDv4_f(<4 x float> %a) {
+; ASM-LABEL: _Z6myFabsDv4_f:
+; DIS-LABEL: {{.+}} <_Z6myFabsDv4_f>:
+; IASM-LABEL: _Z6myFabsDv4_f:
- %test = fcmp olt float 0.0, 0.0
+ %x = call <4 x float> @llvm.fabs.v4f32(<4 x float> %a)
-; ASM: vmrs APSR_nzcv, FPSCR
-; DIS: 14: eef1fa10
-; IASM-NOT: vmrs
+; ASM: vabs.f32 q5, q5
+; DIS: {{.+}}: f3b9a74a
+; IASM-NOT: vabs.f32
- %result = zext i1 %test to i32
- ret i32 %result
+ ret <4 x float> %x
}
« no previous file with comments | « src/IceTargetLoweringARM32.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698