public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug d/94609] FAIL: gdc.dg/runnable.d
Date: Wed, 15 Apr 2020 20:25:03 +0000	[thread overview]
Message-ID: <bug-94609-4-s8f33jMjGx@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-94609-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94609

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
LP64 has:

(gdb) disass _D8runnable6test52FZv
Dump of assembler code for function _D8runnable6test52FZv:
   0x000000000040943a <+0>:     push   %rbp
   0x000000000040943b <+1>:     mov    %rsp,%rbp
   0x000000000040943e <+4>:     push   %r13
   0x0000000000409440 <+6>:     push   %r12
   0x0000000000409442 <+8>:     push   %rbx
   0x0000000000409443 <+9>:     sub    $0x28,%rsp
   0x0000000000409447 <+13>:    lea    -0x40(%rbp),%rax
   0x000000000040944b <+17>:    mov    %rax,%rdi
   0x000000000040944e <+20>:    callq  0x409326
<_D8runnable7test52aFZS8runnable7test52aFZ6Scoped>

The argument is passed in RDI.  But x32 has

Dump of assembler code for function _D8runnable6test52FZv:
   0x00407a33 <+0>:     push   %rbp
   0x00407a34 <+1>:     mov    %esp,%ebp
   0x00407a36 <+3>:     push   %rbx
   0x00407a37 <+4>:     sub    $0x18,%esp
   0x00407a3a <+7>:     callq  0x4078f0
<_D8runnable7test52aFZS8runnable7test52aFZ6Scoped>

RDI/EDI isn't used to pass argument.  Is this done on purpose?  Where does
D frontend decide how to pass argument?

  parent reply	other threads:[~2020-04-15 20:25 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-15 18:38 [Bug d/94609] New: " hjl.tools at gmail dot com
2020-04-15 20:24 ` [Bug d/94609] " ibuclaw at gdcproject dot org
2020-04-15 20:25 ` hjl.tools at gmail dot com [this message]
2020-04-15 20:32 ` ibuclaw at gdcproject dot org
2020-04-15 20:42 ` ibuclaw at gdcproject dot org
2020-04-15 20:57 ` ibuclaw at gdcproject dot org
2020-04-15 21:03 ` hjl.tools at gmail dot com
2020-04-15 21:07 ` ibuclaw at gdcproject dot org
2020-04-15 21:09 ` ibuclaw at gdcproject dot org
2020-04-15 23:47 ` hjl.tools at gmail dot com
2020-04-15 23:54 ` hjl.tools at gmail dot com
2020-04-16  0:26 ` ibuclaw at gdcproject dot org
2020-04-16  7:41 ` ibuclaw at gdcproject dot org
2020-04-19  8:08 ` cvs-commit at gcc dot gnu.org
2020-04-19  8:11 ` ibuclaw at gdcproject dot org
2020-04-19 14:24 ` cvs-commit at gcc dot gnu.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=bug-94609-4-s8f33jMjGx@http.gcc.gnu.org/bugzilla/ \
    --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).