aboutsummaryrefslogtreecommitdiff
path: root/tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c')
-rw-r--r--tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c b/tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c
new file mode 100644
index 0000000000..fa95c26cc4
--- /dev/null
+++ b/tests/tcg/mips/user/ase/dsp/test_dsp_r1_preceu_ph_qbl.c
@@ -0,0 +1,20 @@
+#include<stdio.h>
+#include<assert.h>
+
+int main()
+{
+ int rd, rt;
+ int result;
+
+ rt = 0x87654321;
+ result = 0x00870065;
+
+ __asm
+ ("preceu.ph.qbl %0, %1\n\t"
+ : "=r"(rd)
+ : "r"(rt)
+ );
+ assert(result == rd);
+
+ return 0;
+}