diff options
author | Martin Liska <mliska@suse.cz> | 2019-06-25 13:50:12 +0200 |
---|---|---|
committer | Martin Liska <marxin@gcc.gnu.org> | 2019-06-25 11:50:12 +0000 |
commit | adef5d4f4eee1394c862cafc4cb33395af68bc4a (patch) | |
tree | 02f6fcfba0eb88baeda1d4aed30c03e59b05b6bd /gcc/df-scan.c | |
parent | e5ce4cbc72adbfc8284ed6998b7d36c9f50c1ef6 (diff) | |
download | gcc-adef5d4f4eee1394c862cafc4cb33395af68bc4a.zip gcc-adef5d4f4eee1394c862cafc4cb33395af68bc4a.tar.gz gcc-adef5d4f4eee1394c862cafc4cb33395af68bc4a.tar.bz2 |
Remove dead code in df-scan.c (PR tree-optimization/90978).
2019-06-25 Martin Liska <mliska@suse.cz>
PR tree-optimization/90978
* df-scan.c (df_update_entry_block_defs): Remove dead else
branch.
(df_update_exit_block_uses): Likewise.
From-SVN: r272651
Diffstat (limited to 'gcc/df-scan.c')
-rw-r--r-- | gcc/df-scan.c | 44 |
1 files changed, 12 insertions, 32 deletions
diff --git a/gcc/df-scan.c b/gcc/df-scan.c index 08d7af3..2eea149 100644 --- a/gcc/df-scan.c +++ b/gcc/df-scan.c @@ -3601,23 +3601,13 @@ df_update_entry_block_defs (void) auto_bitmap refs (&df_bitmap_obstack); df_get_entry_block_def_set (refs); - if (df->entry_block_defs) + gcc_assert (df->entry_block_defs); + if (!bitmap_equal_p (df->entry_block_defs, refs)) { - if (!bitmap_equal_p (df->entry_block_defs, refs)) - { - struct df_scan_bb_info *bb_info = df_scan_get_bb_info (ENTRY_BLOCK); - df_ref_chain_delete_du_chain (bb_info->artificial_defs); - df_ref_chain_delete (bb_info->artificial_defs); - bb_info->artificial_defs = NULL; - changed = true; - } - } - else - { - struct df_scan_problem_data *problem_data - = (struct df_scan_problem_data *) df_scan->problem_data; - gcc_unreachable (); - df->entry_block_defs = BITMAP_ALLOC (&problem_data->reg_bitmaps); + struct df_scan_bb_info *bb_info = df_scan_get_bb_info (ENTRY_BLOCK); + df_ref_chain_delete_du_chain (bb_info->artificial_defs); + df_ref_chain_delete (bb_info->artificial_defs); + bb_info->artificial_defs = NULL; changed = true; } @@ -3775,23 +3765,13 @@ df_update_exit_block_uses (void) auto_bitmap refs (&df_bitmap_obstack); df_get_exit_block_use_set (refs); - if (df->exit_block_uses) + gcc_assert (df->exit_block_uses); + if (!bitmap_equal_p (df->exit_block_uses, refs)) { - if (!bitmap_equal_p (df->exit_block_uses, refs)) - { - struct df_scan_bb_info *bb_info = df_scan_get_bb_info (EXIT_BLOCK); - df_ref_chain_delete_du_chain (bb_info->artificial_uses); - df_ref_chain_delete (bb_info->artificial_uses); - bb_info->artificial_uses = NULL; - changed = true; - } - } - else - { - struct df_scan_problem_data *problem_data - = (struct df_scan_problem_data *) df_scan->problem_data; - gcc_unreachable (); - df->exit_block_uses = BITMAP_ALLOC (&problem_data->reg_bitmaps); + struct df_scan_bb_info *bb_info = df_scan_get_bb_info (EXIT_BLOCK); + df_ref_chain_delete_du_chain (bb_info->artificial_uses); + df_ref_chain_delete (bb_info->artificial_uses); + bb_info->artificial_uses = NULL; changed = true; } |