This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 003/236] config/mn10300: Fix missing PATTERN in PARALLEL handling


On 08/06/2014 10:19 AM, David Malcolm wrote:
> @@ -2772,11 +2772,11 @@ mn10300_adjust_sched_cost (rtx insn, rtx link, rtx dep, int cost)
>    if (!TARGET_AM33)
>      return 1;
>  
> -  if (GET_CODE (insn) == PARALLEL)
> -    insn = XVECEXP (insn, 0, 0);
> +  if (GET_CODE (PATTERN (insn)) == PARALLEL)
> +    insn = XVECEXP (PATTERN (insn), 0, 0);
>  
> -  if (GET_CODE (dep) == PARALLEL)
> -    dep = XVECEXP (dep, 0, 0);
> +  if (GET_CODE (PATTERN (dep)) == PARALLEL)
> +    dep = XVECEXP (PATTERN (dep), 0, 0);

I think these tests are simply wrong and should be removed.

Certainly one can't expect to extract the first element of an insn's pattern
and then a few lines later test the pattern vs JUMP_P.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]