From 2e94c12d07637be82bccf407a306fac33902c59c Mon Sep 17 00:00:00 2001 From: Julian Brown Date: Wed, 3 Jun 2009 16:01:38 +0000 Subject: [PATCH] arm.c (arm_hard_regno_mode_ok): Permit values of four words or less (including TImode) in core registers. * config/arm/arm.c (arm_hard_regno_mode_ok): Permit values of four words or less (including TImode) in core registers. From-SVN: r148135 --- gcc/ChangeLog | 5 +++++ gcc/config/arm/arm.c | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d4261298f7f4..c1e05ca606cd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2009-06-03 Julian Brown + + * config/arm/arm.c (arm_hard_regno_mode_ok): Permit values of four + words or less (including TImode) in core registers. + 2009-06-03 Richard Guenther PR middle-end/40328 diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 24a94a6ebfbd..cf3ef2323c0f 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -14741,13 +14741,13 @@ arm_hard_regno_mode_ok (unsigned int regno, enum machine_mode mode) return VALID_IWMMXT_REG_MODE (mode); } - /* We allow any value to be stored in the general registers. + /* We allow almost any value to be stored in the general registers. Restrict doubleword quantities to even register pairs so that we can - use ldrd. Do not allow Neon structure opaque modes in general registers; - they would use too many. */ + use ldrd. Do not allow very large Neon structure opaque modes in + general registers; they would use too many. */ if (regno <= LAST_ARM_REGNUM) return !(TARGET_LDRD && GET_MODE_SIZE (mode) > 4 && (regno & 1) != 0) - && !VALID_NEON_STRUCT_MODE (mode); + && ARM_NUM_REGS (mode) <= 4; if (regno == FRAME_POINTER_REGNUM || regno == ARG_POINTER_REGNUM) -- 2.47.2