Re: [PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062, take 3)

2014-02-06 Thread Uros Bizjak
On Thu, Feb 6, 2014 at 10:45 AM, Richard Biener wrote: > On Thu, 6 Feb 2014, Jakub Jelinek wrote: > >> On Wed, Feb 05, 2014 at 08:42:27PM +0100, Jakub Jelinek wrote: >> > So, where do we want to do that instead? E.g. should it be e.g. in >> > tree_versionable_function_p directly and let the inlin

Re: [PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062, take 3)

2014-02-06 Thread Richard Biener
On Thu, 6 Feb 2014, Jakub Jelinek wrote: > On Wed, Feb 05, 2014 at 08:42:27PM +0100, Jakub Jelinek wrote: > > So, where do we want to do that instead? E.g. should it be e.g. in > > tree_versionable_function_p directly and let the inliner (if it doesn't do > > already) also treat optimize(0) funct

Re: [PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062, take 2)

2014-02-06 Thread Richard Biener
On Wed, 5 Feb 2014, Jakub Jelinek wrote: > On Wed, Feb 05, 2014 at 02:20:05PM +0100, Richard Biener wrote: > > > Using !!optimize to determine if we should switch local ABI to regparm > > > convention isn't compatible with optimize attribute, as !!optimize is > > > whether the current function is

[PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062, take 3)

2014-02-05 Thread Jakub Jelinek
On Wed, Feb 05, 2014 at 08:42:27PM +0100, Jakub Jelinek wrote: > So, where do we want to do that instead? E.g. should it be e.g. in > tree_versionable_function_p directly and let the inliner (if it doesn't do > already) also treat optimize(0) functions that aren't always_inline as > noinline? So,

[PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062, take 2)

2014-02-05 Thread Jakub Jelinek
On Wed, Feb 05, 2014 at 02:20:05PM +0100, Richard Biener wrote: > > Using !!optimize to determine if we should switch local ABI to regparm > > convention isn't compatible with optimize attribute, as !!optimize is > > whether the current function is being optimized, but for the ABI decisions > > we

Re: [PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062)

2014-02-05 Thread Jan Hubicka
> On Wed, 5 Feb 2014, Jakub Jelinek wrote: > > > Hi! > > > > Using !!optimize to determine if we should switch local ABI to regparm > > convention isn't compatible with optimize attribute, as !!optimize is > > whether the current function is being optimized, but for the ABI decisions > > we actua

Re: [PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062)

2014-02-05 Thread Richard Biener
On Wed, 5 Feb 2014, Jakub Jelinek wrote: > Hi! > > Using !!optimize to determine if we should switch local ABI to regparm > convention isn't compatible with optimize attribute, as !!optimize is > whether the current function is being optimized, but for the ABI decisions > we actually need the cal

[PATCH] Fix ix86_function_regparm with optimize attribute (PR target/60062)

2014-02-05 Thread Jakub Jelinek
Hi! Using !!optimize to determine if we should switch local ABI to regparm convention isn't compatible with optimize attribute, as !!optimize is whether the current function is being optimized, but for the ABI decisions we actually need the caller and callee to agree on the calling convention. Fi