diff options
author | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-06-26 00:25:08 +0000 |
---|---|---|
committer | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-06-26 00:25:08 +0000 |
commit | 2457c75425617823976a1142d6f88c514ca985bc (patch) | |
tree | 5cf8ceabdd8f1c5995f5d74b7dc88765e4b60528 /gcc/emit-rtl.c | |
parent | 65b198c2b551597a75b1972bf64a18e63862d565 (diff) | |
download | gcc-2457c75425617823976a1142d6f88c514ca985bc.tar.gz |
* dwarf2out.c (new_cfi, queue_reg_save, dwarf2out_begin_prologue,
dwarf2out_frame_init, new_loc_descr, new_die, lookup_decl_die,
lookup_decl_loc, add_var_loc_to_decl, compute_section_prefix,
assign_symbol_names, htab_cu_hash, htab_cu_eq, htab_cu_del,
build_abbrev_table, new_loc_list, output_comp_unit, add_arange,
add_ranges_num, add_ranges_by_labels, file_info_cmp,
file_name_acquire, output_file_names, add_const_value_attribute,
premark_used_types_helper, file_table_eq, file_table_hash,
lookup_filename, dwarf2out_var_location, dwarf2out_source_line,
dwarf2out_init, file_table_relative_p): Fix -Wc++-compat and/or
-Wcast-qual warnings.
* ebitmap.c (ebitmap_array_grow, ebitmap_array_init,
ebitmap_alloc, ebitmap_ior, ebitmap_and_compl): Likewise.
* emit-rtl.c (get_mem_attrs, get_reg_attrs, gen_rtvec,
gen_reg_rtx, start_sequence, init_emit): Likewise.
* et-forest.c (et_new_occ, et_new_tree): Likewise.
* except.c (init_eh_for_function, gen_eh_region,
remove_unreachable_regions, add_ehl_entry, duplicate_eh_regions_1,
arh_to_landing_pad, arh_to_label, add_action_record,
add_call_site, switch_to_exception_section): Likewise.
* expmed.c (synth_mult): Likewise.
* expr.c (gen_group_rtx, emit_group_load, emit_group_store,
store_expr): Likewise.
* final.c (shorten_branches, final_scan_insn, debug_queue_symbol):
Likewise.
* function.c (assign_stack_temp_for_type,
allocate_struct_function, match_asm_constraints_1): Likewise.
* gcov-io.c (gcov_allocate): Likewise.
* gcse.c (GNEW, GCNEW, GNEWVEC, GCNEWVEC, GRESIZEVEC, GNEWVAR,
GCNEWVAR, GRESIZEVAR, GOBNEW, GOBNEWVAR): New.
(gcse_main, alloc_gcse_mem, alloc_gcse_mem, alloc_reg_set_mem,
record_one_set, insert_expr_in_table, insert_set_in_table,
dump_hash_table, compute_hash_table_work, alloc_hash_table,
pre_ldst_expr_hash, pre_ldst_expr_eq, find_rtx_in_ldst,
reg_set_info, reg_clear_last_set): Fix -Wc++-compat and/or
-Wcast-qual warnings.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@137136 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r-- | gcc/emit-rtl.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c index fa2b78a4d95..899679cd296 100644 --- a/gcc/emit-rtl.c +++ b/gcc/emit-rtl.c @@ -349,7 +349,7 @@ get_mem_attrs (alias_set_type alias, tree expr, rtx offset, rtx size, memcpy (*slot, &attrs, sizeof (mem_attrs)); } - return *slot; + return (mem_attrs *) *slot; } /* Returns a hash code for X (which is a really a reg_attrs *). */ @@ -398,7 +398,7 @@ get_reg_attrs (tree decl, int offset) memcpy (*slot, &attrs, sizeof (reg_attrs)); } - return *slot; + return (reg_attrs *) *slot; } @@ -812,7 +812,7 @@ gen_rtvec (int n, ...) if (n == 0) return NULL_RTVEC; /* Don't allocate an empty rtvec... */ - vector = alloca (n * sizeof (rtx)); + vector = XALLOCAVEC (rtx, n); for (i = 0; i < n; i++) vector[i] = va_arg (p, rtx); @@ -893,12 +893,11 @@ gen_reg_rtx (enum machine_mode mode) char *new; rtx *new1; - new = xrealloc (crtl->emit.regno_pointer_align, old_size * 2); + new = XRESIZEVEC (char, crtl->emit.regno_pointer_align, old_size * 2); memset (new + old_size, 0, old_size); crtl->emit.regno_pointer_align = (unsigned char *) new; - new1 = ggc_realloc (regno_reg_rtx, - old_size * 2 * sizeof (rtx)); + new1 = GGC_RESIZEVEC (rtx, regno_reg_rtx, old_size * 2); memset (new1 + old_size, 0, old_size * sizeof (rtx)); regno_reg_rtx = new1; @@ -4741,7 +4740,7 @@ start_sequence (void) free_sequence_stack = tem->next; } else - tem = ggc_alloc (sizeof (struct sequence_stack)); + tem = GGC_NEW (struct sequence_stack); tem->next = seq_stack; tem->first = first_insn; @@ -5047,11 +5046,10 @@ init_emit (void) crtl->emit.regno_pointer_align_length = LAST_VIRTUAL_REGISTER + 101; crtl->emit.regno_pointer_align - = xcalloc (crtl->emit.regno_pointer_align_length - * sizeof (unsigned char), 1); + = XCNEWVEC (unsigned char, crtl->emit.regno_pointer_align_length); regno_reg_rtx - = ggc_alloc (crtl->emit.regno_pointer_align_length * sizeof (rtx)); + = GGC_NEWVEC (rtx, crtl->emit.regno_pointer_align_length); /* Put copies of all the hard registers into regno_reg_rtx. */ memcpy (regno_reg_rtx, |