public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/18287] New: Unaligned access to fields inside packed records
@ 2004-11-03 17:51 ebotcazou at gcc dot gnu dot org
  2004-11-03 17:53 ` [Bug c/18287] " ebotcazou at gcc dot gnu dot org
                   ` (13 more replies)
  0 siblings, 14 replies; 15+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2004-11-03 17:51 UTC (permalink / raw)
  To: gcc-bugs

The testcase I'm about to attach generates a bug error at runtime on the SPARC
(and very likely on any other STRICT_ALIGNMENT target).  Verified with 2.95.3,
3.3.x, 3.4.x and 4.0pre.

I think the front-end wrongly turns ADDR_EXPR<COMPONENT_REF<INDIRECT_REF>> into
PLUS_EXPR whatever the alignment of the field.  For reference, the Ada front-end
doesn't do the simplification and lets the middle-end generate the temporary if
required.

-- 
           Summary: Unaligned access to fields inside packed records
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: ebotcazou at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: *-*-*
  GCC host triplet: *-*-*
GCC target triplet: *-*-*


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


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

end of thread, other threads:[~2005-01-04  9:14 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-11-03 17:51 [Bug c/18287] New: Unaligned access to fields inside packed records ebotcazou at gcc dot gnu dot org
2004-11-03 17:53 ` [Bug c/18287] " ebotcazou at gcc dot gnu dot org
2004-11-03 18:02 ` pinskia at gcc dot gnu dot org
2004-11-03 18:03 ` pinskia at gcc dot gnu dot org
2004-11-03 18:17 ` ebotcazou at gcc dot gnu dot org
2004-11-03 19:57 ` pinskia at gcc dot gnu dot org
2004-11-04 16:54 ` wintermute101 at wp dot pl
2005-01-02 10:57 ` ebotcazou at gcc dot gnu dot org
2005-01-02 11:03 ` ebotcazou at gcc dot gnu dot org
2005-01-02 11:12 ` ebotcazou at gcc dot gnu dot org
2005-01-02 16:45 ` giovannibajo at libero dot it
2005-01-02 17:20 ` ebotcazou at gcc dot gnu dot org
2005-01-03 23:16 ` rth at gcc dot gnu dot org
2005-01-04  5:17 ` ebotcazou at gcc dot gnu dot org
2005-01-04  9:14 ` rth 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).