GNU bug report logs - #25912
2.1.7 segfaults on cygwin

Previous Next

Package: guile;

Reported by: szgyg <szgyg <at> ludens.elte.hu>

Date: Wed, 1 Mar 2017 11:05:02 UTC

Severity: normal

Found in version 2.1.7

Done: Andy Wingo <wingo <at> pobox.com>

Bug is archived. No further changes may be made.

Full log


Message #20 received at 25912 <at> debbugs.gnu.org (full text, mbox):

From: szgyg <szgyg <at> ludens.elte.hu>
To: Andy Wingo <wingo <at> pobox.com>
Cc: 25912 <at> debbugs.gnu.org
Subject: Re: bug#25912: 2.1.7 segfaults on cygwin
Date: Wed, 8 Mar 2017 17:50:16 +0100
On Mon, Mar 06, 2017 at 08:41:56PM +0100, Andy Wingo wrote:
> On Thu 02 Mar 2017 10:13, szgyg <szgyg <at> ludens.elte.hu> writes:
> 
> > load_thunk_from_memory doesn't call mprotect because in loader.c
> > line 436 the ELF segment is aligned to 4k while page size is 64k.
> 
> Ah, thank you for tracking this down.  I think we were going to just
> change the page size to 64K for .go files but I can't remember.  I think
> libc's loader doesn't actually align the pages on disk but projects
> segments of the file onto the memory image.

Changing *page-size* to 64k in linker.scm solves the problem. Size of
bootstrap/ goes from 17MB to 20MB.


> What platform is this that has 64K pages?  IIUC cygwin's usual size is
> 4096 bytes.

Pagesize is 4k on windows, but we can't allocate a single page, only
batches of 16 pages. Cygwin is hiding this abomination by using 64k
as pagesize.




This bug report was last modified 8 years and 69 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.