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

            Bug ID: 102959
           Summary: gdc.dg/torture/pr96435.d FAILs
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: d
          Assignee: ibuclaw at gdcproject dot org
          Reporter: ro at gcc dot gnu.org
  Target Milestone: ---
            Target: sparc*-sun-solaris2.11, hppa-unknown-linux-gnu

The gdc.dg/torture/pr96435.d test has been FAILing on SPARC (32 and 64-bit) and
HPPA since it was installed:

FAIL: gdc.dg/torture/pr96435.d   -O0  execution test
FAIL: gdc.dg/torture/pr96435.d   -O0 -frelease  execution test
FAIL: gdc.dg/torture/pr96435.d   -O0 -frelease -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O0 -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O1  execution test
FAIL: gdc.dg/torture/pr96435.d   -O1 -frelease  execution test
FAIL: gdc.dg/torture/pr96435.d   -O1 -frelease -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O1 -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O2  execution test
FAIL: gdc.dg/torture/pr96435.d   -O2 -frelease  execution test
FAIL: gdc.dg/torture/pr96435.d   -O2 -frelease -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O2 -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O3  execution test
FAIL: gdc.dg/torture/pr96435.d   -O3 -frelease  execution test
FAIL: gdc.dg/torture/pr96435.d   -O3 -frelease -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -O3 -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -Os  execution test
FAIL: gdc.dg/torture/pr96435.d   -Os -frelease  execution test
FAIL: gdc.dg/torture/pr96435.d   -Os -frelease -g  execution test
FAIL: gdc.dg/torture/pr96435.d   -Os -g  execution test

Adding -g3 to the -O0 case gives

core.exception.AssertError@/vol/gcc/src/hg/master/local/gcc/testsuite/gdc.dg/torture/pr96435.d(10):
Assertion failure
----------------
/vol/gcc/src/hg/master/local/libphobos/libdruntime/gcc/deh.d:476 _d_throw
[0x93817]
/vol/gcc/src/hg/master/local/libphobos/libdruntime/core/exception.d:441
onAssertError [0x73173]
/vol/gcc/src/hg/master/local/libphobos/libdruntime/core/exception.d:631
_d_assertp [0x733ef]
/vol/gcc/src/hg/master/local/gcc/testsuite/gdc.dg/torture/pr96435.d:10 @safe
bool pr96435.test96435() [0x6ea03]
/vol/gcc/src/hg/master/local/gcc/testsuite/gdc.dg/torture/pr96435.d:16 _Dmain
[0x6e8e3]

Thread 2 hit Breakpoint 1, pr96435.test96435() () at
/vol/gcc/src/hg/master/local/gcc/testsuite/gdc.dg/torture/pr96435.d:6
6           int[2] array = [16, 678];
(gdb) p array
$1 = {0, 0}
(gdb) n
8           U u;
(gdb) p array
$2 = {16, 678}
(gdb) p u
$3 = {i = 0, b = false}
(gdb) n
9           u.i = 0xDEADBEEF;
(gdb) n
10          assert(array[u.b] == 678);
(gdb) p u
$4 = {i = -559038737, b = 222}
(gdb) p/x u.i
$7 = 0xdeadbeef

Reply via email to