From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24144 invoked by alias); 3 Dec 2009 14:10:50 -0000 Received: (qmail 24130 invoked by uid 22791); 3 Dec 2009 14:10:46 -0000 X-SWARE-Spam-Status: No, hits=-1.6 required=5.0 tests=AWL,BAYES_20,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 03 Dec 2009 14:10:40 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id nB3EAaxx007727 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 3 Dec 2009 09:10:37 -0500 Received: from zebedee.pink (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id nB3EAZVD029758; Thu, 3 Dec 2009 09:10:35 -0500 Message-ID: <4B17C6DA.4090808@redhat.com> Date: Thu, 03 Dec 2009 14:10:00 -0000 From: Andrew Haley User-Agent: Thunderbird 2.0.0.23 (X11/20090825) MIME-Version: 1.0 To: Jack Howarth CC: borlum , java@gcc.gnu.org Subject: Re: [patch] Fix oddity in personality routine References: <20091130160125.GA25831@bromo.med.uc.edu> <4B13EDB1.9090102@redhat.com> <20091201050157.GA1933@bromo.med.uc.edu> <4B14E200.8030007@redhat.com> <20091201170403.GA8810@bromo.med.uc.edu> <4B15514D.2010708@redhat.com> <20091201232939.GA20242@bromo.med.uc.edu> <4B1634A9.3000106@redhat.com> <20091203010828.GA684@bromo.med.uc.edu> <4B17921A.8090403@redhat.com> <20091203140334.GA8556@bromo.med.uc.edu> In-Reply-To: <20091203140334.GA8556@bromo.med.uc.edu> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact java-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-owner@gcc.gnu.org X-SW-Source: 2009-12/txt/msg00014.txt.bz2 Jack Howarth wrote: > On Thu, Dec 03, 2009 at 10:25:30AM +0000, Andrew Haley wrote: >> Jack Howarth wrote: >>> On Wed, Dec 02, 2009 at 09:34:33AM +0000, Andrew Haley wrote: >>>> Jack Howarth wrote: >>>>> On Tue, Dec 01, 2009 at 05:24:29PM +0000, Andrew Haley wrote: >>>>>> Jack Howarth wrote: >>>>>>> On Tue, Dec 01, 2009 at 09:29:36AM +0000, Andrew Haley wrote: >>> >>> What do you make of the bad assembly at 0x103f05dd1? >> There is no bad assembly: there's a jump at 0x103f05dc5. >> >> I know what's going on. >> >> The OS forbids execution of memory in the heap. But, there is an extra >> flag, -Wl,-allow_stack_execute, that allows this permission. This is >> a misnamed flag, since we never execute code on the stack. I think it's >> really controlling heap execution, not stack execution. >> >> We need to pass this flag everywhere, whenever a program is compiled by >> gcj. >> >> Andrew. > > Andrew, > This sounds like the patch that Andreas proposed in... > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41991#c3 > > which didn't solve the problem on my MacPro or MacBook Pro > under darwin9 or darwin10. He also ran into the issue again > later... > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41991#c17 > > Do you think that -Wl,-allow_stack_execute needs to be passed > even more widely than on just ecjx_LDFLAGS? Any suggestions as > to where I should be passing it? Perhaps on something like > LIBJAVA_LDFLAGS_NOUNDEF at the toplevel of libjava? Or should > we even be building libffi and boehm-gc with that as well? I don't see =-Wl,-allow_stack_execute passed to anything except when linking gij. That's why IMO gij works but nothing else does. This needs to be everywhere, for all programs. I think SYSTEMSPEC would do it, or add a new linker configure variable. Andrew.