summaryrefslogtreecommitdiffstats
path: root/qemu/tests/tcg/mips/mips64-dsp/repl_ob.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu/tests/tcg/mips/mips64-dsp/repl_ob.c')
-rw-r--r--qemu/tests/tcg/mips/mips64-dsp/repl_ob.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/qemu/tests/tcg/mips/mips64-dsp/repl_ob.c b/qemu/tests/tcg/mips/mips64-dsp/repl_ob.c
new file mode 100644
index 000000000..20cb78013
--- /dev/null
+++ b/qemu/tests/tcg/mips/mips64-dsp/repl_ob.c
@@ -0,0 +1,21 @@
+#include "io.h"
+
+int main(void)
+{
+ long long rd, result;
+ rd = 0;
+ result = 0xFFFFFFFFFFFFFFFF;
+
+ __asm
+ ("repl.ob %0, 0xFF\n\t"
+ : "=r"(rd)
+ );
+
+ if (result != rd) {
+ printf("repl.ob error\n");
+
+ return -1;
+ }
+
+ return 0;
+}