Coding eror in rtlanal.c:reg_set_last() (GCC 3.4 2004/01/21 snapshot).

Jim Wilson wilson@specifixinc.com
Sat Apr 17 05:06:00 GMT 2004


Anmol Paralkar wrote:
> !           last_value = SET_SRC (set);

This is correct.  However, I see that the function reg_set_last has been 
unused since April 1990, and before that, it was only used in one 
specific place in the jump optimization pass.  It might be better to 
remove it than to fix it.

Are you trying to use it perhaps?  What are you using it for?

I think the function has other potential problems.  For instance, it 
doesn't handle volatile asms.  It shouldn't be moving reg values across 
volatile asms.  It claims that it won't return a MEM, but it returns 
SUBREG without checking for SUBREG MEM.  There may be other problems.

Whether it will work probably depends on what you are trying to do with it.
-- 
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com



More information about the Gcc-bugs mailing list