mirror of git://gcc.gnu.org/git/gcc.git
tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
2018-04-28 Richard Biener <rguenther@suse.de> * tree-cfg.c (verify_gimple_phi): Take a gphi * argument. (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts to reflect use. Only add interesting stmts. From-SVN: r259738
This commit is contained in:
parent
5c2cab4656
commit
782e476490
|
|
@ -1,3 +1,9 @@
|
||||||
|
2018-04-28 Richard Biener <rguenther@suse.de>
|
||||||
|
|
||||||
|
* tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
|
||||||
|
(verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
|
||||||
|
to reflect use. Only add interesting stmts.
|
||||||
|
|
||||||
2018-04-27 Martin Jambor <mjambor@suse.cz>
|
2018-04-27 Martin Jambor <mjambor@suse.cz>
|
||||||
|
|
||||||
PR ipa/85549
|
PR ipa/85549
|
||||||
|
|
|
||||||
|
|
@ -5055,7 +5055,7 @@ verify_gimple_stmt (gimple *stmt)
|
||||||
and false otherwise. */
|
and false otherwise. */
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
verify_gimple_phi (gimple *phi)
|
verify_gimple_phi (gphi *phi)
|
||||||
{
|
{
|
||||||
bool err = false;
|
bool err = false;
|
||||||
unsigned i;
|
unsigned i;
|
||||||
|
|
@ -5374,7 +5374,7 @@ verify_gimple_in_cfg (struct function *fn, bool verify_nothrow)
|
||||||
|
|
||||||
timevar_push (TV_TREE_STMT_VERIFY);
|
timevar_push (TV_TREE_STMT_VERIFY);
|
||||||
hash_set<void *> visited;
|
hash_set<void *> visited;
|
||||||
hash_set<gimple *> visited_stmts;
|
hash_set<gimple *> visited_throwing_stmts;
|
||||||
|
|
||||||
/* Collect all BLOCKs referenced by the BLOCK tree of FN. */
|
/* Collect all BLOCKs referenced by the BLOCK tree of FN. */
|
||||||
hash_set<tree> blocks;
|
hash_set<tree> blocks;
|
||||||
|
|
@ -5396,8 +5396,6 @@ verify_gimple_in_cfg (struct function *fn, bool verify_nothrow)
|
||||||
bool err2 = false;
|
bool err2 = false;
|
||||||
unsigned i;
|
unsigned i;
|
||||||
|
|
||||||
visited_stmts.add (phi);
|
|
||||||
|
|
||||||
if (gimple_bb (phi) != bb)
|
if (gimple_bb (phi) != bb)
|
||||||
{
|
{
|
||||||
error ("gimple_bb (phi) is set to a wrong basic block");
|
error ("gimple_bb (phi) is set to a wrong basic block");
|
||||||
|
|
@ -5453,8 +5451,6 @@ verify_gimple_in_cfg (struct function *fn, bool verify_nothrow)
|
||||||
tree addr;
|
tree addr;
|
||||||
int lp_nr;
|
int lp_nr;
|
||||||
|
|
||||||
visited_stmts.add (stmt);
|
|
||||||
|
|
||||||
if (gimple_bb (stmt) != bb)
|
if (gimple_bb (stmt) != bb)
|
||||||
{
|
{
|
||||||
error ("gimple_bb (stmt) is set to a wrong basic block");
|
error ("gimple_bb (stmt) is set to a wrong basic block");
|
||||||
|
|
@ -5504,6 +5500,8 @@ verify_gimple_in_cfg (struct function *fn, bool verify_nothrow)
|
||||||
that they cannot throw, that we update other data structures
|
that they cannot throw, that we update other data structures
|
||||||
to match. */
|
to match. */
|
||||||
lp_nr = lookup_stmt_eh_lp (stmt);
|
lp_nr = lookup_stmt_eh_lp (stmt);
|
||||||
|
if (lp_nr != 0)
|
||||||
|
visited_throwing_stmts.add (stmt);
|
||||||
if (lp_nr > 0)
|
if (lp_nr > 0)
|
||||||
{
|
{
|
||||||
if (!stmt_could_throw_p (stmt))
|
if (!stmt_could_throw_p (stmt))
|
||||||
|
|
@ -5527,11 +5525,11 @@ verify_gimple_in_cfg (struct function *fn, bool verify_nothrow)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
eh_error_found = false;
|
|
||||||
hash_map<gimple *, int> *eh_table = get_eh_throw_stmt_table (cfun);
|
hash_map<gimple *, int> *eh_table = get_eh_throw_stmt_table (cfun);
|
||||||
|
eh_error_found = false;
|
||||||
if (eh_table)
|
if (eh_table)
|
||||||
eh_table->traverse<hash_set<gimple *> *, verify_eh_throw_stmt_node>
|
eh_table->traverse<hash_set<gimple *> *, verify_eh_throw_stmt_node>
|
||||||
(&visited_stmts);
|
(&visited_throwing_stmts);
|
||||||
|
|
||||||
if (err || eh_error_found)
|
if (err || eh_error_found)
|
||||||
internal_error ("verify_gimple failed");
|
internal_error ("verify_gimple failed");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue