Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Date: Tue, 21 Nov 2000 17:16:53 -0800 From: "Zack Weinberg" To: Kelley Cook , "GCC-Bugs AT gcc DOT gnu DOT org" , "GCC-patches AT gcc DOT gnu DOT org" , Cygwin mailing list Subject: Re: Reason for cygwin GCC 2.97 non-bootstrap found Message-ID: <20001121171653.I17712@wolery.stanford.edu> References: <200011211839 DOT eALIdOd15553 AT ahmlir2 DOT mail DOT eds DOT com> <20001121162522 DOT G17712 AT wolery DOT stanford DOT edu> <20001121195005 DOT A17637 AT disaster DOT jaj DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20001121195005.A17637@disaster.jaj.com>; from pedwards@disaster.jaj.com on Tue, Nov 21, 2000 at 07:50:05PM -0500 On Tue, Nov 21, 2000 at 07:50:05PM -0500, Phil Edwards wrote: > On Tue, Nov 21, 2000 at 04:25:22PM -0800, Zack Weinberg wrote: > > > > Could you [since Kelley is out of town till Sunday, this "you" is > > anyone with a convenient cygwin installation] please compile and run > > the appended test program under cygwin? It should either exit > > successfully, or crash; I need to know which. > > With a somewhat-outdated cygwin installation, it exits successfully. Uh oh, that means I don't understand what's going on. Can you try this augmented version of the test program, which probes things a bit more thoroughly? Now I want the output and the exit status. [If you know how, also try to turn on Cygwin's internal debug logging and tell me what that reports.] zw #include #include #include #include #include #include #include #define PAGEPROT PROT_READ|PROT_WRITE #define MAPFLAGS MAP_PRIVATE|MAP_ANONYMOUS void sigsegv(int unused) { _exit(0); } int main(void) { size_t pagesize = getpagesize(); char *base; errno = 0; base = mmap(0, 16*pagesize, PAGEPROT, MAPFLAGS, -1, 0); perror("mmap"); memset(base, 0xAB, 16*pagesize); errno = 0; munmap(base + 4*pagesize, pagesize); perror("munmap"); /* These should not fault. */ memset(base, 0xCD, 4*pagesize); memset(base + 5*pagesize, 0xCD, 10*pagesize); errno = 0; signal(SIGSEGV, sigsegv); perror("signal"); /* This one should fault. */ memset(base + 4*pagesize, 0xEF, pagesize); /* If we get here it didn't crash. */ return 1; } -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com