From patchwork Tue Nov 16 15:48:33 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: hookize FUNCTION_ARG_BOUNDARY X-Patchwork-Submitter: Nathan Froyd X-Patchwork-Id: 71410 Message-Id: <20101116154833.GI24469@nightcrawler> To: Richard Henderson Cc: gcc-patches@gcc.gnu.org Date: Tue, 16 Nov 2010 10:48:33 -0500 From: Nathan Froyd List-Id: On Tue, Nov 16, 2010 at 07:43:01AM -0800, Richard Henderson wrote: > On 11/15/2010 07:42 PM, Nathan Froyd wrote: > > +/* If defined, a C expression that gives the alignment boundary, in bits, > > + of an argument with the specified mode and type. If it is not defined, > > + PARM_BOUNDARY is used for all arguments. */ > > +#define FUNCTION_ARG_BOUNDARY(MODE, TYPE) \ > > +/* Worker function for TARGET_FUNCTION_ARG_BOUNDARY. */ > > Paste-o with that #define, surely. > > > +static unsigned int > > +pa_function_arg_boundary (enum machine_mode mode, const_tree type) > > +{ > > + tree size = TYPE_SIZE (type); > > + bool singleword = (type > > + ? (integer_zerop (size) > > + || !TREE_CONSTANT (size) > > + || int_size_in_bytes (type) <= UNITS_PER_WORD) > > + : GET_MODE_SIZE (mode)); > > Missing a comparison vs U_P_W here. > > > - : GET_MODE_SIZE(MODE) <= UNITS_PER_WORD) \ > > ... from here. Doh, thank you for looking those over. Fixed like so, committed as obvious. -Nathan * config/arc/arc.c: Delete pasto. * config/pa/pa.c (pa_function_arg_boundary): Add missing comparison. Index: config/arc/arc.c =================================================================== --- config/arc/arc.c (revision 166803) +++ config/arc/arc.c (working copy) @@ -2426,10 +2426,6 @@ arc_function_arg_advance (CUMULATIVE_ARG + ROUND_ADVANCE_ARG (mode, type)); } -/* If defined, a C expression that gives the alignment boundary, in bits, - of an argument with the specified mode and type. If it is not defined, - PARM_BOUNDARY is used for all arguments. */ -#define FUNCTION_ARG_BOUNDARY(MODE, TYPE) \ /* Worker function for TARGET_FUNCTION_ARG_BOUNDARY. */ static unsigned int Index: config/pa/pa.c =================================================================== --- config/pa/pa.c (revision 166803) +++ config/pa/pa.c (working copy) @@ -9613,7 +9613,7 @@ pa_function_arg_boundary (enum machine_m ? (integer_zerop (size) || !TREE_CONSTANT (size) || int_size_in_bytes (type) <= UNITS_PER_WORD) - : GET_MODE_SIZE (mode)); + : GET_MODE_SIZE (mode) <= UNITS_PER_WORD); return singleword ? PARM_BOUNDARY : MAX_PARM_BOUNDARY; }