summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/ARM/ARMBaseInfo.h
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Target/ARM/ARMBaseInfo.h')
-rw-r--r--llvm/lib/Target/ARM/ARMBaseInfo.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/llvm/lib/Target/ARM/ARMBaseInfo.h b/llvm/lib/Target/ARM/ARMBaseInfo.h
index 6054bb773e7..a56cc1a9f24 100644
--- a/llvm/lib/Target/ARM/ARMBaseInfo.h
+++ b/llvm/lib/Target/ARM/ARMBaseInfo.h
@@ -97,6 +97,36 @@ inline static const char *ARMCondCodeToString(ARMCC::CondCodes CC) {
}
}
+namespace ARM_PROC {
+ enum IMod {
+ IE = 2,
+ ID = 3
+ };
+
+ enum IFlags {
+ F = 1,
+ I = 2,
+ A = 4
+ };
+
+ inline static const char *IFlagsToString(unsigned val) {
+ switch (val) {
+ default: llvm_unreachable("Unknown iflags operand");
+ case F: return "f";
+ case I: return "i";
+ case A: return "a";
+ }
+ }
+
+ inline static const char *IModToString(unsigned val) {
+ switch (val) {
+ default: llvm_unreachable("Unknown imod operand");
+ case IE: return "ie";
+ case ID: return "id";
+ }
+ }
+}
+
namespace ARM_MB {
// The Memory Barrier Option constants map directly to the 4-bit encoding of
// the option field for memory barrier operations.
OpenPOWER on IntegriCloud