aboutsummaryrefslogtreecommitdiffstats
path: root/capstone/MCInstrDesc.c
diff options
context:
space:
mode:
Diffstat (limited to 'capstone/MCInstrDesc.c')
-rw-r--r--capstone/MCInstrDesc.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/capstone/MCInstrDesc.c b/capstone/MCInstrDesc.c
new file mode 100644
index 000000000..9bb264a43
--- /dev/null
+++ b/capstone/MCInstrDesc.c
@@ -0,0 +1,18 @@
+/* Capstone Disassembly Engine */
+/* By Nguyen Anh Quynh <aquynh@gmail.com>, 2013-2019 */
+
+#include "MCInstrDesc.h"
+
+/// isPredicate - Set if this is one of the operands that made up of
+/// the predicate operand that controls an isPredicable() instruction.
+bool MCOperandInfo_isPredicate(const MCOperandInfo *m)
+{
+ return m->Flags & (1 << MCOI_Predicate);
+}
+
+/// isOptionalDef - Set if this operand is a optional def.
+///
+bool MCOperandInfo_isOptionalDef(const MCOperandInfo *m)
+{
+ return m->Flags & (1 << MCOI_OptionalDef);
+}