Message ID | CAEwic4Z-3AF+mmkC0MVMGRnQGYpATD=zLwHKO+i2GCo_u5umfA@mail.gmail.com |
---|---|
State | New |
Headers | show |
On 06/16/2013 11:55 PM, Kai Tietz wrote: > +static bool > +ix86_function_attribute_inlinable_p (const_tree fndecl ATTRIBUTE_UNUSED) > +{ > + return true; > +} This is hook_bool_const_tree_true. I have an idea that perhaps the default ought to be true, and that the few targets (like mep) that have an interrupt attribute, etc ought to be the ones to actually implement this hook. r~
2013/6/17 Richard Henderson <rth@redhat.com>: > On 06/16/2013 11:55 PM, Kai Tietz wrote: >> +static bool >> +ix86_function_attribute_inlinable_p (const_tree fndecl ATTRIBUTE_UNUSED) >> +{ >> + return true; >> +} > > This is hook_bool_const_tree_true. Right, we could define macro to this ... > I have an idea that perhaps the default ought to be true, and that the few > targets (like mep) that have an interrupt attribute, etc ought to be the ones > to actually implement this hook. Yes, that was actual the cause why I did a RFC on that patch. I was concerned to break some targets by changing the default. I admit that changing default would be the preferred solution for me, too. > > r~ Kai
Index: i386.c =================================================================== --- i386.c (Revision 200128) +++ i386.c (Arbeitskopie) @@ -38721,6 +38721,12 @@ static const struct attribute_spec ix86_attribute_ { NULL, 0, 0, false, false, false, NULL, false } }; +static bool +ix86_function_attribute_inlinable_p (const_tree fndecl ATTRIBUTE_UNUSED) +{ + return true; +} + /* Implement targetm.vectorize.builtin_vectorization_cost. */ static int ix86_builtin_vectorization_cost (enum vect_cost_for_stmt type_of_cost, @@ -42700,6 +42706,8 @@ ix86_memmodel_check (unsigned HOST_WIDE_INT val) #undef TARGET_ATTRIBUTE_TABLE #define TARGET_ATTRIBUTE_TABLE ix86_attribute_table +#undef TARGET_FUNCTION_ATTRIBUTE_INLINABLE_P +#define TARGET_FUNCTION_ATTRIBUTE_INLINABLE_P ix86_function_attribute_inlinable_p #if TARGET_DLLIMPORT_DECL_ATTRIBUTES # undef TARGET_MERGE_DECL_ATTRIBUTES