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:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; q=dns; s=default; b=doke7Bg7wUqMZ4Vq 4L1T2s87MLm756JnxXARhbujwepAEGoSBZGnndzKJHT3SrwzaHcztcHnVotFP2A+ loHfW63bTD+sV4uQQJuVRE/ciBke1vJ6fRuvsmJ6HmiJ75QBV3Z4OTTkI8Hd9b5E vghy7ggrGbmC20FyRg5FONYXLrM= 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:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; s=default; bh=JLEdB4FOhFhibYJnrbD7IX +LTmw=; b=FZuTwvTriO0NilKANqKZ3vAU2Ce6GnaLIrPtwWwRrK8Lt6o/RIBP+Q BmPU+rhZaQP15+JecgqHss133lwrKqDcMDj4rO5am98OG8LqnG5SHoa3H/iKJ9YY RFdxZM85Gurbwk8xaGZod1isx603LFpFVraIzd458F4G080sMJ0V8= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , 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=1.2 required=5.0 tests=AWL,BAYES_50,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 spammy=H*r:Sun, DLL, cyggmp-10.dll, UD:cyggmp-10.dll X-HELO: m0.truegem.net Subject: Re: Failing 'make check' for non-Cygwin GMP-ECM package To: cygwin AT cygwin DOT com References: <87d1saqhlj DOT fsf AT Rainer DOT invalid> <56B7D8FA DOT 1040501 AT maxrnd DOT com> From: Mark Geisert Message-ID: <56B84AEC.4020405@maxrnd.com> Date: Sun, 7 Feb 2016 23:59:40 -0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:42.0) Gecko/20100101 Firefox/42.0 SeaMonkey/2.39 MIME-Version: 1.0 In-Reply-To: <56B7D8FA.1040501@maxrnd.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Mark Geisert wrote: > Achim Gratz wrote: >> Mark Geisert writes: >>> I'm seeing an odd issue after building the GMP-ECM 6.4.4 package from >>> Inria. I downloaded the .tar.gz file and unpacked, ran configure, >>> then make and 'make check'. I get a SIGSEGV from a test using ecm.exe >>> as part of 'make check'. >> >> It seems that this release is three years old. Did you try autoreconf >> or just configure? If the latter, it may simply not recognize the >> current Cygwin correctly in its configury. > > Thanks for the idea but trying it didn't change the symptoms. With more > debugging this seems to me like some kind of dynamic relocation issue so I'm > looking further in that direction within the Cygwin DLL. Replying to myself... Yes, there appear to be two separate bugs colluding to break things the way I'm seeing. First, the application's object file has R_X86_64_PC32 relocation markers for functions it wants to pull in from cyggmp-10.dll. These relocation entries apparently allow for only 4 bytes of address. Second, the relocation that actually needs doing in this testcase results in addresses above 4GB, so they need more than 4 bytes to be stored. There is code in Cygwin's pseudo-reloc.cc to check for this situation but it is being skipped because __OPTIMIZE__ has been #define'd somewhere by the procedure that builds Cygwin. Instead, the relocated address gets truncated before being written back to memory, rather than provoking the error report "Invalid relocation. [...] doesn't fit into 32 bits". I don't know if the first bug could be caused by improper compiler options or whatnot. Here's the gcc invocation for that one object file: /bin/sh ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I./x86_64 -pipe -g -O2 -march=haswell -MT libecm_la-mpmod.lo -MD -MP -MF deps/libecm_la-mpmod.Tpo -c -o libecm_la-mpmod.lo `test -f 'mpmod.c' || echo './'`mpmod.c libtool: compile: gcc -DHAVE_CONFIG_H -I. -I./x86_64 -pipe -g -O2 -march=haswell -MT libecm_la-mpmod.lo -MD -MP -MF .deps/libecm_la-mpmod.Tpo -c mpmod.c -o libecm_la-mpmod.o Configure does know it's building for x86_64. I am up to date on binutils and this is on Cygwin 2.4.1, Win7 64-bit. ..mark -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple