unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: szgyg <szgyg@ludens.elte.hu>
To: Andy Wingo <wingo@pobox.com>
Cc: 25912@debbugs.gnu.org
Subject: bug#25912: 2.1.7 segfaults on cygwin
Date: Wed, 8 Mar 2017 17:50:16 +0100	[thread overview]
Message-ID: <20170308165016.GD1836@debbie.mshome.net> (raw)
In-Reply-To: <878toib3az.fsf@pobox.com>

On Mon, Mar 06, 2017 at 08:41:56PM +0100, Andy Wingo wrote:
> On Thu 02 Mar 2017 10:13, szgyg <szgyg@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.





  reply	other threads:[~2017-03-08 16:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <78221352.340980.1488551525340.ref@mail.yahoo.com>
2017-03-01 10:27 ` bug#25912: 2.1.7 segfaults on cygwin szgyg
2017-03-01 16:47   ` Andy Wingo
2017-03-02  9:13     ` szgyg
2017-03-06 19:41       ` Andy Wingo
2017-03-08 16:50         ` szgyg [this message]
2017-03-03 14:32   ` Mike Gran
2017-03-14 11:35     ` Andy Wingo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170308165016.GD1836@debbie.mshome.net \
    --to=szgyg@ludens.elte.hu \
    --cc=25912@debbugs.gnu.org \
    --cc=wingo@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).