This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: other/9830: [pch] not working on Solaris 9
- From: "Michael Teske" <mteske at csksoftware dot com>
- To: Geoff Keating <geoffk at geoffk dot org>
- Cc: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 25 Feb 2003 10:41:07 +0100
- Subject: Re: other/9830: [pch] not working on Solaris 9
- Organization: CSK Software AG
- References: <20030224132612.26862.qmail__21143.0731149905$1046093758@sources.redhat.com> <jmznolwi89.fsf@desire.geoffk.org>
On Monday 24 February 2003 21:12, Geoff Keating wrote:
[Patch snipped]
> > addr = mmap (mmi.preferred_base, mmi.size,
> > PROT_READ | PROT_WRITE, MAP_PRIVATE,
> > fileno (f), mmi.offset);
>
> This patch is unsafe in general, because it might map the PCH file
> over some other memory that's in use (like a shared object).
oops, yes. That might explain why I get an ICE whan trying to use a
complicated pch file...
> Can you work out why Solaris isn't mapping the PCH at the requested
> address?
As I saw it in gdb, Solaris seems to always return
(mmi.preferred_base + mmi.offset) as addr. I'll try what happens if I pass
mmi.preferred_base-mmi.offset as the first parameter (if MAP_FIXED is not
given).
BTW, as I did not mess around editing gcc's source before: Is it ok to do just
a "make quickstrap", ignore the complains of a difference between stage2 and
3 and use this compiler? Or did I miss some developer make targets?
Greetings,
--
Michael Teske
<This space is left blank intentionally>