[patch i386 middle-end]]: Fix PR/38366

Ian Lance Taylor iant@google.com
Fri Dec 5 16:29:00 GMT 2008


Kai Tietz <Kai.Tietz@onevision.com> writes:

> 2008-12-02  Kai Tietz  <kai.tietz@onevision.com>
>
>         PR/38366
>         * function.c (aggregate_value_p): Get fntype from CALL_EXPR in any 
> case.
>         * calls.c (nitialize_argument_information): Add fntype argument 
> and use it
>         for calls.promote_function_args.
>         (expand_call): Pass fntype to aggregate_value_p if no fndecl 
> available and
>         pass additional fntype to initialize_argument_information.
>         * config/i386/i386.c (ix86_reg_parm_stack_space): Remove cfun part 
> to get
>         function abi type.
>         (init_cumulative_args): Use for abi kind detection fntype, when no 
> fndecl is
>         available.

The lines in the ChangeLog entry are too long.  In general they should
not be more than 74 characters.  Or just use emacs change-log-mode.


> -	fntype = fndecl ? TREE_TYPE (fndecl) : 0;
> +	fntype = fndecl ? TREE_TYPE (fndecl)
> +		        : TREE_TYPE (CALL_EXPR_FN (fntype));

When breaking lines, use parentheses, and indent as
  fntype = (fndecl
            ? TREE_TYPE (fndecl)
            : TREE_TYPE (CALL_EXPR_FN (fntype)));


> -      if (targetm.calls.promote_function_args (fndecl ? TREE_TYPE (fndecl) : 0))
> +      if (targetm.calls.promote_function_args (fndecl ? TREE_TYPE (fndecl) : fntype))

Line is more than 80 characters, format as

  if (targetm.calls.promote_function_args (fndecl
                                           ? TREE_TYPE (fndecl)
                                           : fntype))


This patch is OK with those changes.

Thanks.

Ian



More information about the Gcc-patches mailing list