add condition page
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 28 Mar 2020 17:18:36 +0000 (17:18 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 28 Mar 2020 17:18:36 +0000 (17:18 +0000)
openpower/isa/condition.mdwn [new file with mode: 0644]

diff --git a/openpower/isa/condition.mdwn b/openpower/isa/condition.mdwn
new file mode 100644 (file)
index 0000000..4f181d0
--- /dev/null
@@ -0,0 +1,56 @@
+# Condition Register AND
+
+crand BT,BA,BB
+
+    CR[BT+32] <-  CR[BA+32] & CR[BB+32]
+
+# Condition Register NAND
+
+crnand BT,BA,BB
+
+    CR[BT+32] <- ¬(CR[BA+32] & CR[BB+32])
+
+# Condition Register OR
+
+cror BT,BA,BB
+
+    CR[BT+32] <-  CR[BA+32] | CR[BB+32]
+
+Condition Register XOR
+
+crxor     BT,BA,BB
+
+    CR[BT+32] <- CR[BA+32] ^ CR[BB+32]
+
+# Condition Register NOR
+
+crnor BT,BA,BB
+
+    CR[BT+32] <- ¬(CR[BA+32] | CR[BB+32])
+
+# Condition Register Equivalent
+
+creqv BT,BA,BB
+
+    CR[BT+32] <- CR[BA+32] => CR[BB+32]
+
+# Condition Register AND with Complement 
+
+crandc BT,BA,BB
+
+    CR[BT+32] <- CR[BA+32] &  ¬CR[BB+32]
+
+# Condition Register OR with Complement
+
+crorc BT,BA,BB
+
+    CR[BT+32] <- CR[BA+32] |  ¬CR[BB+32]
+
+
+# Move Condition Register Field
+
+mcrf BF,BFA
+
+    CR[4*BF+32:4*BF+35] <- CR[4*BFA+32:4*BFA+35]
+
+