GCSE considers read only memory clobbered by function calls.
Paolo Bonzini
paolo.bonzini@lu.unisi.ch
Tue May 10 08:39:00 GMT 2005
>>My wild guess is that this was not possible when MEM_READONLY_P was
>>RTX_UNCHANGING_P, and now it is.
>>
>>
>What wasn't possible? the fact that GCSE considers MEM_READONLY_P call
>clobbered or the fact that CSE does not consider it such that?
>
>
I think that it was not so easy as with your patch when RTX_UNCHANGING_P
meant that a location was "write once". Indeed, CSE had some tricks in
the paths that handled RTX_UNCHANGING_P. The patch that killed that flag
(replacing it with MEM_READONLY_P) did some simplification of the code
that handled it:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cse.c.diff?r1=1.307&r2=1.308
RTX_UNCHANGING_P was never mentioned in gcse.c so probably it was not
easy at all to teach gcse.c about it.
(This was not a remark on your patch, but only a half-hearted attempt at
archaeology).
Paolo
More information about the Gcc-patches
mailing list