aboutsummaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2014-08-19 20:08:20 +0000
committerDavid Malcolm <dmalcolm@gcc.gnu.org>2014-08-19 20:08:20 +0000
commit66e8df5354f2d9c705d5d8ae461cc76aaf0d1b0c (patch)
treec357a9a9e901f39a3832334ff03c10d8bf88f08d /gcc/emit-rtl.c
parent7a688d527cb2bc88c93946c16951263be80e46e6 (diff)
downloadgcc-66e8df5354f2d9c705d5d8ae461cc76aaf0d1b0c.zip
gcc-66e8df5354f2d9c705d5d8ae461cc76aaf0d1b0c.tar.gz
gcc-66e8df5354f2d9c705d5d8ae461cc76aaf0d1b0c.tar.bz2
Convert various rtx to rtx_note *
2014-08-19 David Malcolm <dmalcolm@redhat.com> * basic-block.h (create_basic_block_structure): Strengthen third param "bb_note" from rtx to rtx_note *. * rtl.h (emit_note_before): Strengthen return type from rtx to rtx_note *. (emit_note_after): Likewise. (emit_note): Likewise. (emit_note_copy): Likewise. Also, strengthen param similarly. * function.h (struct rtl_data): Strengthen field "x_stack_check_probe_note" from rtx to rtx_note *. * cfgexpand.c (expand_gimple_basic_block): Strengthen local "note" from rtx to rtx_note *. * cfgrtl.c (create_basic_block_structure): Strengthen third param "bb_note" from rtx to rtx_note *. (duplicate_insn_chain): Likewise for local "last". Add a checked cast when calling emit_note_copy. * emit-rtl.c (make_note_raw): Strengthen return type from rtx to rtx_note *. (emit_note_after): Likewise. (emit_note_before): Likewise. (emit_note_copy): Likewise. Also, strengthen param similarly. (emit_note): Likewise. * except.c (emit_note_eh_region_end): Likewise for return type. Strengthen local "next" from rtx to rtx_insn *. (convert_to_eh_region_ranges): Strengthen local "note" from rtx to rtx_note *. * final.c (change_scope): Likewise. (reemit_insn_block_notes): Likewise, for both locals named "note". Also, strengthen local "insn" from rtx to rtx_insn *. * haifa-sched.c (sched_extend_bb): Strengthen local "note" from rtx to rtx_note *. * reg-stack.c (compensate_edge): Likewise for local "after". Also, strengthen local "seq" from rtx to rtx_insn *. * reload1.c (reload_as_needed): Strengthen local "marker" from rtx to rtx_note *. * sel-sched-ir.c (bb_note_pool): Strengthen from rtx_vec_t to vec<rtx_note *>. (get_bb_note_from_pool): Strengthen return type from rtx to rtx_note *. (sel_create_basic_block): Strengthen local "new_bb_note" from insn_t to rtx_note *. * var-tracking.c (emit_note_insn_var_location): Strengthen local "note" from rtx to rtx_note *. (emit_notes_in_bb): Likewise. From-SVN: r214192
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index 218ddc4..a254f9a 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -3852,7 +3852,7 @@ make_call_insn_raw (rtx pattern)
/* Like `make_insn_raw' but make a NOTE instead of an insn. */
-static rtx
+static rtx_note *
make_note_raw (enum insn_note subtype)
{
/* Some notes are never created this way at all. These notes are
@@ -3860,7 +3860,7 @@ make_note_raw (enum insn_note subtype)
gcc_assert (subtype != NOTE_INSN_DELETED_LABEL
&& subtype != NOTE_INSN_DELETED_DEBUG_LABEL);
- rtx note = rtx_alloc (NOTE);
+ rtx_note *note = as_a <rtx_note *> (rtx_alloc (NOTE));
INSN_UID (note) = cur_insn_uid++;
NOTE_KIND (note) = subtype;
BLOCK_FOR_INSN (note) = NULL;
@@ -4557,10 +4557,10 @@ note_outside_basic_block_p (enum insn_note subtype, bool on_bb_boundary_p)
/* Emit a note of subtype SUBTYPE after the insn AFTER. */
-rtx
+rtx_note *
emit_note_after (enum insn_note subtype, rtx after)
{
- rtx note = make_note_raw (subtype);
+ rtx_note *note = make_note_raw (subtype);
basic_block bb = BARRIER_P (after) ? NULL : BLOCK_FOR_INSN (after);
bool on_bb_boundary_p = (bb != NULL && BB_END (bb) == after);
@@ -4573,10 +4573,10 @@ emit_note_after (enum insn_note subtype, rtx after)
/* Emit a note of subtype SUBTYPE before the insn BEFORE. */
-rtx
+rtx_note *
emit_note_before (enum insn_note subtype, rtx before)
{
- rtx note = make_note_raw (subtype);
+ rtx_note *note = make_note_raw (subtype);
basic_block bb = BARRIER_P (before) ? NULL : BLOCK_FOR_INSN (before);
bool on_bb_boundary_p = (bb != NULL && BB_HEAD (bb) == before);
@@ -5023,11 +5023,11 @@ emit_barrier (void)
/* Emit a copy of note ORIG. */
-rtx
-emit_note_copy (rtx orig)
+rtx_note *
+emit_note_copy (rtx_note *orig)
{
enum insn_note kind = (enum insn_note) NOTE_KIND (orig);
- rtx note = make_note_raw (kind);
+ rtx_note *note = make_note_raw (kind);
NOTE_DATA (note) = NOTE_DATA (orig);
add_insn (note);
return note;
@@ -5036,10 +5036,10 @@ emit_note_copy (rtx orig)
/* Make an insn of code NOTE or type NOTE_NO
and add it to the end of the doubly-linked list. */
-rtx
+rtx_note *
emit_note (enum insn_note kind)
{
- rtx note = make_note_raw (kind);
+ rtx_note *note = make_note_raw (kind);
add_insn (note);
return note;
}