From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8764 invoked by alias); 10 Feb 2009 15:35:58 -0000 Received: (qmail 8700 invoked by uid 48); 10 Feb 2009 15:35:46 -0000 Date: Tue, 10 Feb 2009 15:35:00 -0000 Message-ID: <20090210153546.8699.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug target/16331] x86-64 inline asm register constraints insufficient WRT ABI In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "thutt at vmware dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2009-02/txt/msg00886.txt.bz2 ------- Comment #15 from thutt at vmware dot com 2009-02-10 15:35 ------- (In reply to comment #14) > > > OTOH, constraints should be used to support correct register > > > allocation for machine instructions, not to emulate ABI in order to > > > support calls from inside asm statements. > > > > Please indulge me for a moment. > > > > What exactly is a call? > > > > Are you considering the only method of transferring control to be the > > standard 'near call' & 'near ret' instructions on the x86? > > I was referring at the procedure call, where you need to setup outgoing > arguments on the calling point and setup incoming arguments on caller point. > gcc will magically match these two no matter what ABI-changing compile flag > (i.e. -mregparm) you use. When you call procedure from inside asm, gcc does not > know about that, and there is no way that gcc will know where arguments are to > be found. I understand. I'm not expecting gcc to handle those aspects of the inline assembly. My request is just to be able to specify any GP hardware register in a constraint. Both input & output. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16331