public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "ubizjak at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/16331] x86-64 inline asm register constraints insufficient WRT ABI
Date: Tue, 10 Feb 2009 15:20:00 -0000	[thread overview]
Message-ID: <20090210152040.22625.qmail@sourceware.org> (raw)
In-Reply-To: <bug-16331-1331@http.gcc.gnu.org/bugzilla/>



------- Comment #14 from ubizjak at gmail dot com  2009-02-10 15:20 -------

> > 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.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16331


  parent reply	other threads:[~2009-02-10 15:20 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-16331-1331@http.gcc.gnu.org/bugzilla/>
2009-02-09 20:46 ` hjl dot tools at gmail dot com
2009-02-09 20:47 ` hjl dot tools at gmail dot com
2009-02-09 20:47 ` hjl dot tools at gmail dot com
2009-02-09 20:50 ` hjl dot tools at gmail dot com
2009-02-09 22:43 ` ubizjak at gmail dot com
2009-02-10 14:35 ` thutt at vmware dot com
2009-02-10 15:20 ` ubizjak at gmail dot com [this message]
2009-02-10 15:35 ` thutt at vmware dot com
     [not found] <bug-16331-4@http.gcc.gnu.org/bugzilla/>
2012-06-21 17:11 ` gcc at kalvdans dot no-ip.org
2014-06-25 23:48 ` gerald at pfeifer dot com
2004-07-02 16:51 [Bug c/16331] New: " thutt at vmware dot com
2004-08-03  7:06 ` [Bug target/16331] " pinskia at gcc dot gnu dot org
2005-07-02  1:27 ` pinskia at gcc dot gnu dot org
2005-07-02 10:17 ` falk at debian dot org
2005-09-04 19:05 ` pinskia at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090210152040.22625.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).