OpenBSD pch, take 2
Marc Espie
espie@nerim.net
Mon Jan 31 16:06:00 GMT 2005
On Mon, Jan 31, 2005 at 03:47:56PM +0100, Paolo Bonzini wrote:
> >The very nasty thing is that they will *appear* to work. Namely, loading
> >a pch file will work 95% of the time... and fail whenever the file cannot
> >be mmaped at the same address due to randomization issues.
> >So, mark them as completely unreliable.
>
> You may want to find the largest VMA and make the PCH reside in the 200
> MB in the middle of it, or allocate the topmost free 200 MB in the
> address space, etc.
>
> Linux has similar problems, see host-linux.c. If you bring the
> percentage up to 99% or so, it can be ok because PCH should only cause a
> compilation slowdown rather than incorrect results.
>
> Paolo
Nope.
It doesn't work. Specifying pch on the command line will fail if the pch
loading doesn't work, it won't revert gracefully to normal headers.
And it's not a question of finding an address that works, no address works.
And 99% is not acceptable. How would you feel if you had this nifty
compilation procedure that works only 99% of the time and fails the
remaining 1% ? This means that every automated build is doomed. Thus
pch are totally unfit for production on OpenBSD.
More information about the Gcc
mailing list