public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/28196]  New: miscompiled initialization of a constant pointer reference with offset (ppc64 target)
@ 2006-06-28 20:44 inbox at b-q-c dot com
  2006-06-28 20:47 ` [Bug c/28196] " inbox at b-q-c dot com
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: inbox at b-q-c dot com @ 2006-06-28 20:44 UTC (permalink / raw)
  To: gcc-bugs

The following code is miscompiled when using -m64 (=ppc64) target:

const static double a = 1.0;
const static double *b = (double*)&a - 1;

&b[1] should be &a, but it's not - there is an additional offset of 0x10000


-- 
           Summary: miscompiled initialization of a constant pointer
                    reference with offset (ppc64 target)
           Product: gcc
           Version: 4.0.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: inbox at b-q-c dot com
 GCC build triplet: powerpc-apple-darwin8.6
  GCC host triplet: powerpc-apple-darwin8.6
GCC target triplet: powerpc-apple-darwin8.6 (ppc64)


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


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

end of thread, other threads:[~2006-06-28 21:06 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-28 20:44 [Bug c/28196] New: miscompiled initialization of a constant pointer reference with offset (ppc64 target) inbox at b-q-c dot com
2006-06-28 20:47 ` [Bug c/28196] " inbox at b-q-c dot com
2006-06-28 20:50 ` inbox at b-q-c dot com
2006-06-28 20:51 ` inbox at b-q-c dot com
2006-06-28 21:15 ` pinskia 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).