diff options
Diffstat (limited to 'gdb/arch/arm.h')
| -rw-r--r-- | gdb/arch/arm.h | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/gdb/arch/arm.h b/gdb/arch/arm.h index 5f7aa85..3e99e1b 100644 --- a/gdb/arch/arm.h +++ b/gdb/arch/arm.h @@ -194,6 +194,23 @@ struct reg_buffer_common; first halfword is INST1. */ int thumb_insn_size (unsigned short inst1); +/* Returns true if COND always evaluates to true. */ + +static inline bool +condition_always_true (unsigned long cond) +{ + return cond == INST_AL || cond == INST_NV; +} + +/* Returns true if cond of INSN always evaluates to true. */ + +static inline bool +insn_condition_always_true (uint32_t insn) +{ + unsigned long cond = bits (insn, 28, 31); + return condition_always_true (cond); +} + /* Returns true if the condition evaluates to true. */ int condition_true (unsigned long cond, unsigned long status_reg); @@ -221,10 +238,11 @@ unsigned long shifted_reg_val (reg_buffer_common *regcache, /* Create an Arm target description with the given FP hardware type. */ -target_desc *arm_create_target_description (arm_fp_type fp_type, bool tls); +target_desc_up arm_create_target_description (arm_fp_type fp_type, bool tls); /* Create an Arm M-profile target description with the given hardware type. */ -target_desc *arm_create_mprofile_target_description (arm_m_profile_type m_type); +target_desc_up arm_create_mprofile_target_description + (arm_m_profile_type m_type); #endif /* GDB_ARCH_ARM_H */ |
