public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux
@ 2005-02-20  5:00 jsm28 at gcc dot gnu dot org
  2005-02-20  5:16 ` [Bug target/20094] " pinskia at gcc dot gnu dot org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2005-02-20  5:00 UTC (permalink / raw)
  To: gcc-bugs

The tests gcc.dg/transparent-union-1.c and gcc.dg/transparent-union-2.c
fail on ia64-hpux.  Problems start with:

/scratch/joseph/gcc-mainline/gcc/testsuite/gcc.dg/transparent-union-1.c:12:
warning: 'transparent_union' attribute ignored

The union has mode BLKmode while the fields have mode SImode.

Not a regression relative to 3.4.x.

-- 
           Summary: gcc.dg/transparent-union-* fail on ia64-hpux
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jsm28 at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: ia64-*-hpux11.*


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
@ 2005-02-20  5:16 ` pinskia at gcc dot gnu dot org
  2005-02-20 10:17 ` wilson at specifixinc dot com
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-02-20  5:16 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-02-19 21:24 -------
Hmm, Does anyone know how these union are supposed to be passed on ia64-*-hpux, if by referrence 
then the warning is correct and the testcase should not be tested on this target.  This is an ABI Issue.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ABI


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
  2005-02-20  5:16 ` [Bug target/20094] " pinskia at gcc dot gnu dot org
@ 2005-02-20 10:17 ` wilson at specifixinc dot com
  2005-02-20 18:33 ` giovannibajo at libero dot it
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: wilson at specifixinc dot com @ 2005-02-20 10:17 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From wilson at specifixinc dot com  2005-02-19 23:15 -------
Subject: Re:  gcc.dg/transparent-union-* fail on ia64-hpux

pinskia at gcc dot gnu dot org wrote:
> ------- Additional Comments From pinskia at gcc dot gnu dot org  2005-02-19 21:24 -------
> Hmm, Does anyone know how these union are supposed to be passed on ia64-*-hpux, if by referrence 
> then the warning is correct and the testcase should not be tested on this target.  This is an ABI Issue.

unions get passed right-aligned little-endian and left-aligned 
big-endian.  Since linux is little-endian, and HPUX is big-endian, only 
HPUX has a problem here.  HPUX defines MEMBER_TYPE_FORCES_BLK to make 
this work.  There are other ways to solve this problem used by other 
targets, for instance, defining BLOCK_REG_PADDING for HPUX.  Getting 
BLOCK_REG_PADDING to work can be tricky though.

It looks like the ia64/hpux.h is the only one that defines 
MEMBER_TYPE_FORCES_BLK that can trigger this problem, since the others 
don't trigger on pointer or integer types.

It appears that MEMBER_TYPE_FORCES_BLK should not be used for a 
transparent union, or should be used differently.  This check could 
perhaps be done unconditionally in stor-layout.c.  This might be a 
simple solution.

Or maybe we can pass the union/structure type to MEMBER_TYPE_FORCES_BLK 
and modify the ia64/hpux.h version of the macro to check for the 
transparent_union attribute.


-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
  2005-02-20  5:16 ` [Bug target/20094] " pinskia at gcc dot gnu dot org
  2005-02-20 10:17 ` wilson at specifixinc dot com
@ 2005-02-20 18:33 ` giovannibajo at libero dot it
  2005-02-22  3:26 ` wilson at specifixinc dot com
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: giovannibajo at libero dot it @ 2005-02-20 18:33 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From giovannibajo at libero dot it  2005-02-20 13:03 -------
Jim, these are transparent unions, I thought that they were passed using the 
convention of the first element in the union.

-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2005-02-20 18:33 ` giovannibajo at libero dot it
@ 2005-02-22  3:26 ` wilson at specifixinc dot com
  2005-02-22  4:56 ` wilson at specifixinc dot com
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: wilson at specifixinc dot com @ 2005-02-22  3:26 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From wilson at specifixinc dot com  2005-02-21 23:11 -------
Subject: Re:  gcc.dg/transparent-union-* fail on ia64-hpux

giovannibajo at libero dot it wrote:
> ------- Additional Comments From giovannibajo at libero dot it  2005-02-20 13:03 -------
> Jim, these are transparent unions, I thought that they were passed using the 
> convention of the first element in the union.

Yes, they are.  And yes, MEMBER_TYPE_FORCES_BLK is causing the problem. 
  Look at handle_transparent_union_attribute, and note the mode checks 
it is performing.


-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2005-02-22  3:26 ` wilson at specifixinc dot com
@ 2005-02-22  4:56 ` wilson at specifixinc dot com
  2005-05-22  5:49 ` pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: wilson at specifixinc dot com @ 2005-02-22  4:56 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From wilson at specifixinc dot com  2005-02-21 23:19 -------
Subject: Re:  gcc.dg/transparent-union-* fail on ia64-hpux

giovannibajo at libero dot it wrote:
> ------- Additional Comments From giovannibajo at libero dot it  2005-02-20 13:03 -------
> Jim, these are transparent unions, I thought that they were passed using the 
> convention of the first element in the union.

By the way, I probably wasn't clear about this, but I haven't made any 
attempt to debug or analyze the problem.  I'm just trying to point 
people at the cause of the first error, which was obvious to me just 
from reading the bug report.  And that is MEMBER_TYPE_FORCES_BLK.  There 
may also be other problems here.


-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2005-02-22  4:56 ` wilson at specifixinc dot com
@ 2005-05-22  5:49 ` pinskia at gcc dot gnu dot org
  2005-07-30 19:28 ` jsm28 at gcc dot gnu dot org
  2005-08-16 21:38 ` wilson at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-22  5:49 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-05-22 05:49 -------
Confirmed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2005-05-22 05:49:15
               date|                            |


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2005-05-22  5:49 ` pinskia at gcc dot gnu dot org
@ 2005-07-30 19:28 ` jsm28 at gcc dot gnu dot org
  2005-08-16 21:38 ` wilson at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2005-07-30 19:28 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From jsm28 at gcc dot gnu dot org  2005-07-30 19:19 -------
My newly added test transparent-union-4.c fails on ia64-hpux for the same reason.


-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug target/20094] gcc.dg/transparent-union-* fail on ia64-hpux
  2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
                   ` (6 preceding siblings ...)
  2005-07-30 19:28 ` jsm28 at gcc dot gnu dot org
@ 2005-08-16 21:38 ` wilson at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: wilson at gcc dot gnu dot org @ 2005-08-16 21:38 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From wilson at gcc dot gnu dot org  2005-08-16 21:32 -------
The MEMBER_TYPE_FORCES_BLK definition was changed Aug 3.
    http://gcc.gnu.org/ml/gcc-patches/2005-08/msg00166.html

The Aug 4 ia64-hp-hpux11 testsuite reports no longer show any transparent union
failures.
    http://gcc.gnu.org/ml/gcc-testresults/2005-08/msg00223.html

Since MEMBER_TYPE_FORCES_BLK is still defined for TFmode, one can still
reproduce this problem if you use a transparent union whose first member is a
long double.

It is believed that defining MEMBER_TYPE_FORCES_BLK is also not needed for
TFmode anymore, but someone needs to do rigorous testing to verify that this
change does not introduce any ABI changes.  Eric Botcazou didn't need this fixed
for Ada, so he didn't do this testing.

-- 


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


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2005-08-16 21:32 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-20  5:00 [Bug target/20094] New: gcc.dg/transparent-union-* fail on ia64-hpux jsm28 at gcc dot gnu dot org
2005-02-20  5:16 ` [Bug target/20094] " pinskia at gcc dot gnu dot org
2005-02-20 10:17 ` wilson at specifixinc dot com
2005-02-20 18:33 ` giovannibajo at libero dot it
2005-02-22  3:26 ` wilson at specifixinc dot com
2005-02-22  4:56 ` wilson at specifixinc dot com
2005-05-22  5:49 ` pinskia at gcc dot gnu dot org
2005-07-30 19:28 ` jsm28 at gcc dot gnu dot org
2005-08-16 21:38 ` wilson at gcc dot gnu dot org

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