[tree-ssa] Fix gcc.dg/tree-ssa/20030530-2.c
law@redhat.com
law@redhat.com
Wed Jun 11 17:38:00 GMT 2003
In message <wvln0gofx5n.fsf@prospero.boston.redhat.com>, Jason Merrill writes:
>> Also, don't we recognize functions whose calls can be elided if they're
>> called with the same arguments repeatedly? (I forget the technical term
>> :)
>
>"pure". Not yet, because of TREE_SIDE_EFFECTS. Perhaps we shouldn't set
>TREE_SIDE_EFFECTS on calls to pure functions.
Actually, it's "const" -- "pure" functions are allowed to access global
memory. And, yes, it seems to me the best way to get this optimization
is to not set TREE_SIDE_EFFECTS on "const" functions.
Jeff
More information about the Gcc-patches
mailing list