gcc/
* basic-block.h (set_block_for_insn): Eliminate this macro in
favor of...
* rtl.h (set_block_for_insn): New inline function, imposing the
requirement that the "insn" param is an rtx_insn *.
---
gcc/basic-block.h | 2 --
gcc/rtl.h | 5 +++++
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/gcc/basic-block.h b/gcc/basic-block.h
index dd727c2..fb1c498 100644
--- a/gcc/basic-block.h
+++ b/gcc/basic-block.h
@@ -385,8 +385,6 @@ struct GTY(()) control_flow_graph {
/* The two blocks that are always in the cfg. */
#define NUM_FIXED_BLOCKS (2)
-#define set_block_for_insn(INSN, BB) (BLOCK_FOR_INSN (INSN) = BB)
-
extern void compute_bb_for_insn (void);
extern unsigned int free_bb_for_insn (void);
extern void update_bb_for_insn (basic_block);
diff --git a/gcc/rtl.h b/gcc/rtl.h
index deb206b..7c5bd51 100644
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -1353,6 +1353,11 @@ inline basic_block& BLOCK_FOR_INSN (rtx insn)
return XBBDEF (insn, 2);
}
+inline void set_block_for_insn (rtx_insn *insn, basic_block bb)
+{
+ BLOCK_FOR_INSN (insn) = bb;
+}
+
/* The body of an insn. */
inline rtx PATTERN (const_rtx insn)
{
--
1.8.5.3