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]
Other format: [Raw text]

[Bug optimization/12525] [tree-ssa] wrong code when using asm with +.


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From amacleod at redhat dot com  2003-10-06 15:57 -------
I think its a rewritting into SSA bug. This is the output I see from ssa1:

f ()
{
  register int r;


  # BLOCK 0 (b.c:3).  PRED: -1.  SUCC: -2.
  r_1 = 1;
  __asm__("":"+r" r_2:);
;
}


The asm stmt is using r_2. r_1 is the value initialized, and DCE removes the r_1
= 1 because it isnt being used anywhere in the program.
the asm ought to be using r_1.

Andrew


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