aboutsummaryrefslogtreecommitdiff
path: root/thumb.risu
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2011-03-10 18:23:02 +0000
committerPeter Maydell <peter.maydell@linaro.org>2011-03-10 18:23:02 +0000
commit7d41380b9ea2fe4b60229cfdc408f982cc933c96 (patch)
tree0041076cbf0880387792d4f28ef4af0ace54686d /thumb.risu
parent30e50be0f7900af6ef78695f2fb8acf89cba05be (diff)
Add patterns for saturating 8 and 16 bit add/sub
Diffstat (limited to 'thumb.risu')
-rw-r--r--thumb.risu12
1 files changed, 12 insertions, 0 deletions
diff --git a/thumb.risu b/thumb.risu
index fffd0c2..85772bf 100644
--- a/thumb.risu
+++ b/thumb.risu
@@ -48,6 +48,18 @@ VQDMULL T1 1110 1111 1 d sz:2 vn:4 vd:3 0 1101 n 0 m 0 vm:4 { ($sz != 3) && ($sz
MOVS T2 000 00 00000 rm:3 rd:3
+# saturating add/sub
+UQADD16 T1 11111 010 1001 rn:4 1111 rd:4 0101 rm:4
+UQADD8 T1 11111 010 1000 rn:4 1111 rd:4 0101 rm:4
+UQSUB16 T1 11111 010 1101 rn:4 1111 rd:4 0101 rm:4
+UQSUB8 T1 11111 010 1100 rn:4 1111 rd:4 0101 rm:4
+# ditto, signed
+QADD16 T1 11111 010 1001 rn:4 1111 rd:4 0001 rm:4
+QADD8 T1 11111 010 1000 rn:4 1111 rd:4 0001 rm:4
+QSUB16 T1 11111 010 1101 rn:4 1111 rd:4 0001 rm:4
+QSUB8 T1 11111 010 1100 rn:4 1111 rd:4 0001 rm:4
+
+
##############################################################################
# Loads and stores