+2016-05-31 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ * config/arm/arm-protos.h (arm_arch_thumb1): Declare.
+ * config/arm/arm.c (arm_arch_thumb1): Define.
+ (arm_option_override): Initialize arm_arch_thumb1.
+ * config/arm/arm.h (arm_arch_thumb1): Declare.
+ (TARGET_ARM_ARCH_ISA_THUMB): Use arm_arch_thumb to determine if target
+ support Thumb-1 ISA.
+
2016-05-31 Kirill Yukhin <kirill.yukhin@intel.com>
PR target/71346
interworking clean. */
extern int arm_cpp_interwork;
+/* Nonzero if chip supports Thumb 1. */
+extern int arm_arch_thumb1;
+
/* Nonzero if chip supports Thumb 2. */
extern int arm_arch_thumb2;
interworking clean. */
int arm_cpp_interwork = 0;
+/* Nonzero if chip supports Thumb 1. */
+int arm_arch_thumb1;
+
/* Nonzero if chip supports Thumb 2. */
int arm_arch_thumb2;
arm_arch7em = ARM_FSET_HAS_CPU1 (insn_flags, FL_ARCH7EM);
arm_arch8 = ARM_FSET_HAS_CPU1 (insn_flags, FL_ARCH8);
arm_arch8_1 = ARM_FSET_HAS_CPU2 (insn_flags, FL2_ARCH8_1);
+ arm_arch_thumb1 = ARM_FSET_HAS_CPU1 (insn_flags, FL_THUMB);
arm_arch_thumb2 = ARM_FSET_HAS_CPU1 (insn_flags, FL_THUMB2);
arm_arch_xscale = ARM_FSET_HAS_CPU1 (insn_flags, FL_XSCALE);
interworking clean. */
extern int arm_cpp_interwork;
+/* Nonzero if chip supports Thumb 1. */
+extern int arm_arch_thumb1;
+
/* Nonzero if chip supports Thumb 2. */
extern int arm_arch_thumb2;
(arm_base_arch) \
/* The highest Thumb instruction set version supported by the chip. */
-#define TARGET_ARM_ARCH_ISA_THUMB \
- (arm_arch_thumb2 ? 2 \
- : ((TARGET_ARM_ARCH >= 5 || arm_arch4t) ? 1 : 0))
+#define TARGET_ARM_ARCH_ISA_THUMB \
+ (arm_arch_thumb2 ? 2 : (arm_arch_thumb1 ? 1 : 0))
/* Expands to an upper-case char of the target's architectural
profile. */
+2016-05-31 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ * gcc.target/arm/armv5_thumb_isa.c: New test.
+
2016-05-31 Kirill Yukhin <kirill.yukhin@intel.com>
PR target/71346
--- /dev/null
+/* { dg-require-effective-target arm_arch_v5_ok } */
+/* { dg-add-options arm_arch_v5 } */
+
+#if __ARM_ARCH_ISA_THUMB
+#error "__ARM_ARCH_ISA_THUMB defined for ARMv5"
+#endif
+
+int foo;