public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "iains at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/35491] wrong ABI for some struct passing with vector code
Date: Mon, 14 Feb 2011 15:50:00 -0000	[thread overview]
Message-ID: <bug-35491-4-guUdZl4sf3@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-35491-4@http.gcc.gnu.org/bugzilla/>

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

Iain Sandoe <iains at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED
      Known to fail|                            |

--- Comment #5 from Iain Sandoe <iains at gcc dot gnu.org> 2011-02-14 15:45:05 UTC ---
$ cat ../test-ppc/apinski-ppc-vect-abi.c 
#define vector __vector
struct data {
     float f;  //0 - 3
     int i;    // 4 - 7
     double d; // 8 - 15
     vector float v;  // 16 - 31
}; // __attribute__ ((d64_abi));  //size is 32

extern int bar (int a, struct data b, void *c);

int foo (struct data *inp_r3, void *inp_r4)
{
  return bar(10, *inp_r3, ((void *) inp_r4));
}

$ ./gcc/xgcc -Bgcc ../test-ppc/apinski-ppc-vect-abi.c -m64 -S -O2
$ more apinski-ppc-vect-abi.s 

        .machine ppc64
        .text
        .align  2
        .globl _foo
_foo:
        mfspr r0,256
        stw r0,-4(r1)
        oris r0,r0,0x2000
        mtspr 256,r0
        lfs f1,0(r3)
        mr r9,r4
        lfd f2,8(r3)
        lwz r5,4(r3)
        li r3,10
        lwz r12,-4(r1)
        mtspr 256,r12
        b _bar
        .subsections_via_symbols

thus fixed in trunk.


       reply	other threads:[~2011-02-14 15:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-35491-4@http.gcc.gnu.org/bugzilla/>
2011-02-14 15:50 ` iains at gcc dot gnu.org [this message]
2008-03-07  1:19 [Bug target/35491] New: " pinskia at gcc dot gnu dot org
2008-03-11  0:57 ` [Bug target/35491] " pinskia at gcc dot gnu dot org
2008-03-11  0:57 ` pinskia at gcc dot gnu dot org
2010-07-24  8:41 ` iains at gcc dot gnu dot org
2010-07-27 13:24 ` iains 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=bug-35491-4-guUdZl4sf3@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).