------- Comment #2 from burnus at gcc dot gnu dot org  2008-04-04 14:14 -------
> Confirmed on powerpc-apple-darwin9 (but not on i686-apple-darwin9). The bus
> error comes from the statement 'b%b=-a%b' in function 'neg_at'. If I insert
> 'print *, allocated(a%b)' in the function, I get .false. on powerpc (but 
> .true.
> for i686) for 't1=-t1'.

Also confirmed on x86-64-linux. I always get non allocated before and allocated
after the allocation statement, which looks OK.

I have to admit, I did not quickly see in the dump (-fdump-tree-original) why
it is failing; at a glance, both calling "neg_at" in MAIN__ and the assignment
in "neg_at" itself look ok; and "t2 = -t1" also works.

Side question: Why do we initialize b.b.data with NULL 3 times?

  b.b.data = 0B;
  b.b.data = 0B;
  {
    struct alltype alltype.0;
    alltype.0.b.data = 0B;
    b = alltype.0;
  }


-- 

burnus at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |wrong-code
   Last reconfirmed|0000-00-00 00:00:00         |2008-04-04 14:14:38
               date|                            |


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

Reply via email to