Enable clustering for switch statements

Programming / Compilers / GCC - marxin [138bc75d-0d04-0410-961f-82ee72b054a4] - 20 June 2018 08:52 EDT

2018-06-20 Martin Liska

- tree-switch-conversion.c (jump_table_cluster::find_jump_tables): New. (bit_test_cluster::find_bit_tests): Likewise. (switch_decision_tree::analyze_switch_statement): Find clusters.
- tree-switch-conversion.h (struct jump_table_cluster): Document hierarchy.

eafe7d87f18 Enable clustering for switch statements.
gcc/ChangeLog | 9 +++
gcc/tree-switch-conversion.c | 176 ++++++++++++++++++++++++++++++++++++++-----
gcc/tree-switch-conversion.h | 19 ++++-
3 files changed, 184 insertions(+), 20 deletions(-)

Upstream: gcc.gnu.org


  • Share