summaryrefslogtreecommitdiff
path: root/gcc/cfgbuild.c
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2014-08-27 20:33:38 +0000
committerDavid Malcolm <dmalcolm@gcc.gnu.org>2014-08-27 20:33:38 +0000
commitca486330c49fe55964c6d11f1463d70365bdef6b (patch)
tree66e196517fd89856bf4cc787decc8acce49a4e4a /gcc/cfgbuild.c
parent38e60c554d650d2c1fdefea2ba4f70ebf1d31298 (diff)
Use rtx_expr_list for expr_status.x_forced_labels
gcc/ 2014-08-27 David Malcolm <dmalcolm@redhat.com> * function.h (struct expr_status): Strengthen field "x_forced_labels" from rtx to rtx_expr_list *. * cfgbuild.c (make_edges): Split local "x" into two locals, strengthening one from rtx to rtx_expr_list *, and using methods of said class. * dwarf2cfi.c (create_trace_edges): Split local "lab" out; within loop over forced_labels, introduce strengthen it from rtx to rtx_expr_list *, using methods to clarify the code. * jump.c (rebuild_jump_labels_1): Strengthen local "insn" from rtx to rtx_expr_list *, using methods of said class to clarify the code. * reload1.c (set_initial_label_offsets): Split local "x" into two per-loop variables, strengthening the first from rtx to rtx_expr_list * and using methods. From-SVN: r214602
Diffstat (limited to 'gcc/cfgbuild.c')
-rw-r--r--gcc/cfgbuild.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/gcc/cfgbuild.c b/gcc/cfgbuild.c
index dd6ed7a00e1..05adac0cbc4 100644
--- a/gcc/cfgbuild.c
+++ b/gcc/cfgbuild.c
@@ -219,7 +219,6 @@ make_edges (basic_block min, basic_block max, int update_p)
FOR_BB_BETWEEN (bb, min, max->next_bb, next_bb)
{
rtx_insn *insn;
- rtx x;
enum rtx_code code;
edge e;
edge_iterator ei;
@@ -285,8 +284,8 @@ make_edges (basic_block min, basic_block max, int update_p)
everything on the forced_labels list. */
else if (computed_jump_p (insn))
{
- for (x = forced_labels; x; x = XEXP (x, 1))
- make_label_edge (edge_cache, bb, XEXP (x, 0), EDGE_ABNORMAL);
+ for (rtx_expr_list *x = forced_labels; x; x = x->next ())
+ make_label_edge (edge_cache, bb, x->element (), EDGE_ABNORMAL);
}
/* Returns create an exit out. */
@@ -338,7 +337,7 @@ make_edges (basic_block min, basic_block max, int update_p)
taken, then only calls to those functions or to other
nested functions that use them could possibly do
nonlocal gotos. */
- for (x = nonlocal_goto_handler_labels; x; x = XEXP (x, 1))
+ for (rtx x = nonlocal_goto_handler_labels; x; x = XEXP (x, 1))
make_label_edge (edge_cache, bb, XEXP (x, 0),
EDGE_ABNORMAL | EDGE_ABNORMAL_CALL);
}