Commit f7d504c2 by Kaveh R. Ghazi Committed by Kaveh Ghazi

cfglayout.c (insn_scope, insn_line): Constify.

	* cfglayout.c (insn_scope, insn_line): Constify.
	* emit-rtl.c (const_int_htab_hash, const_int_htab_eq,
	const_double_htab_hash, const_double_htab_eq,
	mem_attrs_htab_hash): Likewise.
	* loop-iv.c (biv_eq): Likewise.
	* print-rtl.c (print_rtx, print_decl_name, print_mem_expr,
	print_inline_rtx, debug_rtx, debug_rtx_list, debug_rtx_range,
	debug_rtx_find, print_rtl, print_rtl_single, print_simple_rtl):
	Likewise. 
	* rtl-error.c (location_for_asm, diagnostic_for_asm,
	error_for_asm, warning_for_asm, _fatal_insn,
	_fatal_insn_not_found): Likewise. 
	* rtl.c (rtx_size, shared_const_p, shallow_copy_rtx_stat,
	rtx_equal_p, rtl_check_failed_bounds, rtl_check_failed_type1,
	rtl_check_failed_type2, rtl_check_failed_code1,
	rtl_check_failed_code2, rtl_check_failed_code_mode,
	rtvec_check_failed_bounds, rtl_check_failed_flag): Likewise.
	* rtl.h (rtl_check_failed_bounds, rtl_check_failed_type1,
	rtl_check_failed_type2, rtl_check_failed_code1,
	rtl_check_failed_code2, rtl_check_failed_code_mode,
	rtvec_check_failed_bounds, rtl_check_failed_flag, LABEL_KIND,
	SET_LABEL_KIND, rhs_regno, subreg_lsb, subreg_regno, subreg_nregs,
	shared_const_p, rtx_size, shallow_copy_rtx_stat, rtx_equal_p,
	get_pool_mode, insn_line, insn_file, simplify_replace_rtx,
	mode_signbit_p, rtx_addr_can_trap_p, nonzero_address_p,
	rtx_unstable_p, get_integer_term, get_related_value,
	offset_within_block_p, reg_mentioned_p, count_occurrences,
	reg_referenced_p, reg_used_between_p, no_labels_between_p,
	single_set_2, multiple_sets, set_noop_p, refers_to_regno_p,
	reg_overlap_mentioned_p, dead_or_set_p, dead_or_set_regno_p,
	find_reg_note, find_regno_note, find_reg_equal_equiv_note,
	find_constant_src, find_reg_fusage, find_regno_fusage,
	pure_call_p, remove_note, side_effects_p, volatile_refs_p,
	volatile_insn_p, may_trap_p, may_trap_after_code_motion_p,
	may_trap_or_fault_p, inequality_comparisons_p, tablejump_p,
	computed_jump_p, auto_inc_p, in_expr_list_p,
	remove_node_from_expr_list, loc_mentioned_in_p,
	label_is_jump_target_p, reversed_comparison_code_parts,
	debug_rtx, debug_rtx_list, debug_rtx_range, debug_rtx_find,
	print_mem_expr, print_rtl, print_simple_rtl, print_rtl_single,
	print_inline_rtx): Likewise.
	* rtlanal.c (covers_regno_p, covers_regno_no_parallel_p,
	computed_jump_p_1, nonzero_bits1, rtx_unstable_p,
	rtx_addr_can_trap_p_1, rtx_addr_can_trap_p, nonzero_address_p,
	get_integer_term, get_related_value, offset_within_block_p,
	count_occurrences, reg_mentioned_p, no_labels_between_p,
	reg_used_between_p, reg_referenced_p, single_set_2,
	multiple_sets, set_noop_p, refers_to_regno_p,
	reg_overlap_mentioned_p, dead_or_set_p,
	covers_regno_no_parallel_p, covers_regno_p,
	dead_or_set_regno_p, find_reg_note, find_regno_note,
	find_reg_equal_equiv_note, find_constant_src, find_reg_fusage,
	find_regno_fusage, pure_call_p, remove_note, in_expr_list_p,
	remove_node_from_expr_list, volatile_insn_p, volatile_refs_p,
	side_effects_p, may_trap_p_1, may_trap_p,
	may_trap_after_code_motion_p, may_trap_or_fault_p,
	inequality_comparisons_p, tablejump_p, computed_jump_p_1,
	computed_jump_p, auto_inc_p, loc_mentioned_in_p, subreg_lsb,
	subreg_regno, subreg_nregs, label_is_jump_target_p): Likewise.
	* simplify-rtx.c (neg_const_int, plus_minus_operand_p,
	mode_signbit_p, simplify_replace_rtx, plus_minus_operand_p):
	Likewise. 
	* toplev.h (_fatal_insn_not_found, _fatal_insn, error_for_asm,
	warning_for_asm): Likewise.
	* tree.h (print_rtl): Likewise.
	* varasm.c (get_pool_mode): Likewise.

From-SVN: r126922
parent 5f754896
2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* cfglayout.c (insn_scope, insn_line): Constify.
* emit-rtl.c (const_int_htab_hash, const_int_htab_eq,
const_double_htab_hash, const_double_htab_eq,
mem_attrs_htab_hash): Likewise.
* loop-iv.c (biv_eq): Likewise.
* print-rtl.c (print_rtx, print_decl_name, print_mem_expr,
print_inline_rtx, debug_rtx, debug_rtx_list, debug_rtx_range,
debug_rtx_find, print_rtl, print_rtl_single, print_simple_rtl):
Likewise.
* rtl-error.c (location_for_asm, diagnostic_for_asm,
error_for_asm, warning_for_asm, _fatal_insn,
_fatal_insn_not_found): Likewise.
* rtl.c (rtx_size, shared_const_p, shallow_copy_rtx_stat,
rtx_equal_p, rtl_check_failed_bounds, rtl_check_failed_type1,
rtl_check_failed_type2, rtl_check_failed_code1,
rtl_check_failed_code2, rtl_check_failed_code_mode,
rtvec_check_failed_bounds, rtl_check_failed_flag): Likewise.
* rtl.h (rtl_check_failed_bounds, rtl_check_failed_type1,
rtl_check_failed_type2, rtl_check_failed_code1,
rtl_check_failed_code2, rtl_check_failed_code_mode,
rtvec_check_failed_bounds, rtl_check_failed_flag, LABEL_KIND,
SET_LABEL_KIND, rhs_regno, subreg_lsb, subreg_regno, subreg_nregs,
shared_const_p, rtx_size, shallow_copy_rtx_stat, rtx_equal_p,
get_pool_mode, insn_line, insn_file, simplify_replace_rtx,
mode_signbit_p, rtx_addr_can_trap_p, nonzero_address_p,
rtx_unstable_p, get_integer_term, get_related_value,
offset_within_block_p, reg_mentioned_p, count_occurrences,
reg_referenced_p, reg_used_between_p, no_labels_between_p,
single_set_2, multiple_sets, set_noop_p, refers_to_regno_p,
reg_overlap_mentioned_p, dead_or_set_p, dead_or_set_regno_p,
find_reg_note, find_regno_note, find_reg_equal_equiv_note,
find_constant_src, find_reg_fusage, find_regno_fusage,
pure_call_p, remove_note, side_effects_p, volatile_refs_p,
volatile_insn_p, may_trap_p, may_trap_after_code_motion_p,
may_trap_or_fault_p, inequality_comparisons_p, tablejump_p,
computed_jump_p, auto_inc_p, in_expr_list_p,
remove_node_from_expr_list, loc_mentioned_in_p,
label_is_jump_target_p, reversed_comparison_code_parts,
debug_rtx, debug_rtx_list, debug_rtx_range, debug_rtx_find,
print_mem_expr, print_rtl, print_simple_rtl, print_rtl_single,
print_inline_rtx): Likewise.
* rtlanal.c (covers_regno_p, covers_regno_no_parallel_p,
computed_jump_p_1, nonzero_bits1, rtx_unstable_p,
rtx_addr_can_trap_p_1, rtx_addr_can_trap_p, nonzero_address_p,
get_integer_term, get_related_value, offset_within_block_p,
count_occurrences, reg_mentioned_p, no_labels_between_p,
reg_used_between_p, reg_referenced_p, single_set_2,
multiple_sets, set_noop_p, refers_to_regno_p,
reg_overlap_mentioned_p, dead_or_set_p,
covers_regno_no_parallel_p, covers_regno_p,
dead_or_set_regno_p, find_reg_note, find_regno_note,
find_reg_equal_equiv_note, find_constant_src, find_reg_fusage,
find_regno_fusage, pure_call_p, remove_note, in_expr_list_p,
remove_node_from_expr_list, volatile_insn_p, volatile_refs_p,
side_effects_p, may_trap_p_1, may_trap_p,
may_trap_after_code_motion_p, may_trap_or_fault_p,
inequality_comparisons_p, tablejump_p, computed_jump_p_1,
computed_jump_p, auto_inc_p, loc_mentioned_in_p, subreg_lsb,
subreg_regno, subreg_nregs, label_is_jump_target_p): Likewise.
* simplify-rtx.c (neg_const_int, plus_minus_operand_p,
mode_signbit_p, simplify_replace_rtx, plus_minus_operand_p):
Likewise.
* toplev.h (_fatal_insn_not_found, _fatal_insn, error_for_asm,
warning_for_asm): Likewise.
* tree.h (print_rtl): Likewise.
* varasm.c (get_pool_mode): Likewise.
2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* c-lex.c (c_lex_with_flags, lex_string): Constify.
* c-ppoutput.c (print_line, pp_dir_change): Likewise.
* c-typeck.c (free_all_tagged_tu_seen_up_to): Likewise.
......
......@@ -54,7 +54,7 @@ static void change_scope (rtx, tree, tree);
void verify_insn_chain (void);
static void fixup_fallthru_exit_predecessor (void);
static tree insn_scope (rtx);
static tree insn_scope (const_rtx);
rtx
unlink_insn_chain (rtx first, rtx last)
......@@ -451,7 +451,7 @@ change_scope (rtx orig_insn, tree s1, tree s2)
/* Return lexical scope block insn belong to. */
static tree
insn_scope (rtx insn)
insn_scope (const_rtx insn)
{
int max = VEC_length (int, block_locators_locs);
int min = 0;
......@@ -528,7 +528,7 @@ locator_line (int loc)
/* Return line number of the statement that produced this insn. */
int
insn_line (rtx insn)
insn_line (const_rtx insn)
{
return locator_line (INSN_LOCATOR (insn));
}
......@@ -547,7 +547,7 @@ locator_file (int loc)
/* Return source file of the statement that produced this insn. */
const char *
insn_file (rtx insn)
insn_file (const_rtx insn)
{
return locator_file (INSN_LOCATOR (insn));
}
......
......@@ -195,7 +195,7 @@ int split_branch_probability = -1;
static hashval_t
const_int_htab_hash (const void *x)
{
return (hashval_t) INTVAL ((rtx) x);
return (hashval_t) INTVAL ((const_rtx) x);
}
/* Returns nonzero if the value represented by X (which is really a
......@@ -205,14 +205,14 @@ const_int_htab_hash (const void *x)
static int
const_int_htab_eq (const void *x, const void *y)
{
return (INTVAL ((rtx) x) == *((const HOST_WIDE_INT *) y));
return (INTVAL ((const_rtx) x) == *((const HOST_WIDE_INT *) y));
}
/* Returns a hash code for X (which is really a CONST_DOUBLE). */
static hashval_t
const_double_htab_hash (const void *x)
{
rtx value = (rtx) x;
const_rtx const value = (const_rtx) x;
hashval_t h;
if (GET_MODE (value) == VOIDmode)
......@@ -231,7 +231,7 @@ const_double_htab_hash (const void *x)
static int
const_double_htab_eq (const void *x, const void *y)
{
rtx a = (rtx)x, b = (rtx)y;
const_rtx const a = (const_rtx)x, b = (const_rtx)y;
if (GET_MODE (a) != GET_MODE (b))
return 0;
......@@ -248,7 +248,7 @@ const_double_htab_eq (const void *x, const void *y)
static hashval_t
mem_attrs_htab_hash (const void *x)
{
mem_attrs *p = (mem_attrs *) x;
const mem_attrs *const p = (const mem_attrs *) x;
return (p->alias ^ (p->align * 1000)
^ ((p->offset ? INTVAL (p->offset) : 0) * 50000)
......
......@@ -244,7 +244,7 @@ biv_hash (const void *b)
static int
biv_eq (const void *b, const void *r)
{
return ((const struct biv_entry *) b)->regno == REGNO ((rtx) r);
return ((const struct biv_entry *) b)->regno == REGNO ((const_rtx) r);
}
/* Prepare the data for an induction variable analysis of a LOOP. */
......
......@@ -49,7 +49,7 @@ static int sawclose = 0;
static int indent;
static void print_rtx (rtx);
static void print_rtx (const_rtx);
/* String printed at beginning of each RTL when it is dumped.
This string is set to ASM_COMMENT_START when the RTL is dumped in
......@@ -69,7 +69,7 @@ int dump_for_graph;
#ifndef GENERATOR_FILE
static void
print_decl_name (FILE *outfile, tree node)
print_decl_name (FILE *outfile, const_tree node)
{
if (DECL_NAME (node))
fputs (IDENTIFIER_POINTER (DECL_NAME (node)), outfile);
......@@ -86,7 +86,7 @@ print_decl_name (FILE *outfile, tree node)
}
void
print_mem_expr (FILE *outfile, tree expr)
print_mem_expr (FILE *outfile, const_tree expr)
{
if (TREE_CODE (expr) == COMPONENT_REF)
{
......@@ -128,7 +128,7 @@ print_mem_expr (FILE *outfile, tree expr)
/* Print IN_RTX onto OUTFILE. This is the recursive part of printing. */
static void
print_rtx (rtx in_rtx)
print_rtx (const_rtx in_rtx)
{
int i = 0;
int j;
......@@ -603,7 +603,7 @@ print_rtx (rtx in_rtx)
characters. */
void
print_inline_rtx (FILE *outf, rtx x, int ind)
print_inline_rtx (FILE *outf, const_rtx x, int ind)
{
int oldsaw = sawclose;
int oldindent = indent;
......@@ -619,7 +619,7 @@ print_inline_rtx (FILE *outf, rtx x, int ind)
/* Call this function from the debugger to see what X looks like. */
void
debug_rtx (rtx x)
debug_rtx (const_rtx x)
{
outfile = stderr;
sawclose = 0;
......@@ -639,10 +639,10 @@ int debug_rtx_count = 0; /* 0 is treated as equivalent to 1 */
EG: -5 prints 2 rtx's on either side (in addition to the specified rtx). */
void
debug_rtx_list (rtx x, int n)
debug_rtx_list (const_rtx x, int n)
{
int i,count;
rtx insn;
const_rtx insn;
count = n == 0 ? 1 : n < 0 ? -n : n;
......@@ -666,7 +666,7 @@ debug_rtx_list (rtx x, int n)
/* Call this function to print an rtx list from START to END inclusive. */
void
debug_rtx_range (rtx start, rtx end)
debug_rtx_range (const_rtx start, const_rtx end)
{
while (1)
{
......@@ -682,8 +682,8 @@ debug_rtx_range (rtx start, rtx end)
and then call debug_rtx_list to print it, using DEBUG_RTX_COUNT.
The found insn is returned to enable further debugging analysis. */
rtx
debug_rtx_find (rtx x, int uid)
const_rtx
debug_rtx_find (const_rtx x, int uid)
{
while (x != 0 && INSN_UID (x) != uid)
x = NEXT_INSN (x);
......@@ -706,9 +706,9 @@ debug_rtx_find (rtx x, int uid)
If RTX_FIRST is not an insn, then it alone is printed, with no newline. */
void
print_rtl (FILE *outf, rtx rtx_first)
print_rtl (FILE *outf, const_rtx rtx_first)
{
rtx tmp_rtx;
const_rtx tmp_rtx;
outfile = outf;
sawclose = 0;
......@@ -745,7 +745,7 @@ print_rtl (FILE *outf, rtx rtx_first)
/* Return nonzero if we actually printed anything. */
int
print_rtl_single (FILE *outf, rtx x)
print_rtl_single (FILE *outf, const_rtx x)
{
outfile = outf;
sawclose = 0;
......@@ -764,7 +764,7 @@ print_rtl_single (FILE *outf, rtx x)
if RTX is a CONST_INT then print in decimal format. */
void
print_simple_rtl (FILE *outf, rtx x)
print_simple_rtl (FILE *outf, const_rtx x)
{
flag_simple = 1;
print_rtl (outf, x);
......
......@@ -33,12 +33,12 @@ Boston, MA 02110-1301, USA. */
#include "intl.h"
#include "diagnostic.h"
static location_t location_for_asm (rtx);
static void diagnostic_for_asm (rtx, const char *, va_list *, diagnostic_t) ATTRIBUTE_GCC_DIAG(2,0);
static location_t location_for_asm (const_rtx);
static void diagnostic_for_asm (const_rtx, const char *, va_list *, diagnostic_t) ATTRIBUTE_GCC_DIAG(2,0);
/* Figure the location of the given INSN. */
static location_t
location_for_asm (rtx insn)
location_for_asm (const_rtx insn)
{
rtx body = PATTERN (insn);
rtx asmop;
......@@ -76,7 +76,7 @@ location_for_asm (rtx insn)
of the insn INSN. This is used only when INSN is an `asm' with operands,
and each ASM_OPERANDS records its own source file and line. */
static void
diagnostic_for_asm (rtx insn, const char *msg, va_list *args_ptr,
diagnostic_for_asm (const_rtx insn, const char *msg, va_list *args_ptr,
diagnostic_t kind)
{
diagnostic_info diagnostic;
......@@ -87,7 +87,7 @@ diagnostic_for_asm (rtx insn, const char *msg, va_list *args_ptr,
}
void
error_for_asm (rtx insn, const char *gmsgid, ...)
error_for_asm (const_rtx insn, const char *gmsgid, ...)
{
va_list ap;
......@@ -97,7 +97,7 @@ error_for_asm (rtx insn, const char *gmsgid, ...)
}
void
warning_for_asm (rtx insn, const char *gmsgid, ...)
warning_for_asm (const_rtx insn, const char *gmsgid, ...)
{
va_list ap;
......@@ -107,7 +107,7 @@ warning_for_asm (rtx insn, const char *gmsgid, ...)
}
void
_fatal_insn (const char *msgid, rtx insn, const char *file, int line,
_fatal_insn (const char *msgid, const_rtx insn, const char *file, int line,
const char *function)
{
error ("%s", _(msgid));
......@@ -121,7 +121,7 @@ _fatal_insn (const char *msgid, rtx insn, const char *file, int line,
}
void
_fatal_insn_not_found (rtx insn, const char *file, int line,
_fatal_insn_not_found (const_rtx insn, const char *file, int line,
const char *function)
{
if (INSN_CODE (insn) < 0)
......
......@@ -168,7 +168,7 @@ rtvec_alloc (int n)
/* Return the number of bytes occupied by rtx value X. */
unsigned int
rtx_size (rtx x)
rtx_size (const_rtx x)
{
if (GET_CODE (x) == SYMBOL_REF && SYMBOL_REF_HAS_BLOCK_INFO_P (x))
return RTX_HDR_SIZE + sizeof (struct block_symbol);
......@@ -204,7 +204,7 @@ rtx_alloc_stat (RTX_CODE code MEM_STAT_DECL)
/* Return true if ORIG is a sharable CONST. */
bool
shared_const_p (rtx orig)
shared_const_p (const_rtx orig)
{
gcc_assert (GET_CODE (orig) == CONST);
......@@ -319,15 +319,11 @@ copy_rtx (rtx orig)
/* Create a new copy of an rtx. Only copy just one level. */
rtx
shallow_copy_rtx_stat (rtx orig MEM_STAT_DECL)
shallow_copy_rtx_stat (const_rtx orig MEM_STAT_DECL)
{
unsigned int size;
rtx copy;
size = rtx_size (orig);
copy = (rtx) ggc_alloc_zone_pass_stat (size, &rtl_zone);
memcpy (copy, orig, size);
return copy;
const unsigned int size = rtx_size (orig);
rtx const copy = (rtx) ggc_alloc_zone_pass_stat (size, &rtl_zone);
return memcpy (copy, orig, size);
}
/* Nonzero when we are generating CONCATs. */
......@@ -341,7 +337,7 @@ int currently_expanding_to_rtl;
This is the Lisp function EQUAL for rtx arguments. */
int
rtx_equal_p (rtx x, rtx y)
rtx_equal_p (const_rtx x, const_rtx y)
{
int i;
int j;
......@@ -480,7 +476,7 @@ dump_rtx_statistics (void)
#if defined ENABLE_RTL_CHECKING && (GCC_VERSION >= 2007)
void
rtl_check_failed_bounds (rtx r, int n, const char *file, int line,
rtl_check_failed_bounds (const_rtx r, int n, const char *file, int line,
const char *func)
{
internal_error
......@@ -490,7 +486,7 @@ rtl_check_failed_bounds (rtx r, int n, const char *file, int line,
}
void
rtl_check_failed_type1 (rtx r, int n, int c1, const char *file, int line,
rtl_check_failed_type1 (const_rtx r, int n, int c1, const char *file, int line,
const char *func)
{
internal_error
......@@ -500,7 +496,7 @@ rtl_check_failed_type1 (rtx r, int n, int c1, const char *file, int line,
}
void
rtl_check_failed_type2 (rtx r, int n, int c1, int c2, const char *file,
rtl_check_failed_type2 (const_rtx r, int n, int c1, int c2, const char *file,
int line, const char *func)
{
internal_error
......@@ -510,7 +506,7 @@ rtl_check_failed_type2 (rtx r, int n, int c1, int c2, const char *file,
}
void
rtl_check_failed_code1 (rtx r, enum rtx_code code, const char *file,
rtl_check_failed_code1 (const_rtx r, enum rtx_code code, const char *file,
int line, const char *func)
{
internal_error ("RTL check: expected code '%s', have '%s' in %s, at %s:%d",
......@@ -519,7 +515,7 @@ rtl_check_failed_code1 (rtx r, enum rtx_code code, const char *file,
}
void
rtl_check_failed_code2 (rtx r, enum rtx_code code1, enum rtx_code code2,
rtl_check_failed_code2 (const_rtx r, enum rtx_code code1, enum rtx_code code2,
const char *file, int line, const char *func)
{
internal_error
......@@ -529,7 +525,7 @@ rtl_check_failed_code2 (rtx r, enum rtx_code code1, enum rtx_code code2,
}
void
rtl_check_failed_code_mode (rtx r, enum rtx_code code, enum machine_mode mode,
rtl_check_failed_code_mode (const_rtx r, enum rtx_code code, enum machine_mode mode,
bool not_mode, const char *file, int line,
const char *func)
{
......@@ -556,7 +552,7 @@ rtl_check_failed_block_symbol (const char *file, int line, const char *func)
/* XXX Maybe print the vector? */
void
rtvec_check_failed_bounds (rtvec r, int n, const char *file, int line,
rtvec_check_failed_bounds (const_rtvec r, int n, const char *file, int line,
const char *func)
{
internal_error
......@@ -567,7 +563,7 @@ rtvec_check_failed_bounds (rtvec r, int n, const char *file, int line,
#if defined ENABLE_RTL_FLAG_CHECKING
void
rtl_check_failed_flag (const char *name, rtx r, const char *file,
rtl_check_failed_flag (const char *name, const_rtx r, const char *file,
int line, const char *func)
{
internal_error
......
......@@ -50,8 +50,8 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#define HWI_SIGN_EXTEND(low) \
((((HOST_WIDE_INT) low) < 0) ? ((HOST_WIDE_INT) -1) : ((HOST_WIDE_INT) 0))
static rtx neg_const_int (enum machine_mode, rtx);
static bool plus_minus_operand_p (rtx);
static rtx neg_const_int (enum machine_mode, const_rtx);
static bool plus_minus_operand_p (const_rtx);
static bool simplify_plus_minus_op_data_cmp (rtx, rtx);
static rtx simplify_plus_minus (enum rtx_code, enum machine_mode, rtx, rtx);
static rtx simplify_immed_subreg (enum machine_mode, rtx, enum machine_mode,
......@@ -67,7 +67,7 @@ static rtx simplify_binary_operation_1 (enum rtx_code, enum machine_mode,
/* Negate a CONST_INT rtx, truncating (because a conversion from a
maximally negative number can overflow). */
static rtx
neg_const_int (enum machine_mode mode, rtx i)
neg_const_int (enum machine_mode mode, const_rtx i)
{
return gen_int_mode (- INTVAL (i), mode);
}
......@@ -76,7 +76,7 @@ neg_const_int (enum machine_mode mode, rtx i)
the most significant bit of machine mode MODE. */
bool
mode_signbit_p (enum machine_mode mode, rtx x)
mode_signbit_p (enum machine_mode mode, const_rtx x)
{
unsigned HOST_WIDE_INT val;
unsigned int width;
......@@ -255,7 +255,7 @@ simplify_gen_relational (enum rtx_code code, enum machine_mode mode,
resulting RTX. Return a new RTX which is as simplified as possible. */
rtx
simplify_replace_rtx (rtx x, rtx old_rtx, rtx new_rtx)
simplify_replace_rtx (rtx x, const_rtx old_rtx, rtx new_rtx)
{
enum rtx_code code = GET_CODE (x);
enum machine_mode mode = GET_MODE (x);
......@@ -3601,7 +3601,7 @@ simplify_plus_minus (enum rtx_code code, enum machine_mode mode, rtx op0,
/* Check whether an operand is suitable for calling simplify_plus_minus. */
static bool
plus_minus_operand_p (rtx x)
plus_minus_operand_p (const_rtx x)
{
return GET_CODE (x) == PLUS
|| GET_CODE (x) == MINUS
......
......@@ -31,9 +31,9 @@ extern int toplev_main (unsigned int, const char **);
extern int read_integral_parameter (const char *, const char *, const int);
extern void strip_off_ending (char *, int);
extern const char *trim_filename (const char *);
extern void _fatal_insn_not_found (rtx, const char *, int, const char *)
extern void _fatal_insn_not_found (const_rtx, const char *, int, const char *)
ATTRIBUTE_NORETURN;
extern void _fatal_insn (const char *, rtx, const char *, int, const char *)
extern void _fatal_insn (const char *, const_rtx, const char *, int, const char *)
ATTRIBUTE_NORETURN;
#define fatal_insn(msgid, insn) \
......@@ -76,8 +76,8 @@ extern bool enable_rtl_dump_file (int);
extern void announce_function (tree);
extern void error_for_asm (rtx, const char *, ...) ATTRIBUTE_GCC_DIAG(2,3);
extern void warning_for_asm (rtx, const char *, ...) ATTRIBUTE_GCC_DIAG(2,3);
extern void error_for_asm (const_rtx, const char *, ...) ATTRIBUTE_GCC_DIAG(2,3);
extern void warning_for_asm (const_rtx, const char *, ...) ATTRIBUTE_GCC_DIAG(2,3);
extern void warn_deprecated_use (tree);
#ifdef BUFSIZ
......
......@@ -4647,7 +4647,7 @@ extern tree gimplify_parameters (void);
/* In print-rtl.c */
#ifdef BUFSIZ
extern void print_rtl (FILE *, rtx);
extern void print_rtl (FILE *, const_rtx);
#endif
/* In print-tree.c */
......
......@@ -3603,7 +3603,7 @@ get_pool_constant_mark (rtx addr, bool *pmarked)
/* Similar, return the mode. */
enum machine_mode
get_pool_mode (rtx addr)
get_pool_mode (const_rtx addr)
{
return SYMBOL_REF_CONSTANT (addr)->mode;
}
......
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