* gimplify.c (compare_case_labels): New function.
commitb624a250a9f8ce1e45c09d1227ff5e2400387621
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 26 May 2004 22:36:49 +0000 (26 22:36 +0000)
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 26 May 2004 22:36:49 +0000 (26 22:36 +0000)
tree9a721edcedc47294d0570c2ba52be9541243aeec
parent902c164d119a9062cadc0ceb20655f4566845ca6
* gimplify.c (compare_case_labels): New function.
(gimplify_switch_expr): Sort case labels, and make sure the
last label in the label vector is the default case.
* tree-cfg.c (group_case_labels): New function.
(build_tree_cfg): Cleanup redundant labels and group case labels
before creating edges.
(cleanup_dead_labels): Handle GOTO_EXPRs.
(find_case_label_for_value): Use a binary search to find the
case label for the given value.
* tree-gimple.c: Mention that labels are sorted, and that the
last label must be the default.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@82297 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/gimplify.c
gcc/stmt.c
gcc/tree-cfg.c
gcc/tree-gimple.c