diff options
Diffstat (limited to 'gcc/rtlanal.c')
-rw-r--r-- | gcc/rtlanal.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c index 0e8cb44c8b0..bc16437a257 100644 --- a/gcc/rtlanal.c +++ b/gcc/rtlanal.c @@ -2778,7 +2778,7 @@ rtx_referenced_p (rtx x, rtx body) *LABELP and the jump table to *TABLEP. LABELP and TABLEP may be NULL. */ bool -tablejump_p (const_rtx insn, rtx *labelp, rtx *tablep) +tablejump_p (const_rtx insn, rtx *labelp, rtx_jump_table_data **tablep) { rtx label, table; @@ -2793,7 +2793,7 @@ tablejump_p (const_rtx insn, rtx *labelp, rtx *tablep) if (labelp) *labelp = label; if (tablep) - *tablep = table; + *tablep = as_a <rtx_jump_table_data *> (table); return true; } return false; @@ -3794,14 +3794,15 @@ bool label_is_jump_target_p (const_rtx label, const_rtx jump_insn) { rtx tmp = JUMP_LABEL (jump_insn); + rtx_jump_table_data *table; if (label == tmp) return true; - if (tablejump_p (jump_insn, NULL, &tmp)) + if (tablejump_p (jump_insn, NULL, &table)) { - rtvec vec = XVEC (PATTERN (tmp), - GET_CODE (PATTERN (tmp)) == ADDR_DIFF_VEC); + rtvec vec = XVEC (PATTERN (table), + GET_CODE (PATTERN (table)) == ADDR_DIFF_VEC); int i, veclen = GET_NUM_ELEM (vec); for (i = 0; i < veclen; ++i) |