Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2017-03-29 Thread Andreas Schwab
On Mär 29 2017, Eric Botcazou wrote: >> But I still see some ICEs while running the testsuite, >> which I haven't investigated yet. And the original comment before this >> hunk doesn't make sense at this point. > > The hunk in the 'else' arm of the big surrounding conditional? Yes. It talks ab

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2017-03-29 Thread Eric Botcazou
> Thanks, this gets me further, the ada library now compiles with > -mabi=ilp32. Great, I think that you can apply it as obvious then, it's code which is only exercised in Ada and on ILP32 64-bit platforms so the risk is very low... > But I still see some ICEs while running the testsuite, > whic

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2017-03-29 Thread Andreas Schwab
On Mär 28 2017, Eric Botcazou wrote: >> That needs to use ptr_mode, not Pmode. > > I don't think so, the whole computation is in Pmode. Could you try something > similar to what is done in the 'else' arm of the big surrounding conditional? Thanks, this gets me further, the ada library now comp

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2017-03-28 Thread Eric Botcazou
> That needs to use ptr_mode, not Pmode. I don't think so, the whole computation is in Pmode. Could you try something similar to what is done in the 'else' arm of the big surrounding conditional? -- Eric Botcazou

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2017-03-23 Thread Andreas Schwab
On Sep 04 2016, Eric Botcazou wrote: > Index: calls.c > === > --- calls.c (revision 239944) > +++ calls.c (working copy) > @@ -183,17 +183,76 @@ static void restore_fixed_argument_area (rtx, rtx, > > rtx > prepare_call_addres

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-07 Thread Eric Botcazou
> Yes I rebuilt everything and now it all looks good. The previously > failing testcases are now passing and no new regressions. I must have had > something set incorrectly in my environment on my first try. Thanks for confirming. -- Eric Botcazou

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-07 Thread Lynn A. Boger
Yes I rebuilt everything and now it all looks good. The previously failing testcases are now passing and no new regressions. I must have had something set incorrectly in my environment on my first try. Thanks! On 12/06/2016 04:26 PM, Eric Botcazou wrote: I tried this patch applied agains

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-06 Thread Eric Botcazou
> > Btw, Ian, if the heap trampoline support is no longer used by the Go > > compiler, you might want to remove it from the middle-end. > > Yes, I suppose so. The Go frontend hasn't used them for a while. Speaking of obsolete stuff, do you have any opinion on the below patch? https://gcc.gnu.o

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-06 Thread Eric Botcazou
> I tried this patch applied against latest and it fixed the testcases > that I had reported as failing, but the patch also causes > > libgo reflect testcase to fail. Still testing to verify and will report > the failure details. Please double check, as I can reproduce neither on PowerPC64 nor o

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-06 Thread Lynn A. Boger
I tried this patch applied against latest and it fixed the testcases that I had reported as failing, but the patch also causes libgo reflect testcase to fail. Still testing to verify and will report the failure details. On 12/06/2016 02:18 PM, Ian Lance Taylor wrote: On Tue, Dec 6, 2016 at

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-06 Thread Ian Lance Taylor
On Tue, Dec 6, 2016 at 9:52 AM, Eric Botcazou wrote: >> There are a couple of changes to the RTL expander for calls; they are >> supposed to be transparent but they might have tripped on a latent issue. > > Tentative fix attached, I need to test it extensively in Ada though. Thanks. Lynn, can yo

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-06 Thread Eric Botcazou
> There are a couple of changes to the RTL expander for calls; they are > supposed to be transparent but they might have tripped on a latent issue. Tentative fix attached, I need to test it extensively in Ada though. Btw, Ian, if the heap trampoline support is no longer used by the Go compiler,

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-05 Thread Ian Lance Taylor
On Mon, Dec 5, 2016 at 1:29 PM, Lynn A. Boger wrote: > I think you mean https://github.com/golang/go/issues/18200. Yes, thanks, I meant to write https://golang.org/issue/18200. Ian > On 12/05/2016 02:52 PM, Ian Lance Taylor wrote: >> >> On Sun, Sep 4, 2016 at 1:10 PM, Eric Botcazou >> wrote: >

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-05 Thread Eric Botcazou
> According to https://golang.org/cl/18200, this change broke Go on PPC64le. Any other platform where this also happened? > I haven't investigated myself and I don't know why. Go does not use > stack trampolines for function closures. It does use function > closures, but they are built on the h

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-05 Thread Lynn A. Boger
I think you mean https://github.com/golang/go/issues/18200. - Lynn On 12/05/2016 02:52 PM, Ian Lance Taylor wrote: On Sun, Sep 4, 2016 at 1:10 PM, Eric Botcazou wrote: 2016-07-04 Eric Botcazou PR ada/37139 PR ada/67205 * common.opt (-ftrampolines): New option.

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-12-05 Thread Ian Lance Taylor
On Sun, Sep 4, 2016 at 1:10 PM, Eric Botcazou wrote: > > 2016-07-04 Eric Botcazou > > PR ada/37139 > PR ada/67205 > * common.opt (-ftrampolines): New option. > * doc/invoke.texi (Code Gen Options): Document it. > * doc/tm.texi.in (Trampolines): AddTARGET_

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-09-12 Thread Jeff Law
On 09/04/2016 02:10 PM, Eric Botcazou wrote: This is the common infrastructure part. As explained in the initial message, nothing is activated unless both the language and the target opt in. 2016-07-04 Eric Botcazou PR ada/37139 PR ada/67205 * common.opt (-ftrampoli

Re: [patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-09-12 Thread Jeff Law
On 09/04/2016 02:10 PM, Eric Botcazou wrote: This is the common infrastructure part. As explained in the initial message, nothing is activated unless both the language and the target opt in. 2016-07-04 Eric Botcazou PR ada/37139 PR ada/67205 * common.opt (-ftrampoli

[patch v2] Get rid of stack trampolines for nested functions (1/4)

2016-09-04 Thread Eric Botcazou
This is the common infrastructure part. As explained in the initial message, nothing is activated unless both the language and the target opt in. 2016-07-04 Eric Botcazou PR ada/37139 PR ada/67205 * common.opt (-ftrampolines): New option. * doc/invoke.texi (C