This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix PR optimization/13653
> Does this happen enough to matter? Has Joern (or anyone) actually
> run code through the compiler to test how often we have a GIV which
> is marked with TREE_READONLY which is the only thing which blocks
> elimination of its BIV?
The testcase I worked on (extracted from POOMA) had this property: a BIV
eliminable once all its GIVs have been reduced, and one of the GIV was
RTX_UNCHANGING_P. I'm under the impression it's not unusual in languages
that make heavy use of constness like C++.
> If the answer is yes, then clearly your patch or something like it is
> absolutely necessary. If the answer is no, then I'd *love* to see
> those tests run to verify that reduction of these kinds of GIVs and
> elimination of their BIVs is important in real code.
The answer is no. I'll do some testing with big C++ code when I have more
time.
--
Eric Botcazou