OpenMP: Remove dead code from declare variant reimplementation
After reimplementing late resolution of "declare variant", the declare_variant_alt and calls_declare_variant_alt flags on struct cgraph_node are no longer used by anything. For the purposes of marking functions that need late resolution, the has_omp_variant_constructs flag has replaced calls_declare_variant_alt. Likewise struct omp_declare_variant_entry, struct omp_declare_variant_base_entry, and the hash tables used to store these structures are no longer needed, since the information needed for late resolution is now stored in the gomp_variant_construct nodes. In addition, some obsolete code that was temporarily ifdef'ed out instead of delted in order to produce a more readable patch for the previous installment of this series is now removed entirely. There are no functional changes in this patch, just removing dead code. gcc/ChangeLog * cgraph.cc (symbol_table::create_edge): Don't set calls_declare_variant_alt in the caller. * cgraph.h (struct cgraph_node): Remove declare_variant_alt and calls_declare_variant_alt flags. * cgraphclones.cc (cgraph_node::create_clone): Don't copy calls_declare_variant_alt bit. * gimplify.cc: Remove previously #ifdef-ed out code. * ipa-free-lang-data.cc (free_lang_data_in_decl): Adjust code referencing declare_variant_alt bit. * ipa.cc (symbol_table::remove_unreachable_nodes): Likewise. * lto-cgraph.cc (lto_output_node): Remove references to deleted bits. (output_refs): Adjust code referencing declare_variant_alt bit. (input_overwrite_node): Remove references to deleted bits. (input_refs): Adjust code referencing declare_variant_alt bit. * lto-streamer-out.cc (lto_output): Likewise. * lto-streamer.h (omp_lto_output_declare_variant_alt): Delete. (omp_lto_input_declare_variant_alt): Delete. * omp-expand.cc (expand_omp_target): Use has_omp_variant_constructs bit to trigger pass_omp_device_lower instead of calls_declare_variant_alt. * omp-general.cc (struct omp_declare_variant_entry): Delete. (struct omp_declare_variant_base_entry): Delete. (struct omp_declare_variant_hasher): Delete. (omp_declare_variant_hasher::hash): Delete. (omp_declare_variant_hasher::equal): Delete. (omp_declare_variants): Delete. (omp_declare_variant_alt_hasher): Delete. (omp_declare_variant_alt_hasher::hash): Delete. (omp_declare_variant_alt_hasher::equal): Delete. (omp_declare_variant_alt): Delete. (omp_lto_output_declare_variant_alt): Delete. (omp_lto_input_declare_variant_alt): Delete. (includes): Delete unnecessary include of gt-omp-general.h. * omp-offload.cc (execute_omp_device_lower): Remove references to deleted bit. (pass_omp_device_lower::gate): Likewise. * omp-simd-clone.cc (simd_clone_create): Likewise. * passes.cc (ipa_write_summaries): Likeise. * symtab.cc (symtab_node::get_partitioning_class): Likewise. * tree-inline.cc (expand_call_inline): Likewise. (tree_function_versioning): Likewise. gcc/lto/ChangeLog * lto-partition.cc (lto_balanced_map): Adjust code referencing deleted declare_variant_alt bit.
Showing
- gcc/cgraph.cc 0 additions, 2 deletionsgcc/cgraph.cc
- gcc/cgraph.h 2 additions, 9 deletionsgcc/cgraph.h
- gcc/cgraphclones.cc 0 additions, 1 deletiongcc/cgraphclones.cc
- gcc/gimplify.cc 0 additions, 149 deletionsgcc/gimplify.cc
- gcc/ipa-free-lang-data.cc 1 addition, 1 deletiongcc/ipa-free-lang-data.cc
- gcc/ipa.cc 0 additions, 3 deletionsgcc/ipa.cc
- gcc/lto-cgraph.cc 0 additions, 10 deletionsgcc/lto-cgraph.cc
- gcc/lto-streamer-out.cc 1 addition, 2 deletionsgcc/lto-streamer-out.cc
- gcc/lto-streamer.h 0 additions, 6 deletionsgcc/lto-streamer.h
- gcc/lto/lto-partition.cc 2 additions, 3 deletionsgcc/lto/lto-partition.cc
- gcc/omp-expand.cc 1 addition, 1 deletiongcc/omp-expand.cc
- gcc/omp-general.cc 0 additions, 1097 deletionsgcc/omp-general.cc
- gcc/omp-offload.cc 1 addition, 7 deletionsgcc/omp-offload.cc
- gcc/omp-simd-clone.cc 0 additions, 2 deletionsgcc/omp-simd-clone.cc
- gcc/passes.cc 1 addition, 2 deletionsgcc/passes.cc
- gcc/symtab.cc 1 addition, 1 deletiongcc/symtab.cc
- gcc/tree-inline.cc 0 additions, 4 deletionsgcc/tree-inline.cc
Loading
Please register or sign in to comment