delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
DomainKey-Signature: | a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:from:to:subject:message-id:reply-to | |
:references:mime-version:content-type:in-reply-to; q=dns; s= | |
default; b=Z9on32Fnqu/j4VZVPO7mIB22oWgYdLrUqOflOugNr49HS+jIubTuQ | |
NRSzQhBphTJtin/HVj3Aoec3UiFbWfuDSfqF8u69Rn6IyLdxgfEKaxrJDVHtkjuh | |
jl8C7g5ycMzK6YqfNdUvkvub0nVUb4loSF/yPymuQ2UaqHCxvO5g+g= | |
DKIM-Signature: | v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:from:to:subject:message-id:reply-to | |
:references:mime-version:content-type:in-reply-to; s=default; | |
bh=I2nGM9E2CpEzY5wrNfxqPUTM+fE=; b=VCmEV9QykdjE6P+4TDwkg+pcUCyh | |
yh7Wk0YSkoaUx6/MRIKuh4Ik0rHwJ3QD+h/pPJR5gtcQOfZjbfm7HCIi3dye2tHS | |
k5k6vuLF+WMYuxAVMSwOvuJAOKG8XCrkDzAioxSHpdduLiHSN7TEWr7I0SGL0mH9 | |
jnTS0wgTP1sDUow= | |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
Authentication-Results: | sourceware.org; auth=none |
X-Virus-Found: | No |
X-Spam-SWARE-Status: | No, score=-100.3 required=5.0 tests=AWL,BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_BRBL_LASTEXT,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=6g256k, 6G256K, directions, 80000000 |
X-HELO: | drew.franken.de |
Date: | Sun, 10 Dec 2017 14:30:25 +0100 |
From: | Corinna Vinschen <corinna-cygwin AT cygwin DOT com> |
To: | cygwin AT cygwin DOT com |
Subject: | Re: fork fails after nmap with hint address in an unmapped memory region |
Message-ID: | <20171210133025.GJ18791@calimero.vinschen.de> |
Reply-To: | cygwin AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
References: | <b431898c-30f5-2847-c922-0f25a525ef76 AT yahoo DOT fr> <15510444518 DOT 20171209184819 AT yandex DOT ru> <42c71a45-e61b-6917-b634-e912fb51d2d5 AT yahoo DOT fr> <56047a39-4e1e-fa50-0e8b-c123c5b5ed3c AT SystematicSw DOT ab DOT ca> <cd9b5838-2545-362e-6e02-a46749791d6f AT dronecode DOT org DOT uk> <715b8bf4-ab6e-3c37-9ad2-f7c6bc3119d1 AT SystematicSw DOT ab DOT ca> |
MIME-Version: | 1.0 |
In-Reply-To: | <715b8bf4-ab6e-3c37-9ad2-f7c6bc3119d1@SystematicSw.ab.ca> |
User-Agent: | Mutt/1.9.1 (2017-09-22) |
--fdj2RfSjLxBAspz7 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Dec 9 23:40, Brian Inglis wrote: > On 2017-12-09 15:51, Jon Turney wrote: > > On 09/12/2017 18:29, Brian Inglis wrote: > >> On 2017-12-09 08:53, St=C3=A9phane Mbape via cygwin wrote: > >>> Le 09/12/2017 =C3=A0 16:48, Andrey Repin a =C3=A9crit : > >>>>> While embeding luajit in a c=C2=A0 program, I found myself unable t= o fork > >>>>> processes. > >>>>> Investigations prove that it was related to nmap. > >>>>> To be accurate, calling nmap with hint address in a unmapped memory > >>>>> region will cause all forks to fail with > >>>>> "fixup_mmaps_after_fork: ReadProcessMemory failed for MAP_PRIVATE > >>>>> address 0x6FFFFFE0000, Win32 error 299" > >>>>> There is a sample code below. > >>>> You forgot to mention Cygwin version you're using, and please provid= e the > >>>> sample as an attach to save people the copy-pasting issues. > >>> Cygwin version: 2.9.0 > >>> OS: Windows 10 > >>> Arch: 64bit > >>> The sample was also attached. > >> > >> Confirmed reproducible; addr2line does not give anything useful from t= he > >> stackdump, but included raw stackdump below, in case it gives hints. > >=20 > > If you're going to use addr2line to interpret a .stackdump file, I'm af= raid > > you're just supposed to know that the cygwin1.dll has an ImageBase of > > 0x0000000180040000 on x86_64 >=20 > Who came up with that magic number 6G256K and why - would a round 7/8G no= t do? Long discussion on cygwin-developers way back when we developed the 64 bit version. Basically: * Leave lower 32 bit area of 44 bit address space free for Windows * Leave upper 32 bit area of 44 bit address space free for Windows The rest just came about: 0x1:00000000 - 0x1:80000000 Stacks 0x1:80000000 - 0x2:00000000 Cygwin DLL plus helper space 0x2:00000000 - 0x4:00000000 Rebased DLLs 0x4:00000000 - 0x6:00000000 Non-rebased DLLs 0x6:00000000 Start address heap ... 0x700:00000000 Start address of mmap top down allocations So heap and mmap are growing from different directions. Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --fdj2RfSjLxBAspz7 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJaLTbxAAoJEPU2Bp2uRE+gemgP+gILprI2ShcVHPArAPC0l93c R2P1UR9FFyU+ley93rcjD0tbIWf4HCvEGqFvtj3KAejMcz+30OXJCv0zVgLY1GOh 4FIjgeHHHOMf+Heb84gAM5RRlaHhEebhT6DV74cwIkZu/+vNmjt8VKa1cR5j1Lfd 9MnBfvPjML0A/srbOtITC6m+REXAgjSjoQmMyNbY5fUGEQfYo/3kwLzTtm2wJpZX TB0OoqvM6n3o9SM//GXZYFUj2vAVdLLZ0qx6yVy4cgFlKmI/RJdpo9SjNRRcCCnZ lsDZ+GJWDBLbAvO+cC+WQS4lUReI7Wr2Xtd1yeMO+4OuE+zi2i0je4qe8S+mVPTe cqt1QmMLdkzs6oElJt9/4mwt3yqJ0recJlTWdVZdwLgqIltRiygaVUKnpweix4dK JM0sfhM8RkLH6ufE9U5a9tmVrVi0SKv9EvY0NpXdiXNueefp2B7a3cfvu2r8TQYC Q82zUkowaOeXfab4VhjrJ7wiRY0hqiyZgtDDzHCE+sb0jQVNP+85I0qWN0ingYff FKYMMwUiZjuyaEzKbwag8/bL2sXWgU4byXXViO5Ek3DVQfc8BWsgtNMLD1ojbT0+ p6D5rxIgmshSwMZ6JeySX9QdtXUzPx9/SNhQTR+aZqaafUXoia2GMN5d/QTNhnZN iLBVMUkGYUf3yn2ECm1+ =cGc4 -----END PGP SIGNATURE----- --fdj2RfSjLxBAspz7--
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |