aboutsummaryrefslogtreecommitdiff
path: root/sim/testsuite/mips64vr5900el-elf/t-pmadduw.s
diff options
context:
space:
mode:
Diffstat (limited to 'sim/testsuite/mips64vr5900el-elf/t-pmadduw.s')
-rw-r--r--sim/testsuite/mips64vr5900el-elf/t-pmadduw.s33
1 files changed, 33 insertions, 0 deletions
diff --git a/sim/testsuite/mips64vr5900el-elf/t-pmadduw.s b/sim/testsuite/mips64vr5900el-elf/t-pmadduw.s
new file mode 100644
index 0000000..8335f49
--- /dev/null
+++ b/sim/testsuite/mips64vr5900el-elf/t-pmadduw.s
@@ -0,0 +1,33 @@
+.include "t-macros.i"
+
+ start
+
+test_pmadduw:
+ load $6 0x0123456780000000 0x89abcdef7fffffff
+ load $7 0x0123456780000000 0x89abcdef7fffffff
+ load $8 0x0123456700000000 0x89abcdefffffffff
+ load $9 0x012345677fffffff 0x89abcdef80000000
+ pmthi $8
+ pmtlo $9
+ nop
+ nop
+ pmadduw $10,$6,$7 #Expectation:
+ check10 0x400000007fffffff 0x3ffffffe80000001
+ checkHI 0x0000000040000000 0x000000003ffffffe
+ checkLO 0x000000007fffffff 0xffffffff80000001
+
+test_pmadduw2:
+ load $6 0x0123456780000000 0x89abcdef7fffffff
+ load $7 0x0123456780000000 0x89abcdef7fffffff
+ load $8 0x01234567ffffffff 0x89abcdef00000000
+ load $9 0x0123456780000000 0x89abcdef7fffffff
+ pmthi $8
+ pmtlo $9
+ nop
+ nop
+ pmadduw $10,$6,$7 #Expectation:
+ check10 0x3fffffff80000000 0x3fffffff80000000
+ checkHI 0x000000003fffffff 0x000000003fffffff
+ checkLO 0xffffffff80000000 0xffffffff80000000
+
+ exit0