Introduce gimple_eh_dispatch
commit6cae7b6bf7a9b5a6e46fae677a56a9e88e498f0a
authorDavid Malcolm <dmalcolm@redhat.com>
Mon, 16 Dec 2013 19:07:56 +0000 (16 14:07 -0500)
committerDavid Malcolm <dmalcolm@redhat.com>
Fri, 24 Oct 2014 21:24:14 +0000 (24 17:24 -0400)
tree7f66060ba3780354d3a0052c7c56d58d23db3044
parent53b17ee90d7b80c4947e34eeccc936241a8dca04
Introduce gimple_eh_dispatch

This corresponds to:
  [PATCH 30/89] Introduce gimple_eh_dispatch
  https://gcc.gnu.org/ml/gcc-patches/2014-04/msg01236.html
from the original 89-patch kit

That earlier patch was approved by Jeff:
> OK after fixing up the naming/const stuff as discussed for prior
> patches.
> That applies to 22-30. Make sure to take care of
> the pretty printers per Trevor's comments as well. He indicated those
> were missing in a couple of those patches.
in https://gcc.gnu.org/ml/gcc-patches/2014-05/msg00628.html

gcc/
* coretypes.h (gimple_eh_dispatch): New typedef.
(const_gimple_eh_dispatch): New typedef.

* gimple-pretty-print.c (dump_gimple_eh_dispatch): Require a
gimple_eh_dispatch rather than a plain gimple.
(pp_gimple_stmt_1): Add a checked cast to gimple_eh_dispatch
within GIMPLE_EH_DISPATCH case of switch statement.

* gimple-streamer-in.c (input_gimple_stmt): Likewise.

* gimple-streamer-out.c (output_gimple_stmt): Likewise.

* gimple.c (gimple_build_eh_dispatch): Return a gimple_eh_dispatch
rather than a plain gimple.

* gimple.h (gimple_build_eh_dispatch): Return a gimple_eh_dispatch
rather than a plain gimple.
(gimple_eh_dispatch_region): Require a const_gimple_eh_dispatch
rather than a plain const_gimple.
(gimple_eh_dispatch_set_region): Require a gimple_eh_dispatch
rather than a plain gimple.

* tree-cfg.c (make_edges): Add a checked cast to gimple_eh_dispatch
within GIMPLE_EH_DISPATCH case of switch statement.
(gimple_verify_flow_info): Likewise.
(gimple_redirect_edge_and_branch): Likewise.
(move_stmt_r): Likewise, adding a local.

* tree-eh.c (emit_eh_dispatch): Convert local from gimple to
gimple_eh_dispatch.
(make_eh_dispatch_edges): Require a gimple_eh_dispatch rather than
a plain gimple.
(redirect_eh_dispatch_edge): Likewise.
(lower_eh_dispatch): Likewise.
(execute_lower_eh_dispatch): Add a checked cast to
gimple_eh_dispatch.
(mark_reachable_handlers): Likewise.
(verify_eh_dispatch_edge): Require a gimple_eh_dispatch rather
than a plain gimple.

* tree-eh.h (make_eh_dispatch_edges): Likewise.
(redirect_eh_dispatch_edge): Likewise.
(verify_eh_dispatch_edge): Likewise.

* tree-inline.c (remap_gimple_stmt): Add a checked cast to
gimple_eh_dispatch within GIMPLE_EH_DISPATCH case of switch
statement, adding a local.
(copy_edges_for_bb): Add a checked cast to gimple_eh_dispatch.
gcc/ChangeLog.gimple-classes
gcc/coretypes.h
gcc/gimple-pretty-print.c
gcc/gimple-streamer-in.c
gcc/gimple-streamer-out.c
gcc/gimple.c
gcc/gimple.h
gcc/tree-cfg.c
gcc/tree-eh.c
gcc/tree-eh.h
gcc/tree-inline.c