From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20440 invoked by alias); 10 Sep 2013 10:19:23 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 20423 invoked by uid 48); 10 Sep 2013 10:19:20 -0000 From: "martin at netbsd dot org" To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/58379] New: default mmap based implementation (mmap_gt_pch_get_address/mmap_gt_pch_use_address) is useless Date: Tue, 10 Sep 2013 10:19:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: preprocessor X-Bugzilla-Version: 4.8.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: martin at netbsd dot org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-09/txt/msg00672.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58379 Bug ID: 58379 Summary: default mmap based implementation (mmap_gt_pch_get_address/mmap_gt_pch_use_address) is useless Product: gcc Version: 4.8.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: preprocessor Assignee: unassigned at gcc dot gnu.org Reporter: martin at netbsd dot org I may be misunderstanding the interface - but it looks to me like it lets the kernel chose an arbitrary mapping address for different compiler invocations but relies on the assumption that the returned address will be the same. If not, the compiler fails with a fatal_error when trying to read a precompiled header file ("had to relocate PCH"). I can not imagine a host system where this would work reliably (or even typically twice in a row). Please tell me I misunderstood, or consider disabling PCH support for host platforms without host_hooks overriding this function.