On 10/25/14 10:29, Marc Glisse wrote:
On Fri, 24 Oct 2014, Jeff Law wrote:
I'm starting to agree -- a later message indicated you wanted to drop
the unlink_stmt_vdef call and you wanted to avoid gsi_replace, that
seems fine. I'll approve once those things are taken care of.
The following passed bootstrap+testsuite. I wasn't sure what exactly a
clobber is guaranteed not to have (no histograms for instance? At least
I assumed it doesn't throw) so I may have kept some unnecessary calls
when I inlined gsi_replace. I'd be happy to remove any you feel is useless.
2014-10-26 Marc Glisse <marc.gli...@inria.fr>
PR tree-optimization/60770
gcc/
* tree-into-ssa.c: Include value-prof.h.
(maybe_register_def): Replace clobbers with default definitions.
* tree-ssa-live.c: Include tree-ssa.h.
(set_var_live_on_entry): Do not mark undefined variables as live.
(verify_live_on_entry): Do not check undefined variables.
* tree-ssa.h (ssa_undefined_value_p): New parameter for the case
of partially undefined variables.
* tree-ssa.c (ssa_undefined_value_p): Likewise.
(execute_update_addresses_taken): Do not drop clobbers.
gcc/testsuite/
* gcc.dg/tree-ssa/pr60770-1.c: New file.
A clobber doesn't generate any code, it's really best to think of it as
a marker. It doesn't throw, shouldn't have histrograms or anything else
of importance.
Approved.
Jeff