Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-10 Thread Segher Boessenkool
Hi Alexandre, On Thu, Aug 09, 2018 at 03:23:12AM -0300, Alexandre Oliva wrote: > On Aug 8, 2018, Segher Boessenkool wrote: > > > Then you get sdata2 used (via srodata in generic code), and it is accessed > > via GPR2 (via the sda21 reloc and linker magic). It is hard to trace down > > :-) >

Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-08 Thread Alexandre Oliva
On Aug 8, 2018, Segher Boessenkool wrote: > Then you get sdata2 used (via srodata in generic code), and it is accessed > via GPR2 (via the sda21 reloc and linker magic). It is hard to trace down :-) Aah, it didn't occur to me that the r2 uses could be introduced by the linker. I was cutting c

Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-08 Thread Alexandre Oliva
On Aug 7, 2018, Segher Boessenkool wrote: > The approach looks like it should work, but it does not seem all that > convenient to me. And there's more, it's actually redundant. -msdata -G 0 is equivalent to the proposed -msdata=explicit. Patch withdrawn. Sorry about the noise. -- Alexandre O

Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-08 Thread Segher Boessenkool
On Wed, Aug 08, 2018 at 12:38:54AM -0300, Alexandre Oliva wrote: > On Aug 7, 2018, Segher Boessenkool wrote: > > On Tue, Aug 07, 2018 at 02:18:59AM -0300, Alexandre Oliva wrote: > > >> I saw comments, docs and init code that suggested the possibility of > >> using r2/.sdata2 for small data, but

Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-07 Thread Alexandre Oliva
On Aug 7, 2018, Segher Boessenkool wrote: > Hi! Hi! > On Tue, Aug 07, 2018 at 02:18:59AM -0300, Alexandre Oliva wrote: >> I saw comments, docs and init code that suggested the possibility of >> using r2/.sdata2 for small data, but I couldn't get code to be generated >> for such access, even w

Re: [RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-07 Thread Segher Boessenkool
Hi! On Tue, Aug 07, 2018 at 02:18:59AM -0300, Alexandre Oliva wrote: > This option allows users to manually select what goes in the limited > small data range, and still get smaller and faster small data access > sequences for the selected data. > We've considered adding a new attribute, say "sda

[RFC,PATCH] Introduce -msdata=explicit for powerpc

2018-08-06 Thread Alexandre Oliva
This option allows users to manually select what goes in the limited small data range, and still get smaller and faster small data access sequences for the selected data. We've considered adding a new attribute, say "sdata", to let the compiler pick the sdata/sbss section name itself, but that's