tree-optimization/111294 - better DCE after forwprop
The following adds more aggressive DCE to forwprop to clean up dead
stmts when folding a stmt leaves some operands unused. The patch
uses simple_dce_from_worklist for this purpose, queueing original
operands before substitution and folding, but only if we folded the
stmt.
This removes one dead stmt biasing threading costs in a later pass
but it doesn't resolve the optimization issue in the PR yet.
PR tree-optimization/111294
* tree-ssa-forwprop.cc (pass_forwprop::execute): Track
operands that eventually become dead and use simple_dce_from_worklist
to remove their definitions if they did so.