This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

FAIL: gcc.c-torture/execute/950628-1.c execution, -O1


There are have been a number of testsuite regressions under hpux 10.20
in the last few weeks.  The is a summary of the failure of 950628-1.c
when compiled with an optimisation higher than -O0.  Here is the initial
snipit of the test:

typedef struct
{
  char hours, day, month;
  short year;
} T;

T g (void)
{
  T now;

  now.hours = 1;
  now.day = 2;
  now.month = 3;
  now.year = 4;
  return now;
}

The assignment `now.year = 4' disappears in the life pass.  Here is the
relevant rtl from the cfg pass:

;; Function g

[deleted]

(note 20 19 22 ("/xxx/gnu/gcc-2.97/gcc/testsuite/gcc.c-torture/execute/950628-1.c") 14 -1347440721)

(insn 22 20 23 (set (reg:HI 98)
        (const_int 4 [0x4])) 91 {*pa.md:2554} (nil)
    (expr_list:REG_EQUAL (const_int 4 [0x4])
        (nil)))

(insn 23 22 24 (set (mem/s:HI (plus:SI (reg/f:SI 3 %r3)
                (const_int 12 [0xc])) 0)
        (reg:HI 98)) 91 {*pa.md:2554} (nil)
    (nil))

(note 24 23 27 ("/xxx/gnu/gcc-2.97/gcc/testsuite/gcc.c-torture/execute/950628-1.c") 15 -1347440721)

Here is what is left after the life pass:

;; Function g

108 registers.

[deleted]

Register 98 used 1 times across 1 insns in block 0; set 1 time; 2 bytes.

[deleted]

1 basic blocks, 2 edges.

Basic block 0: first insn 58, last 57, loop_depth 0, count 0.
Predecessors:  ENTRY (fallthru)
Successors:  EXIT (fallthru)
Registers live at start: 2 [%r2] 3 [%r3] 30 [%r30] 107
Registers live at end: 2 [%r2] 3 [%r3] 28 [%r28] 29 [%r29] 30 [%r30]

(note 20 19 24 ("/xxx/gnu/gcc-2.97/gcc/testsuite/gcc.c-torture/execute/950628-1.c") 14 -1347440721)

(note 24 20 27 ("/xxx/gnu/gcc-2.97/gcc/testsuite/gcc.c-torture/execute/950628-1.c") 15 -1347440721)

Although, register 98 is mentioned in the life analysis, there is now code
referencing this pseudo at the end of the life pass.

Dave
-- 
J. David Anglin                                  dave.anglin@nrc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6605)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]