Commit bcfba653 by David Malcolm Committed by David Malcolm

config/epiphany: Use rtx_insn

gcc/
	* config/epiphany/epiphany-protos.h (epiphany_final_prescan_insn):
	Strengthen first param "insn" from rtx to rtx_insn *.

	* config/epiphany/epiphany.c (epiphany_final_prescan_insn):
	Likewise.
	(frame_insn): Likewise for return type.  Introduce local "insn"
	for use in place of local "x" for use as an rtx_insn *.
	(frame_move_insn): Strengthen return type from rtx to rtx_insn *.
	(epiphany_expand_prologue): Likewise for local "insn".
	* config/epiphany/mode-switch-use.c (insert_uses): Likewise.
	* config/epiphany/resolve-sw-modes.c
	(pass_resolve_sw_modes::execute): Likewise for locals "insn" and
	"seq".

From-SVN: r214441
parent aa4e645e
2014-08-25 David Malcolm <dmalcolm@redhat.com> 2014-08-25 David Malcolm <dmalcolm@redhat.com>
* config/epiphany/epiphany-protos.h (epiphany_final_prescan_insn):
Strengthen first param "insn" from rtx to rtx_insn *.
* config/epiphany/epiphany.c (epiphany_final_prescan_insn):
Likewise.
(frame_insn): Likewise for return type. Introduce local "insn"
for use in place of local "x" for use as an rtx_insn *.
(frame_move_insn): Strengthen return type from rtx to rtx_insn *.
(epiphany_expand_prologue): Likewise for local "insn".
* config/epiphany/mode-switch-use.c (insert_uses): Likewise.
* config/epiphany/resolve-sw-modes.c
(pass_resolve_sw_modes::execute): Likewise for locals "insn" and
"seq".
2014-08-25 David Malcolm <dmalcolm@redhat.com>
* config/c6x/c6x-protos.h (c6x_get_unit_specifier): Strengthen * config/c6x/c6x-protos.h (c6x_get_unit_specifier): Strengthen
param from rtx to rtx_insn *. param from rtx to rtx_insn *.
(c6x_final_prescan_insn): Likewise for first param. (c6x_final_prescan_insn): Likewise for first param.
......
...@@ -27,7 +27,7 @@ extern struct rtx_def *gen_compare_reg (enum machine_mode, enum rtx_code, ...@@ -27,7 +27,7 @@ extern struct rtx_def *gen_compare_reg (enum machine_mode, enum rtx_code,
#endif #endif
/* Declarations for various fns used in the .md file. */ /* Declarations for various fns used in the .md file. */
extern void epiphany_final_prescan_insn (rtx, rtx *, int); extern void epiphany_final_prescan_insn (rtx_insn *, rtx *, int);
extern bool epiphany_is_long_call_p (rtx); extern bool epiphany_is_long_call_p (rtx);
extern bool epiphany_small16 (rtx); extern bool epiphany_small16 (rtx);
bool epiphany_uninterruptible_p (tree decl); bool epiphany_uninterruptible_p (tree decl);
......
...@@ -76,7 +76,7 @@ static tree epiphany_handle_forwarder_attribute (tree *, tree, tree, int, ...@@ -76,7 +76,7 @@ static tree epiphany_handle_forwarder_attribute (tree *, tree, tree, int,
bool *); bool *);
static bool epiphany_pass_by_reference (cumulative_args_t, enum machine_mode, static bool epiphany_pass_by_reference (cumulative_args_t, enum machine_mode,
const_tree, bool); const_tree, bool);
static rtx frame_insn (rtx); static rtx_insn *frame_insn (rtx);
/* defines for the initialization of the GCC target structure. */ /* defines for the initialization of the GCC target structure. */
#define TARGET_ATTRIBUTE_TABLE epiphany_attribute_table #define TARGET_ATTRIBUTE_TABLE epiphany_attribute_table
...@@ -1440,7 +1440,7 @@ epiphany_print_operand_address (FILE *file, rtx addr) ...@@ -1440,7 +1440,7 @@ epiphany_print_operand_address (FILE *file, rtx addr)
} }
void void
epiphany_final_prescan_insn (rtx insn ATTRIBUTE_UNUSED, epiphany_final_prescan_insn (rtx_insn *insn ATTRIBUTE_UNUSED,
rtx *opvec ATTRIBUTE_UNUSED, rtx *opvec ATTRIBUTE_UNUSED,
int noperands ATTRIBUTE_UNUSED) int noperands ATTRIBUTE_UNUSED)
{ {
...@@ -1545,11 +1545,12 @@ frame_subreg_note (rtx set, int offset) ...@@ -1545,11 +1545,12 @@ frame_subreg_note (rtx set, int offset)
return set; return set;
} }
static rtx static rtx_insn *
frame_insn (rtx x) frame_insn (rtx x)
{ {
int i; int i;
rtx note = NULL_RTX; rtx note = NULL_RTX;
rtx_insn *insn;
if (GET_CODE (x) == PARALLEL) if (GET_CODE (x) == PARALLEL)
{ {
...@@ -1584,14 +1585,14 @@ frame_insn (rtx x) ...@@ -1584,14 +1585,14 @@ frame_insn (rtx x)
note = gen_rtx_PARALLEL (VOIDmode, note = gen_rtx_PARALLEL (VOIDmode,
gen_rtvec (2, frame_subreg_note (x, 0), gen_rtvec (2, frame_subreg_note (x, 0),
frame_subreg_note (x, UNITS_PER_WORD))); frame_subreg_note (x, UNITS_PER_WORD)));
x = emit_insn (x); insn = emit_insn (x);
RTX_FRAME_RELATED_P (x) = 1; RTX_FRAME_RELATED_P (insn) = 1;
if (note) if (note)
add_reg_note (x, REG_FRAME_RELATED_EXPR, note); add_reg_note (insn, REG_FRAME_RELATED_EXPR, note);
return x; return insn;
} }
static rtx static rtx_insn *
frame_move_insn (rtx to, rtx from) frame_move_insn (rtx to, rtx from)
{ {
return frame_insn (gen_rtx_SET (VOIDmode, to, from)); return frame_insn (gen_rtx_SET (VOIDmode, to, from));
...@@ -1819,7 +1820,8 @@ epiphany_expand_prologue (void) ...@@ -1819,7 +1820,8 @@ epiphany_expand_prologue (void)
register save. */ register save. */
if (current_frame_info.last_slot >= 0) if (current_frame_info.last_slot >= 0)
{ {
rtx ip, mem2, insn, note; rtx ip, mem2, note;
rtx_insn *insn;
gcc_assert (current_frame_info.last_slot != GPR_FP gcc_assert (current_frame_info.last_slot != GPR_FP
|| (!current_frame_info.need_fp || (!current_frame_info.need_fp
......
...@@ -49,7 +49,7 @@ insert_uses (void) ...@@ -49,7 +49,7 @@ insert_uses (void)
for (e = N_ENTITIES - 1; e >= 0; e--) for (e = N_ENTITIES - 1; e >= 0; e--)
{ {
int no_mode = num_modes[e]; int no_mode = num_modes[e];
rtx insn; rtx_insn *insn;
int mode; int mode;
if (!OPTIMIZE_MODE_SWITCHING (e)) if (!OPTIMIZE_MODE_SWITCHING (e))
......
...@@ -77,7 +77,8 @@ unsigned ...@@ -77,7 +77,8 @@ unsigned
pass_resolve_sw_modes::execute (function *fun) pass_resolve_sw_modes::execute (function *fun)
{ {
basic_block bb; basic_block bb;
rtx insn, src; rtx_insn *insn;
rtx src;
vec<basic_block> todo; vec<basic_block> todo;
sbitmap pushed; sbitmap pushed;
bool need_commit = false; bool need_commit = false;
...@@ -155,7 +156,7 @@ pass_resolve_sw_modes::execute (function *fun) ...@@ -155,7 +156,7 @@ pass_resolve_sw_modes::execute (function *fun)
FOR_EACH_EDGE (e, ei, bb->succs) FOR_EACH_EDGE (e, ei, bb->succs)
{ {
basic_block succ = e->dest; basic_block succ = e->dest;
rtx seq; rtx_insn *seq;
if (!REGNO_REG_SET_P (DF_LIVE_IN (succ), jilted_reg)) if (!REGNO_REG_SET_P (DF_LIVE_IN (succ), jilted_reg))
continue; continue;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment