From fb39b3a2a58b6643c9be271bbf7b05bca48af43c Mon Sep 17 00:00:00 2001 From: jsm28 Date: Tue, 14 Nov 2006 20:36:28 +0000 Subject: [PATCH] * config/arm/arm.h (FUNCTION_ARG_ADVANCE): Only adjust iwmmxt_nregs if TARGET_IWMMXT_ABI. * config/arm/iwmmxt.md (movv8qi_internal, movv4hi_internal, movv2si_internal): Support moves between core registers. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@118825 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 7 +++++++ gcc/config/arm/arm.h | 5 +++-- gcc/config/arm/iwmmxt.md | 39 +++++++++++++++++++++------------------ 3 files changed, 31 insertions(+), 20 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1080e8cbebc..2458b0ecdf0 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2006-11-14 Joseph Myers + + * config/arm/arm.h (FUNCTION_ARG_ADVANCE): Only adjust + iwmmxt_nregs if TARGET_IWMMXT_ABI. + * config/arm/iwmmxt.md (movv8qi_internal, movv4hi_internal, + movv2si_internal): Support moves between core registers. + 2006-11-14 Eric Christopher * configure: Regenerate with autoconf 2.59. diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index beb222263ab..73d8333b080 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -1480,8 +1480,9 @@ typedef struct (TYPE is null for libcalls where that information may not be available.) */ #define FUNCTION_ARG_ADVANCE(CUM, MODE, TYPE, NAMED) \ (CUM).nargs += 1; \ - if (arm_vector_mode_supported_p (MODE) \ - && (CUM).named_count > (CUM).nargs) \ + if (arm_vector_mode_supported_p (MODE) \ + && (CUM).named_count > (CUM).nargs \ + && TARGET_IWMMXT_ABI) \ (CUM).iwmmxt_nregs += 1; \ else \ (CUM).nregs += ARM_NUM_REGS2 (MODE, TYPE) diff --git a/gcc/config/arm/iwmmxt.md b/gcc/config/arm/iwmmxt.md index 380d4b95455..9ae55a7b811 100644 --- a/gcc/config/arm/iwmmxt.md +++ b/gcc/config/arm/iwmmxt.md @@ -158,8 +158,8 @@ ) (define_insn "movv8qi_internal" - [(set (match_operand:V8QI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r") - (match_operand:V8QI 1 "general_operand" "y,y,mi,y,r,mi"))] + [(set (match_operand:V8QI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r,?r") + (match_operand:V8QI 1 "general_operand" "y,y,mi,y,r,r,mi"))] "TARGET_REALLY_IWMMXT" "* switch (which_alternative) @@ -169,17 +169,18 @@ case 2: return \"wldrd%?\\t%0, %1\"; case 3: return \"tmrrc%?\\t%Q0, %R0, %1\"; case 4: return \"tmcrr%?\\t%0, %Q1, %R1\"; + case 5: return \"#\"; default: return output_move_double (operands); }" [(set_attr "predicable" "yes") - (set_attr "length" "4, 4, 4,4,4, 8") - (set_attr "type" "*,store1,load1,*,*,load1") - (set_attr "pool_range" "*, *, 256,*,*, 256") - (set_attr "neg_pool_range" "*, *, 244,*,*, 244")]) + (set_attr "length" "4, 4, 4,4,4,8, 8") + (set_attr "type" "*,store1,load1,*,*,*,load1") + (set_attr "pool_range" "*, *, 256,*,*,*, 256") + (set_attr "neg_pool_range" "*, *, 244,*,*,*, 244")]) (define_insn "movv4hi_internal" - [(set (match_operand:V4HI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r") - (match_operand:V4HI 1 "general_operand" "y,y,mi,y,r,mi"))] + [(set (match_operand:V4HI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r,?r") + (match_operand:V4HI 1 "general_operand" "y,y,mi,y,r,r,mi"))] "TARGET_REALLY_IWMMXT" "* switch (which_alternative) @@ -189,17 +190,18 @@ case 2: return \"wldrd%?\\t%0, %1\"; case 3: return \"tmrrc%?\\t%Q0, %R0, %1\"; case 4: return \"tmcrr%?\\t%0, %Q1, %R1\"; + case 5: return \"#\"; default: return output_move_double (operands); }" [(set_attr "predicable" "yes") - (set_attr "length" "4, 4, 4,4,4, 8") - (set_attr "type" "*,store1,load1,*,*,load1") - (set_attr "pool_range" "*, *, 256,*,*, 256") - (set_attr "neg_pool_range" "*, *, 244,*,*, 244")]) + (set_attr "length" "4, 4, 4,4,4,8, 8") + (set_attr "type" "*,store1,load1,*,*,*,load1") + (set_attr "pool_range" "*, *, 256,*,*,*, 256") + (set_attr "neg_pool_range" "*, *, 244,*,*,*, 244")]) (define_insn "movv2si_internal" - [(set (match_operand:V2SI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r") - (match_operand:V2SI 1 "general_operand" "y,y,mi,y,r,mi"))] + [(set (match_operand:V2SI 0 "nonimmediate_operand" "=y,m,y,?r,?y,?r,?r") + (match_operand:V2SI 1 "general_operand" "y,y,mi,y,r,r,mi"))] "TARGET_REALLY_IWMMXT" "* switch (which_alternative) @@ -209,13 +211,14 @@ case 2: return \"wldrd%?\\t%0, %1\"; case 3: return \"tmrrc%?\\t%Q0, %R0, %1\"; case 4: return \"tmcrr%?\\t%0, %Q1, %R1\"; + case 5: return \"#\"; default: return output_move_double (operands); }" [(set_attr "predicable" "yes") - (set_attr "length" "4, 4, 4,4,4, 24") - (set_attr "type" "*,store1,load1,*,*,load1") - (set_attr "pool_range" "*, *, 256,*,*, 256") - (set_attr "neg_pool_range" "*, *, 244,*,*, 244")]) + (set_attr "length" "4, 4, 4,4,4,8, 24") + (set_attr "type" "*,store1,load1,*,*,*,load1") + (set_attr "pool_range" "*, *, 256,*,*,*, 256") + (set_attr "neg_pool_range" "*, *, 244,*,*,*, 244")]) ;; This pattern should not be needed. It is to match a ;; wierd case generated by GCC when no optimizations are -- 2.11.4.GIT