From b31d115d2ac149d25ed98bd025d106b5d8555880 Mon Sep 17 00:00:00 2001
From: David Malcolm <dmalcolm@redhat.com>
Date: Tue, 17 Jun 2014 16:24:36 -0400
Subject: [PATCH 068/236] df-*.c: Use rtx_insn

gcc/
	* df-core.c (df_bb_regno_first_def_find): Strengthen local "insn"
	from rtx to rtx_insn *.
	(df_bb_regno_last_def_find): Likewise.

	* df-problems.c (df_rd_bb_local_compute): Likewise.
	(df_lr_bb_local_compute): Likewise.
	(df_live_bb_local_compute): Likewise.
	(df_chain_remove_problem): Likewise.
	(df_chain_create_bb): Likewise.
	(df_word_lr_bb_local_compute): Likewise.
	(df_remove_dead_eq_notes): Likewise for param "insn".
	(df_note_bb_compute): Likewise for local "insn".
	(simulate_backwards_to_point): Likewise.
	(df_md_bb_local_compute): Likewise.

	* df-scan.c (df_scan_free_bb_info): Likewise.
	(df_scan_start_dump): Likewise.
	(df_scan_start_block): Likewise.
	(df_install_ref_incremental): Likewise for local "insn".
	(df_insn_rescan_all): Likewise.
	(df_reorganize_refs_by_reg_by_insn): Likewise.
	(df_reorganize_refs_by_insn_bb): Likewise.
	(df_recompute_luids): Likewise.
	(df_bb_refs_record): Likewise.
	(df_update_entry_exit_and_calls): Likewise.
	(df_bb_verify): Likewise.
---
 gcc/df-core.c     |  4 ++--
 gcc/df-problems.c | 20 ++++++++++----------
 gcc/df-scan.c     | 24 ++++++++++++------------
 3 files changed, 24 insertions(+), 24 deletions(-)

diff --git a/gcc/df-core.c b/gcc/df-core.c
index 0dd8cc4..0267bde 100644
--- a/gcc/df-core.c
+++ b/gcc/df-core.c
@@ -1946,7 +1946,7 @@ df_set_clean_cfg (void)
 df_ref
 df_bb_regno_first_def_find (basic_block bb, unsigned int regno)
 {
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   unsigned int uid;
 
@@ -1972,7 +1972,7 @@ df_bb_regno_first_def_find (basic_block bb, unsigned int regno)
 df_ref
 df_bb_regno_last_def_find (basic_block bb, unsigned int regno)
 {
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   unsigned int uid;
 
diff --git a/gcc/df-problems.c b/gcc/df-problems.c
index 77f8c99..47902f7 100644
--- a/gcc/df-problems.c
+++ b/gcc/df-problems.c
@@ -355,7 +355,7 @@ df_rd_bb_local_compute (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_rd_bb_info *bb_info = df_rd_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
 
   bitmap_clear (&seen_in_block);
   bitmap_clear (&seen_in_insn);
@@ -835,7 +835,7 @@ df_lr_bb_local_compute (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_lr_bb_info *bb_info = df_lr_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   df_ref *use_rec;
 
@@ -1462,7 +1462,7 @@ df_live_bb_local_compute (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_live_bb_info *bb_info = df_live_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   int luid = 0;
 
@@ -1982,7 +1982,7 @@ df_chain_remove_problem (void)
 
   EXECUTE_IF_SET_IN_BITMAP (df_chain->out_of_date_transfer_functions, 0, bb_index, bi)
     {
-      rtx insn;
+      rtx_insn *insn;
       df_ref *def_rec;
       df_ref *use_rec;
       basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
@@ -2105,7 +2105,7 @@ df_chain_create_bb (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_rd_bb_info *bb_info = df_rd_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
   bitmap_head cpy;
 
   bitmap_initialize (&cpy, &bitmap_default_obstack);
@@ -2531,7 +2531,7 @@ df_word_lr_bb_local_compute (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_word_lr_bb_info *bb_info = df_word_lr_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   df_ref *use_rec;
 
@@ -2883,7 +2883,7 @@ df_remove_dead_and_unused_notes (rtx insn)
    as the bitmap of currently live registers.  */
 
 static void
-df_remove_dead_eq_notes (rtx insn, bitmap live)
+df_remove_dead_eq_notes (rtx_insn *insn, bitmap live)
 {
   rtx *pprev = &REG_NOTES (insn);
   rtx link = *pprev;
@@ -3153,7 +3153,7 @@ df_note_bb_compute (unsigned int bb_index,
 		    bitmap live, bitmap do_not_gen, bitmap artificial_uses)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
-  rtx insn;
+  rtx_insn *insn;
   df_ref *def_rec;
   df_ref *use_rec;
   struct dead_debug_local debug;
@@ -3784,7 +3784,7 @@ find_memory_stores (rtx x, const_rtx pat ATTRIBUTE_UNUSED,
 void
 simulate_backwards_to_point (basic_block bb, regset live, rtx point)
 {
-  rtx insn;
+  rtx_insn *insn;
   bitmap_copy (live, df_get_live_out (bb));
   df_simulate_initialize_backwards (bb, live);
 
@@ -4271,7 +4271,7 @@ df_md_bb_local_compute (unsigned int bb_index)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
   struct df_md_bb_info *bb_info = df_md_get_bb_info (bb_index);
-  rtx insn;
+  rtx_insn *insn;
 
   /* Artificials are only hard regs.  */
   if (!(df->changeable_flags & DF_NO_HARD_REGS))
diff --git a/gcc/df-scan.c b/gcc/df-scan.c
index 992d0af..28196b3 100644
--- a/gcc/df-scan.c
+++ b/gcc/df-scan.c
@@ -283,7 +283,7 @@ df_scan_free_bb_info (basic_block bb, void *vbb_info)
   /* See if bb_info is initialized.  */
   if (bb_info->artificial_defs)
     {
-      rtx insn;
+      rtx_insn *insn;
       FOR_BB_INSNS (bb, insn)
 	{
 	  if (INSN_P (insn))
@@ -403,7 +403,7 @@ df_scan_start_dump (FILE *file ATTRIBUTE_UNUSED)
   int icount = 0;
   int ccount = 0;
   basic_block bb;
-  rtx insn;
+  rtx_insn *insn;
 
   fprintf (file, ";;  invalidated by call \t");
   df_print_regset (file, regs_invalidated_by_call_regset);
@@ -482,7 +482,7 @@ df_scan_start_block (basic_block bb, FILE *file)
     }
 #if 0
   {
-    rtx insn;
+    rtx_insn *insn;
     FOR_BB_INSNS (bb, insn)
       if (INSN_P (insn))
 	df_insn_debug (insn, false, file);
@@ -730,7 +730,7 @@ df_install_ref_incremental (df_ref ref)
   unsigned int count = 0;
   bool add_to_table;
 
-  rtx insn = DF_REF_INSN (ref);
+  rtx_insn *insn = DF_REF_INSN (ref);
   basic_block bb = BLOCK_FOR_INSN (insn);
 
   if (DF_REF_REG_DEF_P (ref))
@@ -1417,7 +1417,7 @@ df_insn_rescan_all (void)
 
   FOR_EACH_BB_FN (bb, cfun)
     {
-      rtx insn;
+      rtx_insn *insn;
       FOR_BB_INSNS (bb, insn)
 	{
 	  df_insn_rescan (insn);
@@ -1638,7 +1638,7 @@ df_reorganize_refs_by_reg_by_insn (struct df_ref_info *ref_info,
   EXECUTE_IF_SET_IN_BITMAP (df->blocks_to_analyze, 0, bb_index, bi)
     {
       basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
-      rtx insn;
+      rtx_insn *insn;
       df_ref *ref_rec;
 
       if (include_defs)
@@ -1692,7 +1692,7 @@ df_reorganize_refs_by_reg_by_insn (struct df_ref_info *ref_info,
   EXECUTE_IF_SET_IN_BITMAP (df->blocks_to_analyze, 0, bb_index, bi)
     {
       basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
-      rtx insn;
+      rtx_insn *insn;
       df_ref *ref_rec;
 
       if (include_defs)
@@ -1827,7 +1827,7 @@ df_reorganize_refs_by_insn_bb (basic_block bb, unsigned int offset,
 			       bool include_defs, bool include_uses,
 			       bool include_eq_uses)
 {
-  rtx insn;
+  rtx_insn *insn;
 
   if (include_defs)
     offset = df_add_refs_to_table (offset, ref_info,
@@ -3528,7 +3528,7 @@ df_insn_refs_collect (struct df_collection_rec *collection_rec,
 void
 df_recompute_luids (basic_block bb)
 {
-  rtx insn;
+  rtx_insn *insn;
   int luid = 0;
 
   df_grow_insn_info ();
@@ -3622,7 +3622,7 @@ void
 df_bb_refs_record (int bb_index, bool scan_insns)
 {
   basic_block bb = BASIC_BLOCK_FOR_FN (cfun, bb_index);
-  rtx insn;
+  rtx_insn *insn;
   int luid = 0;
 
   if (!df)
@@ -4159,7 +4159,7 @@ df_update_entry_exit_and_calls (void)
      in the set of registers clobbered across the call.  */
   FOR_EACH_BB_FN (bb, cfun)
     {
-      rtx insn;
+      rtx_insn *insn;
       FOR_BB_INSNS (bb, insn)
 	{
 	  if (INSN_P (insn) && CALL_P (insn))
@@ -4430,7 +4430,7 @@ df_insn_refs_verify (struct df_collection_rec *collection_rec,
 static bool
 df_bb_verify (basic_block bb)
 {
-  rtx insn;
+  rtx_insn *insn;
   struct df_scan_bb_info *bb_info = df_scan_get_bb_info (bb->index);
   struct df_collection_rec collection_rec;
 
-- 
1.8.5.3

