On Thu, Dec 08, 2011 at 08:55:17PM +0000, Iain Sandoe wrote:
>
> On 8 Dec 2011, at 20:15, Jack Howarth wrote:
>>>
>>> At present, you pass it when "no-pic, no-pie" etc. are - perhaps it
>>> should just be the default and *only* switched on for -pie something
>>> like....
>>>
>>> %{!fpie: %{!PIE: %:version-compare(>= 10.7 mmacosx-version-min= -
>>> no_pie) } }
>>>
>>> Otherwise, D11 is behaving differently from other targets for the  
>>> whole
>>> test-suite - not just boehm-gc.
>>
>> Iain,
>>   One could make the alternative argument that the testing on linux is
>> currently incomplete because it is not done on any of the hardened  
>> linux
>> distros which utilize PIE such as...
>>
>> http://www.gentoo.org/proj/en/hardened/
>>
>> I find it very stange that there seems to be so little communication  
>> between
>> such projects and FSF gcc.
>
>
> [well the best solution would be to solve whatever problem stops boehm- 
> gc working with PIE on/off-- but that's not a job for this week ;-) ]
>
> ===
>
> So to recap ---
> IMO it's better if we can do the same as the vendor's tools on the  
> target system, providing that's not provably buggy.
> (I think that's our general policy on Darwin, right?).
>
> So, yes, you are correct, I would prefer not to switch PIE off ...
>
> ... but then, I guess, the test-suite makes the "assumption" that PIE is 
> off by default ...

Iain,
    The same argument could be made for PIC itself regarding the testsuite. 
Aren't we still the only target that defaults to PIC objects? I would think that
the fact that we test against PIE on darwin11 and later would be a bonus for
FSF gcc since they don't seem to get much feedback directly from the hardened
linux projects. Better to just turn off PIE for the few problem test cases
and retain the wider testing against PIE in order to look for potential problems
(since one really doesn't want to test the compiler in mode completely alien
to how it will be used in practice... that is with PIE linkage).
                  Jack

>
> ... so, perhaps a solution is to run it  RUNTESTFLAGS=".... \-fno-PIE ... 
> " on Darwin11.
>
> -====-
>
> similarly,  the hardened linux guys could do  ... RUNTESTFLAGS="....\{- 
> fPIE... "  if they want to test coverage with PIE on.
>
> -====-
>
> ... of course, that breaks when there are specific tests that *are* PIE 
> aware ...
>
> ... so the 'easy way out' is to make D11 behave as per earlier versions 
> (i.e. default PIE off);
>
> ----
>
> for a small number of tests ..  { dg-additional-options ... } would be  
> more transparent than modifying
> lib/something.exp
>
> ... but, I'll bow out at this juncture -
> - we've established the underlying issue - which isn't likely to get  
> solved with specs or test-suite options.
>
> cheers
> Iain

Reply via email to