This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix for PCH on many Linux platforms


"David S. Miller" <davem@redhat.com> writes:

> On 13 Jun 2004 21:30:08 -0400
> Ian Lance Taylor <ian@wasabisystems.com> wrote:
> 
> > From looking at the 2.4.22 kernel code, I suspect that the same occurs
> > on Linux, although the documentation does not indicate it.
> 
> It does not, you only get it if the area is currently free.

I'm willing to believe you.

What I see is that in mm/mmap.c, get_unmapped_area returns immediately
when passed MAP_FIXED.  In do_mmap_pgoff, after that returns, I see a
loop calling do_munmap.  I don't see anything like the code in
arch_get_unmapped_area which looks for an area which is not currently
mapped--that code is not called if MAP_FIXED is set.  I'm looking at
the 2.4.22-1.2188.nptl sources of Fedora Core 1.  The 2.6.5 code
appears similar at first glance.

So, I'm willing to believe you, but it's not obvious how it works.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]