On mainline, we do a lot of work on constant propagation, DCE, and DOM
among other things, so delete_trivially_dead_insns does not have as
many opportunities to remove insns. Here are some numbers obtained
while compiling cc1-i files.
version 2 iter 3 iter insns
-----------------------------
3.4.2 14639 67 246955
mainline 10906 0 82722
"2 iter" is the number of times d_t_d_i had two iterations. "3 iter"
is similarly defined. "insns" is the number of insns deleted by
d_t_d_i. Note that d_t_d_i never iterates 3 times or more on mainline
and that it never iterates 4 iterations or more on 3.4.2 during the
test above.
The patch simply drops the idea of iterating until we reach a fixed
point.