1. 22 Jun, 2009 1 commit
    • alias.c: Use REG_P... · 481683e1
      2009-06-22  Shujing Zhao  <pearly.zhao@oracle.com>
      
      	* alias.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P, CALL_P, NOTE_P and
      	JUMP_TABLE_DATA_P predicates where applicable.
      	* auto-inc-dec.c: Ditto.
      	* builtins.c: Ditto.
      	* caller-save.c: Ditto.
      	* calls.c: Ditto.
      	* cfgcleanup.c: Ditto.
      	* cfglayout.c: Ditto.
      	* cfgrtl.c: Ditto.
      	* combine.c: Ditto.
      	* combine-stack-adj.c: Ditto.
      	* cse.c: Ditto.
      	* cselib.c: Ditto.
      	* dbxout.c: Ditto.
      	* df-scan.c: Ditto.
      	* dse.c: Ditto.
      	* dwarf2asm.c: Ditto.
      	* dwarf2out.c: Ditto.
      	* emit-rtl.c: Ditto.
      	* except.c: Ditto.
      	* explow.c: Ditto.
      	* expmed.c: Ditto.
      	* expr.c: Ditto.
      	* final.c: Ditto.
      	* function.c: Ditto.
      	* fwprop.c: Ditto.
      	* gcse.c: Ditto.
      	* genpreds.c: Ditto.
      	* genrecog.c: Ditto.
      	* ifcvt.c: Ditto.
      	* ira-costs.c: Ditto.
      	* ira-lives.c: Ditto.
      	* jump.c: Ditto.
      	* loop-iv.c: Ditto.
      	* lower-subreg.c: Ditto.
      	* modulo-sched.c: Ditto.
      	* optabs.c: Ditto.
      	* postreload.c: Ditto.
      	* print-rtl.c: Ditto.
      	* recog.c: Ditto.
      	* reginfo.c: Ditto.
      	* regmove.c: Ditto.
      	* reload1.c: Ditto.
      	* reload.c: Ditto.
      	* reorg.c: Ditto.
      	* rtlanal.c: Ditto.
      	* rtl.c: Ditto.
      	* sched-vis.c: Ditto.
      	* sdbout.c: Ditto.
      	* sel-sched-ir.c: Ditto.
      	* simplify-rtx.c: Ditto.
      	* targhooks.c: Ditto.
      	* var-tracking.c: Ditto.
      	* vmsdbgout.c: Ditto.
      
      From-SVN: r148786
      Shujing Zhao committed
  2. 19 Jun, 2009 1 commit
    • dse.c (struct store_info): Rename bitmap field to bmap. · dc491a25
      ./:	* dse.c (struct store_info): Rename bitmap field to bmap.  Change
      	all uses.
      
      	* c-decl.c (in_struct, struct_types): Remove.
      	(struct c_binding): Add in_struct field.
      	(c_binding_ptr): Define type, along with VEC.
      	(struct c_struct_parse_info): Define.
      	(struct_parse_info): New static variable.
      	(bind): Initialize in_struct field.
      	(start_struct): Remove enclosing_in_struct and
      	enclosing_struct_types parameters.  Add
      	enclosing_struct_parse_info parameter.  Change all callers.  Set
      	struct_parse_info rather than in_struct and struct_types.
      	(grokfield): If -Wc++-compat and there is a symbol binding for the
      	field name, set the in_struct flag and push it on the
      	struct_parse_info->fields vector.
      	(warn_cxx_compat_finish_struct): New static function.
      	(finish_struct): Remove enclosing_in_struct and
      	enclosing_struct_types parameters.  Add
      	enclosing_struct_parse_info parameter.  Change all callers.  Don't
      	set C_TYPE_DEFINED_IN_STRUCT here.  Call
      	warn_cxx_compat_finish_struct.  Free struct_parse_info and set to
      	parameter.  Only push on struct_types if warn_cxx_compat.
      	(finish_enum): Only push on struct_types if warn_cxx_compat.
      	(declspecs_add_type): Add loc parameter.  Change all callers.
      	Change all error calls to error_at.  Pass loc, not input_location,
      	to pedwarn calls.  Warn if -Wc++-compat and a typedef name is
      	defined in a struct.  If -Wc++-compat and parsing a struct, record
      	that a typedef name was used.
      	* c-parser.c (c_parser_declspecs): Get location to pass to
      	declspecs_add_type.
      	(c_parser_struct_or_union_specifier): Update calls to start_struct
      	and finish_struct.
      	* c-tree.h (struct c_struct_parse_info): Declare.
      	(finish_struct, start_struct): Update declarations.
      	(declspecs_add_type): Update declaration.
      objc/:
      	* objc-act.c (objc_in_struct, objc_struct_types): Remove.
      	(objc_struct_info): New static variable.
      	(objc_start_struct): Pass &objc_struct_info, not &objc_in_struct
      	and &objc_struct_types, to start_struct.
      	(objc_finish_struct): Likewise for finish_struct.
      objcp/:
      	* objcp-decl.h (start_struct): Remove in_struct and struct_types
      	parameters.  Add struct_info parameter.
      	(finish_struct): Likewise.
      testsuite/:
      	* gcc.dg/Wcxx-compat-15.c: New testcase.
      
      From-SVN: r148709
      Ian Lance Taylor committed
  3. 13 May, 2009 1 commit
  4. 24 Apr, 2009 1 commit
    • re PR rtl-optimization/39794 (Miscompile with -O2 -funroll-loops) · 6216f94e
      	PR rtl-optimization/39794
      	* alias.c (canon_true_dependence): Add x_addr argument.
      	* rtl.h (canon_true_dependence): Adjust prototype.
      	* cse.c (check_dependence): Adjust canon_true_dependence callers.
      	* cselib.c (cselib_invalidate_mem): Likewise.
      	* gcse.c (compute_transp): Likewise.
      	* dse.c (scan_reads_nospill): Likewise.
      	(record_store, check_mem_read_rtx): Likewise.  For non-const-or-frame
      	addresses pass base->val_rtx as mem_addr, for const-or-frame addresses
      	canon_base_addr of the group, plus optional offset.
      	(struct group_info): Rename canon_base_mem to
      	canon_base_addr.
      	(get_group_info): Set canon_base_addr to canon_rtx of base, not
      	canon_rtx of base_mem.
      
      	* gcc.dg/pr39794.c: New test.
      
      From-SVN: r146669
      Jakub Jelinek committed
  5. 20 Apr, 2009 1 commit
    • Fix enum conversions which are invalid in C++: · bbbbb16a
      gcc/:
      	Fix enum conversions which are invalid in C++:
      	* auto-inc-dec.c (attempt_change): Change 0 to SET in function
      	call.
      	* calls.c (store_one_arg): Change 0 to EXPAND_NORMAL in function
      	call.
      	* cse.c (hash_rtx_cb): Change 0 to VOIDmode in function call.
      	* dbgcnt.c (dbg_cnt_set_limit_by_name): Add cast to enum type.
      	* dbxout.c (dbxout_symbol): Change 0 to VOIDmode in function
      	call.
      	(dbxout_parms): Likewise.
      	* df-core.c (df_set_flags): Change changeable_flags parameter to
      	int.
      	(df_clear_flags): Likewise.
      	* df-problems.c (df_rd_bb_local_compute_process_def): Change
      	top_flag parameter to int.
      	(df_chain_create_bb_process_use): Likewise.
      	(df_chain_add_problem): Change chain_flags parameter to unsigned
      	int.  Remove cast.
      	* df-scan.c (df_ref_create): Change ref_flags parameter to int.
      	(df_ref_create_structure, df_def_record_1): Likewise.
      	(df_defs_record, df_uses_record, df_get_call_refs): Likewise.
      	(df_notes_rescan): Change 0 to VOIDmode in function call.
      	(df_get_call_refs, df_insn_refs_collect): Likewise.
      	(df_bb_regs_collect): Likewise.
      	(df_entry_block_defs_collect): Likewise.
      	(df_exit_block_uses_collect): Likewise.
      	* df.h: Update declarations.
      	* double-int.c (double_int_divmod): Add cast to enum type.
      	* dse.c (replace_inc_dec): Reverse parameters to gen_int_mode.
      	* dwarf2out.c (new_reg_loc_descr): Add casts to enum type.
      	(based_loc_descr): Likewise.
      	(loc_descriptor_from_tree_1): Change first_op and second_op to
      	enum dwarf_location_atom.  Add cast to enum type.
      	* expmed.c (init_expmed): Change 0 to SET in function call.
      	* expr.c (init_expr_target): Change 0 to VOIDmode in function
      	call.
      	(expand_expr_real_1): Change 0 to EXPAND_NORMAL in function call.
      	(do_store_flag): Likewise.
      	* fixed-value.h (struct fixed_value): Change mode to enum
      	machine_mode.
      	* function.c (assign_parms): Change 0 to VOIDmode in function
      	call.
      	* genautomata.c (insert_automaton_decl): Change 1 to INSERT in
      	function call.
      	(insert_insn_decl, insert_decl, insert_state): Likewise.
      	(automata_list_finish): Likewise.
      	* genrecog.c (process_define_predicate): Add cast to enum type.
      	* gensupport.c (init_predicate_table): Add cast to enum type.
      	* gimple.c (gimple_build_return): Change 0 to ERROR_MARK in
      	function call.
      	(gimple_build_call_1, gimple_build_label): Likewise.
      	(gimple_build_goto, gimple_build_asm_1): Likewise.
      	(gimple_build_switch_1, gimple_build_cdt): Likewise.
      	* gimple.h (GIMPLE_CHECK): Change 0 to ERROR_MARK in function
      	call.
      	(enum fallback): Rename from enum fallback_t.
      	(fallback_t): Typedef as int.
      	* gimple-low.c (lower_builtin_setjmp): Change TSI_SAME_STMT to
      	GSI_SAME_STMT in function call.
      	* ira.c (setup_class_subset_and_memory_move_costs): Add casts to
      	enum type.
      	(setup_reg_class_relations): Likewise.
      	(setup_reg_class_nregs): Change cl to int.  Add casts to enum
      	type.
      	(setup_prohibited_class_mode_regs): Add cast to enum type.
      	(setup_prohibited_mode_move_regs): Likewise.
      	* ira-costs.c (record_reg_classes): Change rclass to enum
      	reg_class.
      	(record_address_regs): Change i to enum reg_class.
      	* lists.c (alloc_EXPR_LIST): Add cast to enum type.
      	* machmode.h (GET_MODE_CLASS): Cast value to enum mode_class.
      	(GET_MODE_WIDER_MODE): Cast value to enum machine_mode.
      	(GET_MODE_2XWIDER_MODE): Likewise.
      	(GET_CLASS_NARROWEST_MODE): Likewise.
      	* omp-low.c (expand_omp_for): Add cast to enum type.
      	* optabs.c (debug_optab_libfuncs): Add casts to enum type.
      	* opts.c (enable_warning_as_error): Change kind to diagostic_t.
      	* postreload.c (reload_cse_simplify_operands): Change rclass local
      	to enum reg_class.
      	* predict.c (combine_predictions_for_insn): Change best_predictor
      	and predictor to enum br_predictor.
      	(combine_predictions_for_bb): Likewise.
      	(build_predict_expr): Change assignment to PREDICT_EXPR_OUTCOME to
      	use SET_PREDICT_EXPR_OUTCOME.
      	* real.c (real_arithmetic): Change icode to code in function
      	call.
      	* reginfo.c (init_move_cost): Add casts to enum type.
      	(init_reg_sets_1, init_fake_stack_mems): Likewise.
      	* regmove.c (regclass_compatible_p): Change class0 and class1 to
      	enum reg_class.
      	* reload.c (find_valid_class): Add casts to enum type.
      	(push_reload): Change 0 to NO_REGS in function call.
      	(find_reloads): Change this_alternative to array of enum
      	reg_class.  Remove some now-unnecessary casts.
      	(make_memloc): Change 0 to VOIDmode in function call.
      	* reload1.c (reload): Change 0 to VOIDmode in function call.
      	(eliminate_regs_1, elimination_effects): Likewise.
      	(eliminate_regs_in_insn): Likewise.
      	(emit_input_reload_insns): Add cast to enum type.
      	(delete_output_reload): Change 0 to VOIDmode in function call.
      	* reorg.c (insn_sets_resource_p): Convert include_delayed_effects
      	to enum type in function call.
      	* tree.h (PREDICT_EXPR_OUTCOME): Add cast to enum type.
      	(SET_PREDICT_EXPR_OUTCOME): Define.
      	* tree-dump.c (get_dump_file_info): Change phase parameter to
      	int.
      	(get_dump_file_name, dump_begin, dump_enabled_p): Likewise.
      	(dump_initialized_p, dump_flag_name, dump_end): Likewise.
      	(dump_function): Likewise.
      	* tree-dump.h: Update declarations.
      	* tree-pass.h: Update declarations.
      	* varasm.c (assemble_integer): Change mclass to enum mode_class.
      	* config/arm/arm.c (thumb_legitimize_reload_address): Add cast to
      	enum type.
      	(arm_rtx_costs_1): Correct parenthesization.
      	(arm_rtx_costs): Add casts to enum type.
      	(adjacent_mem_locations): Reverse arguments to const_ok_for_op.
      	(vfp_emit_fstmd): Use add_rg_note.
      	(emit_multi_reg_push, emit_sfm): Likewise.
      	(thumb_set_frame_pointer): Likewise.
      	(arm_expand_prologue): Likewise.
      	(arm_regno_class): Change return type to enum reg_class.
      	(thumb1_expand_prologue): Use add_reg_note.
      	* config/arm/arm-protos.h (arm_regno_class): Update declaration.
      	* config/arm/arm.h (INITIALIZE_TRAMPOLINE): Change 0 to LCT_NORMAL
      	in function call.
      	* config/arm/gentune.sh: Add cast to enum type.
      	* config/arm/arm-tune.md: Rebuild.
      	* config/i386/i386.c (ix86_expand_prologue): Use add_reg_note.
      	(ix86_split_fp_branch, predict_jump): Likewise.
      	(ix86_expand_multi_arg_builtin): Change sub_code from enum
      	insn_code to enum rtx_code.
      	(ix86_builtin_vectorized_function): Add cast to enum type.
      	* config/i386/i386.md (truncdfsf2): Change slot to enum
      	ix86_stack_slot.
      	(truncxf<mode>2, isinf<mode>2): Likewise.
      	* config/i386/i386-c.c (ix86_pragma_target_parse): Add cast to
      	enum type.
      	* config/ia64/ia64.c (ia64_split_tmode_move): Use add_reg_note.
      	(spill_restore_mem, do_spill, ia64_expand_prologue): Likewise.
      	(insert_bundle_state): Change 1 to INSERT in function call.
      	(ia64_add_bundle_selector_before): Likewise.
      	* config/ia64/ia64.md (cpu attr): Add cast to enum type.
      	(save_stack_nonlocal): Change 0 to LCT_NORMAL in function call.
      	(restore_stack_nonlocal): Likewise.
      	* config/mips/mips.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL in
      	function call.
      	* config/mips/mips.c (mips_binary_cost): Change 0 to SET in
      	function call.
      	(mips_rtx_costs): Likewise.
      	(mips_override_options): Add casts to enum type.
      	* config/mips/sdemtk.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL
      	in function call.
      	* config/pa/pa.c (legitimize_pic_address): Use add_reg_note.
      	(store_reg, set_reg_plus_d): Likewise.
      	(hppa_expand_prologue, hppa_profile_hook): Likewise.
      	* config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Add
      	cast to enum type.
      	(altivec_expand_vec_set_builtin): Change 0 to EXPAND_NORMAL in
      	function call.
      	(emit_unlikely_jump): Use add_reg_note.
      	(rs6000_emit_allocate_stack): Likewise.
      	(rs6000_frame_related, rs6000_emit_prologue): Likewise.
      	(output_toc): Change 1 to INSERT in function call.
      	(output_profile_hook): Change 0 to LCT_NORMAL in function call.
      	(rs6000_initialize_trampoline): Likewise.
      	(rs6000_init_dwarf_reg_sizes_extra): Change 0 to EXPAND_NORMAL in
      	function call.
      	* config/s390/s390.c (s390_rtx_costs): Add cast to enum type.
      	(s390_expand_movmem): Change 0 to OPTAB_DIRECT in function call.
      	(s390_expand_setmem, s390_expand_cmpmem): Likewise.
      	(save_gprs): Use add_reg_note.
      	(s390_emit_prologue): Likewise.
      	(s390_expand_builtin): Change 0 to EXPAND_NORMAL in function
      	call.
      	* config/sparc/sparc.c (sparc_expand_prologue): Use add_reg_note.
      	(sparc_fold_builtin): Add cast to enum type.
      	* config/spu/spu.c (spu_emit_branch_or_set): Change ior_code to
      	enum insn_code.
      	(spu_expand_prologue): Use add_reg_note.
      	(expand_builtin_args): Change 0 to EXPAND_NORMAL in function
      	call.
      
      	* c-parser.c (c_parser_attributes): Change VEC back to tree list.
      	(c_parser_postfix_expression_after_primary): Get VEC for list of
      	arguments.  Get original types of arguments.  Call
      	build_function_call_vec.
      	(cached_expr_list_1, cached_expr_list_2): New static variables.
      	(c_parser_expr_list): Change return type to VEC *.  Add
      	p_orig_types parameter.  Change all callers.
      	(c_parser_release_expr): New static function.
      	(c_parser_vec_to_tree_list): New static function.
      	* c-typeck.c (build_function_call): Rewrite to build a VEC and
      	call build_function_call_vec.
      	(build_function_call_vec): New function, based on old
      	build_function_call.
      	(convert_arguments): Remove nargs and argarray parameters.  Change
      	values to a VEC.  Add origtypes parameter.
      	(build_modify_expr): Add rhs_origtype parameter.  Change all
      	callers.
      	(convert_for_assignment): Add origtype parameter.  Change all
      	callers.  If warn_cxx_compat, check for conversion to an enum
      	type when calling a function.
      	(store_init_value): Add origtype parameter.  Change all callers.
      	(digest_init): Likewise.
      	(struct init_node): Add origtype field.
      	(add_pending_init): Add origtype parameter.  Change all callers.
      	(output_init_element): Likewise.
      	(output_pending_init_elements): Pass origtype from init_node to
      	output_init_element.
      	(process_init_elemnt): Pass origtype from c_expr to
      	output_init_element.
      	(c_finish_return): Add origtype parameter.  Change all callers.
      	* c-common.c (sync_resolve_size): Change params to VEC *.  Change
      	caller.
      	(sync_resolve_params): Likewise.
      	(sync_resolve_return): Change params to first_param.  Change
      	caller.
      	(resolve_overloaded_builtins): Change params to VEC *.  Change
      	callers.   Save first parameter around call to
      	build_function_call_vec.
      	* c-decl.c (finish_decl): Add origtype parameter.  Change all
      	callers.  Call build_function_call_vec rather than
      	build_function_call for cleanup.
      	* c-tree.h: Update declarations.
      	* c-common.h: Update declarations.
      	* stub-objc.c (objc_rewrite_function_call): Change parameter from
      	params to first_param.
      	* target.h (struct gcc_target): Change resolve_overloaded_builtin
      	params parameter from tree to void *.
      	* config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
      	Change arglist parameter to have type void *, and to be a pointer
      	to a VEC.
      	* config/rs6000/rs6000-protos.h
      	(altivec_resolve_overloaded_builtin): Update declaration.
      	* config/spu/spu-c.c (spu_resolved_overloaded_builtin): Change
      	fnargs parameter to have type void *, and to be a pointer to a
      	VEC.  Call build_function_call_vec instead of
      	build_function_call.
      	* config/spu/spu-protos.h (spu_expand_builtin): Update
      	declaration.
      
      gcc/cp/:
      	* typeck.c (build_function_call_vec): New function.
      	(cp_build_function_call): Only pass first parameter to
      	objc_rewrite_function_call.
      	(build_modify_expr): Add rhs_origtype parameter.  Change all
      	callers.
      	* decl.c (finish_decl): Add origtype parameter.  Change all
      	callers.
      	* semantics.c (finish_call_expr): Pass VEC to
      	resolve_overloaded_builtin.
      
      gcc/objc:
      	* objc-act.c (objc_rewrite_function_call): Change parameter from
      	params to first_param.  Change all callers.
      
      gcc/testsuite:
      	* gcc.dg/Wcxx-compat-3.c: New testcase.
      
      From-SVN: r146451
      Ian Lance Taylor committed
  6. 18 Mar, 2009 1 commit
    • dse.c (struct group_info): Reorder fields for 64-bit hosts. · 8f5929e1
      	* dse.c (struct group_info): Reorder fields for 64-bit hosts.
      	* matrix-reorg.c (struct matrix_info): Likewise.
      	* tree-ssa-loop-ivopts.c (struct ivopts_data): Likewise.
      	* rtl.h (struct mem_attrs): Likewise.
      	* df.h (struct df): Likewise.
      	* tree-data-ref.h (struct data_dependence_relation): Likewise.
      	* ira-int.h (struct ira_allocno): Likewise.
      	* df-scan.c (struct df_collection_rec): Likewise.
      	* ira.c (struct equivalence): Likewise.
      	* function.c (struct temp_slot): Likewise.
      	* cfgloop.h (struct loop): Likewise.
      
      	* parser.c (struct cp_token): Reorder fields for 64-bit hosts.
      	(eof_token): Adjust.
      
      	* include/cpplib.h (struct cpp_dir): Reorder fields for 64-bit hosts.
      
      From-SVN: r144938
      Jakub Jelinek committed
  7. 29 Dec, 2008 1 commit
  8. 22 Dec, 2008 1 commit
    • re PR middle-end/31150 (Not promoting an whole array to be static const) · 8dd5516b
      	PR middle-end/31150
      	* dse.c (struct store_info): Add const_rhs field.
      	(clear_rhs_from_active_local_stores): Clear also const_rhs.
      	(record_store): Try also cselib_expand_value_rtx to get a constant.
      	(find_shift_sequence, get_stored_val): Use const_rhs instead of
      	rhs if worthwhile.
      	* cselib.c (cselib_record_sets): If !cselib_record_memory and
      	there is just one set from read-only MEM, look at REG_EQUAL or
      	REG_EQUIV note.
      
      	* dse.c (struct store_info): Add redundant_reason field.
      	(record_store): When storing the same constant as has been
      	stored by an earlier store, set redundant_reason field
      	to the earlier store's insn_info_t.  Don't delete cannot_delete
      	insns.
      	(find_shift_sequence): Remove read_info argument, add read_mode
      	and require_cst arguments.  Return early if require_cst and
      	constant wouldn't be returned.
      	(get_stored_val): New function.
      	(replace_read): Use it.
      	(scan_insn): Put even cannot_delete insns with exactly 1 store
      	into active_local_stores.
      	(dse_step1): Don't delete cannot_delete insns.  Remove redundant
      	constant stores if contains_cselib_groups and earlier store storing
      	the same value hasn't been eliminated.
      	(dse_step6): Renamed to dse_step7.  New function.
      	(dse_step7): Renamed from dse_step6.
      	(rest_of_handle_dse): Call dse_step6 and dse_step7 at the end.
      	* cselib.c (cselib_expand_value_rtx): Don't wrap CONST_INTs
      	into CONST unless really necessary.  Handle SUBREG, unary,
      	ternary, bitfield and compares specially, to be able to simplify
      	operations on constants.
      	(expand_loc): Try to optimize LO_SUM.
      
      	* dse.c (get_call_args): New function.
      	(scan_insn): Don't handle BUILT_IN_BZERO.  For memset, attempt
      	to get call arguments and if successful and both len and val are
      	constants, handle the call as (mem:BLK) (const_int) store.
      
      	* dse.c (struct store_info): Add is_large bool field, change
      	positions_needed into a union of a bitmask and bitmap + count.
      	(free_store_info): Free bitmap if is_large.
      	(set_usage_bits): Don't look at stores where
      	offset + width >= MAX_OFFSET.
      	(set_position_unneeded, set_all_positions_unneeded,
      	any_positions_needed_p, all_positions_needed_p): New static inline
      	functions.
      	(record_store): Handle BLKmode stores of CONST_INT, if
      	MEM_SIZE is set on the MEM.  Use the new positions_needed
      	accessor inlines.
      	(replace_read): Handle reads from BLKmode CONST_INT stores.
      	(check_mem_read_rtx): Use all_positions_needed_p function.
      	(dse_step1): Free large positions_needed bitmaps and clear is_large.
      
      	* dse.c (struct store_info): Change begin and end types to
      	HOST_WIDE_INT.
      
      	* dse.c (record_store): Fix check for unused store.
      
      	* expr.c (block_clear_fn): No longer static.
      	* expr.h (block_clear_fn): Declare.
      	* dse.c (scan_insn): Memset and bzero can just read their
      	arguments.
      
      	* gcc.c-torture/execute/20081218-1.c: New test.
      
      From-SVN: r142892
      Jakub Jelinek committed
  9. 18 Dec, 2008 1 commit
    • re PR rtl-optimization/37922 (code generation error) · 02b47899
      2008-12-18  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	PR rtl-optimization/37922
      	* dse.c (bb_info): Added regs_live field.
      	(look_for_hardregs): New function.
      	(replace_read): Added regs_live parameter and code to check that
      	shift sequence does not clobber live hardregs.
      	(check_mem_read_rtx): Added parameter to replace_read.
      	(dse_step1): Added regs_live bitmap and initialize it.
      	(rest_of_handle_dse): Added DF_NOTES problem and earlier call to
      	df_analyze.
      	* df-problems.c Renamed to 
      	df_simulate_initialize_backwards.
      	(df_simulate_one_insn): Renamed to
      	df_simulate_one_insn_backwards.
      	(df_simulate_artificial_refs_at_top): Renamed to 
      	df_simulate_finalize_backwards.
      	(df_simulate_initialized_forwards,
      	df_simulate_one_insn_forwards,
      	df_simulate_finalize_backwards): New functions.
      	* df.h (df_simulate_artificial_refs_at_end): Renamed to 
      	df_simulate_initialize_backwards.
      	(df_simulate_one_insn): Renamed to
      	df_simulate_one_insn_backwards.
      	(df_simulate_artificial_refs_at_top): Renamed to 
      	df_simulate_finalize_backwards.
      	(df_simulate_initialized_forwards,
      	df_simulate_one_insn_forwards,
      	df_simulate_finalize_backwards): New functions.
      	* ra-conflict.c (global_conflicts): Renamed
      	df_simulate_artificial_refs_at_end to
      	df_simulate_initialize_backwards.
      	* sel-sched.c (propagate_lv_set): Renamed df_simulate_one_insn to
      	df_simulate_one_insn_backwards.
      	* ifcvt.c (dead_or_predicable): Renamed
      	df_simulate_artificial_refs_at_end to
      	df_simulate_initialize_backwards. Renamed df_simulate_one_insn to
      	df_simulate_one_insn_backwards.
      	* recog.c (peephole2_optimize): Ditto.
      	* rtl-factoring (collect_pattern_seqs, clear_regs_live_in_seq): Ditto.
      
      2008-12-18  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	PR rtl-optimization/37922
      	* g++.dg/torture/pr37922.C: New test.
      
      From-SVN: r142809
      Kenneth Zadeck committed
  10. 24 Nov, 2008 1 commit
  11. 11 Sep, 2008 1 commit
  12. 31 Aug, 2008 1 commit
    • fwprop.c (should_replace_address): Add speed attribute. · f40751dd
      	* fwprop.c (should_replace_address): Add speed attribute.
      	(PR_OPTIMIZE_FOR_SPEED): New flag.
      	(propagate_rtx_1): Use it.
      	(propagate_rtx): Set it.
      	(try_fwprop_subst): Update call of rtx_costs.
      	(forward_propagate_and_simplify): LIkewise.
      	* hooks.c (hook_int_rtx_bool_0): New
      	(hook_bool_rtx_int_int_intp_false): Replace by ...
      	(hook_bool_rtx_int_int_intp_bool_false): .. thisone.
      	* hooks.h (hook_int_rtx_bool_0): New
      	(hook_bool_rtx_int_int_intp_false): Replace by ...
      	(hook_bool_rtx_int_int_intp_bool_false): .. thisone.
      	* optabs.c (avoid_expensive_constant): UPdate call of rtx_cost.
      	(prepare_cmp_insn): UPdate call of rtx_cost.
      	* postreload.c (reload_cse_simplify_set): Update call of rtx_cost.
      	(reload_cse_simplify_operands): Update call of rtx_cost.
      	(reload_cse_move2add): call of rtx_cost.
      	* target.h (struct gcc_target): Update rtx_costs and address_costs.
      	* rtlanal.c (rtx_cost): Add speed argument.
      	(address_cost): Add speed argument
      	(default_address_cost): Likewise.
      	(insn_rtx_cost): Likewise.
      	* cfgloopanal.c (seq_cost): Add speed argument.
      	(target_reg_cost, target_spill_cost): Turn to array.
      	(init_set_costs): Update for speed.
      	(estimate_reg_pressure_cost): Add speed argument.
      	* auto-inc-dec.c (attempt_change): Update call of rtx_cost.
      	* dojump.c (prefer_and_bit_test): UPdate call of rtx_cost.
      	* tree-ssa-loop-ivopts.c (struct ivopts_data): New field speed.
      	(seq_cost): Add speed argument.
      	(computation_cost): Add speed arugment.
      	(add_cost, multiply_by_const, get_address_cost): add speed argument.
      	(force_expr_to_var_cost): Update for profile info.
      	(force_var_cost): Likewise.
      	(split_address_cost): Likewise.
      	(ptr_difference_cost): Likewise.
      	(difference_cost): Likewise.
      	(get_computation_cost_at): Likewise.
      	(determine_iv_cost): Likewise.
      	(ivopts_global_cost_for_size): Likewise.
      	(rewrite_use_address): Likewise.
      	(tree_ssa_iv_optimize_loop): Initialize speed field.
      	* cse.c (optimize_this_for_speed_p): New static var.
      	(notreg_cost): Update call of rtx_cost.
      	(cse_extended_basic_block): set optimize_this_for_speed_p.
      	* ifcvt.c (cheap_bb_rtx_cost_p): Update call of rtx_cost.
      	(noce_try_cmove_arith): Likewise.
      	(noce_try_sign_mask): LIkewise.
      	* expr.c (compress_float_constant): Update rtx_cost calls.
      	* tree-ssa-address.c (most_expensive_mult_to_index): Add speed argument.
      	(addr_to_parts): Likewise.
      	(create_mem_ref): Likewise.
      	* dse.c (find_shift_sequence): Add speed argument.
      	(replace_read): Update call.
      	* calls.c (precompute_register_parameters): Update call of rtx_cost.
      	* expmed.c (sdiv_pow2_cheap, smod_pow2_cheap, zero_cost, add_cost,
      	* neg_cost, shift_cost, shiftadd_cost,
      	shiftsub_cost, mul_cost, sdiv_cost, udiv_cost ,mul_widen_cost,
      	mul_highpart_cost): Increase dimension.
      	(init_expmed): Initialize for both size and speed.
      	(expand_shift): Use profile.
      	(synth_mult): Use profile.
      	(choose_mult_variant): Use profile.
      	(expand_mult): Use profile.
      	(expand_mult_highpart_optab): Use profile.
      	(expand_mult_highpart): Use profile.
      	(expand_smod_pow2): Use profile.
      	(expand_divmod): Use profile.
      	* simplify-rtx.c (simplify_binary_operation_1): Update call of rtx_cost.
      	* loop-invariant.c (create_new_invariant): Use profile.
      	(gain_for_invariant): Add speed parameter.
      	(best_gain_for_invariant): Likewise.
      	(find_invariants_to_move): Likewise.
      	(move_single_loop_invariants): Set it.
      	* target-def.h (TARGET_RTX_COSTS): Use hook.
      	* rtl.h (rtx_cost, address_cost, insn_rtx_cost): Update prototpe.
      	(optimize_insn_for_size_p, optimize_insn_for_speed_p): Declare.
      	* output.h (default_address_cost): Update prototype.
      	* combine.c (optimize_this_for_speed_p): New static var.
      	(combine_validate_cost): Update call of rtx_cost.
      	(combine_instructions): Set optimize_this_for_speed_p.
      	(expand_compound_operation): Update call of rtx_cost.
      	(make_extraction):Update call of rtx_cost.
      	(force_to_mode):Update call of rtx_cost.
      	(distribute_and_simplify_rtx):Update call of rtx_cost.
      	* cfgloop.h (target_reg_cost, target_spill_cost): Turn to array.
      	(estimate_reg_pressure_cost): Update prototype.
      	* tree-flow.h (multiply_by_cost, create_mem_ref): Update prototype.
      	* basic-block.h (optimize_insn_for_size_p, optimize_insn_for_speed_p):
      	Remove.
      	* config/alpha/alpha.c (alpha_rtx_costs): Update.
      	(alpha_rtx_costs): Update.
      	* config/frv/frv.c (frv_rtx_costs): Update.
      	* config/s390/s390.c (s390_rtx_costs): Update.
      	* config/m32c/m32c.c (m32c_memory_move_cost): Update.
      	(m32c_rtx_costs): Update.
      	* config/spu/spu.c (TARGET_ADDRESS_COST): Upate.
      	(spu_rtx_costs): Update.
      	* config/sparc/sparc.c (sparc_rtx_costs): Update.
      	* config/m32r/m32r.c (m32r_rtx_costs): Update.
      	* config/i386/i386.c (:ix86_address_cost): Update.
      	(ix86_rtx_costs): Update.
      	* config/sh/sh.c (sh_rtx_costs, sh_address_cost): Update.
      	* config/pdp11/pdp11.c (pdp11_rtx_costs): Update.
      	* config/avr/avr.c (avr_rtx_costs, avr_address_cost): Update.
      	* config/crx/crx.c (crx_address_cost): Update.
      	* config/xtensa/xtensa.c (xtensa_rtx_costs): Update.
      	* config/stormy16/stormy16.c
      	(xstormy16_address_cost, xstormy16_rtx_costs): Update.
      	* config/m68hc11/m68hc11.c
      	(m68hc11_address_cost, m68hc11_rtx_costs): Update.
      	* config/cris/cris.c (cris_rtx_costs, cris_address_cost): Update.
      	* config/iq2000/iq2000.c (iq2000_rtx_costs, iq2000_address_cost): Update.
      	* config/mn10300/mn10300.c (mn10300_address_cost, mn10300_rtx_costs): Update
      	* config/ia64/ia64.c (ia64_rtx_costs): Update.
      	* config/m68k/m68k.c (m68k_rtx_costs): Update.
      	* config/rs6000/rs6000.c (rs6000_rtx_costs): Update.
      	* config/arc/arc.c (arc_rtx_costs, arc_address_cost): Update.
      	* config/mcore/mcore.c (TARGET_ADDRESS_COST): Update.
      	(mcore_rtx_costs): update.
      	* config/score/score3.c (score3_rtx_costs): Update.
      	* config/score/score7.c (score7_rtx_costs): Update.
      	* config/score/score3.h (score3_rtx_costs):Update.
      	* config/score/score7.h (score7_rtx_costs): Update.
      	* config/score/score.c (score_rtx_costs): Update.
      	* config/arm/arm.c (arm_address_cost): Update.
      	(arm_rtx_costs_1): Update.
      	(arm_rtx_costs_1): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_xscale_rtx_costs): Update.
      	(arm_thumb_address_cost): Update.
      	* config/pa/pa.c (hppa_address_cost): Update.
      	* config/mips/mips.c (mips_rtx_costs): Update.
      	* config/vax/vax.c (vax_address_cost): Update.
      	* config/h8300/h8300.c (h8300_shift_costs): Update.
      	(h8300_rtx_costs): Update.
      	* config/v850/v850.c (TARGET_ADDRESS_COST): Update.
      	(v850_rtx_costs): Update.
      	* config/mmix/mmix.c (mmix_rtx_costs, mmix_rtx_costs): Update.
      	* config/bfin/bfin.c
      	(bfin_address_cost): Update.
      	(bfin_rtx_costs): Update.
      	* stmt.c (lshift_cheap_p): Update.
      
      From-SVN: r139821
      Jan Hubicka committed
  13. 30 Jul, 2008 1 commit
  14. 15 Jul, 2008 1 commit
    • df-problems.c (df_set_note): Avoid C++ keywords. · 60564289
      	* df-problems.c (df_set_note): Avoid C++ keywords.
      	* df-scan.c (df_ref_change_reg_with_loc_1): Likewise.
      	* dse.c (record_store, remove_useless_values): Likewise.
      	* emit-rtl.c (gen_reg_rtx, update_reg_offset, gen_rtx_REG_offset,
      	gen_reg_rtx_offset, operand_subword, change_address_1,
      	change_address, adjust_address_1, offset_address,
      	widen_memory_access, emit_copy_of_insn_after): Likewise.
      	* explow.c (round_push, allocate_dynamic_stack_space): Likewise.
      	* fwprop.c (should_replace_address, propagate_rtx_1,
      	propagate_rtx, try_fwprop_subst, forward_propagate_and_simplify):
      	Likewise.
      	* gcse.c (cprop_jump, find_implicit_sets, bypass_block,
      	gcse_emit_move_after, update_ld_motion_stores): Likewise.
      	* lcm.c (compute_insert_delete, pre_edge_lcm,
      	compute_rev_insert_delete, pre_edge_rev_lcm): Likewise.
      	* lower-subreg.c (resolve_reg_notes): Likewise.
      	* mode-switching.c (optimize_mode_switching): Likewise.
      
      From-SVN: r137848
      Kaveh R. Ghazi committed
  15. 30 Jun, 2008 1 commit
    • df-scan.c (df_scan_free_ref_vec, [...]): New macros. · 370f38e8
      2008-06-30  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* df-scan.c (df_scan_free_ref_vec, df_scan_free_mws_vec): New
      	macros.
             	(df_scan_free_internal): Free data structures not
      	allocated in storage pools.
      	(df_mw_hardreg_chain_delete_eq_uses): Use df_scan_free_mws_vec.
      	(df_refs_add_to_chains): Use df_scan_free_ref_vec and 
      	df_scan_free_mws_vec.
      	* dse.c (dse_step6): Free offset_map_p and offset_map_n
      	unconditionally.
      
      From-SVN: r137284
      Kenneth Zadeck committed
  16. 26 Jun, 2008 1 commit
    • alias.c (record_alias_subset, [...]): Fix -Wc++-compat and/or -Wcast-qual warnings. · f883e0a7
      	* alias.c (record_alias_subset, init_alias_analysis): Fix
      	-Wc++-compat and/or -Wcast-qual warnings.
      	* attribs.c (lookup_attribute_spec): Likewise.
      	* bb-reorder.c (find_traces, rotate_loop, find_traces_1_round,
      	copy_bb, connect_traces,
      	find_rarely_executed_basic_blocks_and_cr): Likewise.
      	* bt-load.c (find_btr_def_group, add_btr_def, new_btr_user,
      	note_btr_set, migrate_btr_defs): Likewise.
      	* builtins.c (result_vector, expand_builtin_memcpy,
      	expand_builtin_mempcpy_args, expand_builtin_strncpy,
      	builtin_memset_read_str, expand_builtin_printf,
      	fold_builtin_memchr, rewrite_call_expr, fold_builtin_printf):
      	Likewise.
      	* caller-save.c (mark_set_regs): Likewise.
      	* calls.c (expand_call, emit_library_call_value_1): Likewise.
      	* cgraph.c (cgraph_edge): Likewise.
      	* combine.c (likely_spilled_retval_1): Likewise.
      	* coverage.c (htab_counts_entry_hash, htab_counts_entry_eq,
      	htab_counts_entry_del, get_coverage_counts): Likewise.
      	* cselib.c (new_elt_list, new_elt_loc_list, entry_and_rtx_equal_p,
      	new_cselib_val): Likewise.
      	* dbgcnt.c (dbg_cnt_process_opt): Likewise.
      	* dbxout.c (dbxout_init, dbxout_type, output_used_types_helper):
      	Likewise.
      	* df-core.c (df_compact_blocks): Likewise.
      	* df-problems.c (df_grow_bb_info, df_chain_create): Likewise.
      	* df-scan.c (df_grow_reg_info, df_ref_create,
      	df_insn_create_insn_record, df_insn_rescan, df_notes_rescan,
      	df_ref_compare, df_ref_create_structure, df_bb_refs_record,
      	df_record_entry_block_defs, df_record_exit_block_uses,
      	df_bb_verify): Likewise.
      	* df.h (DF_REF_EXTRACT_WIDTH_CONST, DF_REF_EXTRACT_OFFSET_CONST,
      	DF_REF_EXTRACT_MODE_CONST): New.
      	* dominance.c (get_immediate_dominator, get_dominated_by,
      	nearest_common_dominator, root_of_dom_tree,
      	iterate_fix_dominators, first_dom_son, next_dom_son): Fix
      	-Wc++-compat and/or -Wcast-qual warnings.
      	* dse.c (clear_alias_set_lookup, get_group_info, gen_rtx_MEM,
      	record_store, replace_read, check_mem_read_rtx, scan_insn,
      	dse_step1, dse_record_singleton_alias_set): Likewise.
      	* dwarf2asm.c (dw2_force_const_mem): Likewise.
      
      From-SVN: r137137
      Kaveh R. Ghazi committed
  17. 06 Jun, 2008 1 commit
    • cgraph.c: Fix typos in comments. · fa10beec
      gcc/
      	* cgraph.c: Fix typos in comments.
      	(cgraph_availability_names): Fix string typo.
      	* fold-const.c: Fix typos in comments.
      	(fold_binary): Fix typo in warning.
      	* genautomata.c: Fix typos in comments.
      	(check_presence_pattern_sets): Fix typo in local variable.
      	(output_description): Fix typo in output.
      	* ggc-zone.c (ggc_pch_finish): Fix typo in error message.
      	* hwint.h: Likewise.
      	* matrix-reorg.c (check_allocation_function): Likewise.
      	* omega.c (smooth_weird_equations): Likewise.
      	* auto-inc-dec.c: Fix typos in comments.
      	* bb-reorder.c: Likewise.
      	* builtins.c: Likewise.
      	* c-common.c: Likewise.
      	* c-cppbuiltin.c: Likewise.
      	* c-parser.c: Likewise.
      	* c-pretty-print.c: Likewise.
      	* cfgcleanup.c: Likewise.
      	* cfgexpand.c: Likewise.
      	* cfghooks.c: Likewise.
      	* cfglayout.c: Likewise.
      	* cfgloopmanip.c: Likewise.
      	* cgraphunit.c: Likewise.
      	* coverage.c: Likewise.
      	* dbxout.c: Likewise.
      	* df-byte-scan.c: Likewise.
      	* df-core.c: Likewise.
      	* df-problems.c: Likewise.
      	* df-scan.c: Likewise.
      	* dfp.c: Likewise.
      	* dominance.c: Likewise.
      	* domwalk.c: Likewise.
      	* dse.c: Likewise.
      	* dwarf2out.c: Likewise.
      	* emit-rtl.c: Likewise.
      	* et-forest.c: Likewise.
      	* function.c: Likewise.
      	* function.h: Likewise.
      	* gcc.c: Likewise.
      	* gcov-io.c: Likewise.
      	* gcov.c: Likewise.
      	* gcse.c: Likewise.
      	* genattrtab.c: Likewise.
      	* ggc-page.c: Likewise.
      	* gimplify.c: Likewise.
      	* gthr-lynx.h: Likewise.
      	* haifa-sched.c: Likewise.
      	* ipa-cp.c: Likewise.
      	* ipa-inline.c: Likewise.
      	* ipa-prop.h: Likewise.
      	* ipa-pure-const.c: Likewise.
      	* ipa-struct-reorg.c: Likewise.
      	* ipa-struct-reorg.h: Likewise.
      	* ipa-type-escape.c: Likewise.
      	* ipa.c: Likewise.
      	* loop-doloop.c: Likewise.
      	* mips-tfile.c: Likewise.
      	* mkmap-flat.awk: Likewise.
      	* mkmap-symver.awk: Likewise.
      	* modulo-sched.c: Likewise.
      	* omp-low.c: Likewise.
      	* optabs.c: Likewise.
      	* optabs.h: Likewise.
      	* opts.c: Likewise.
      	* passes.c: Likewise.
      	* postreload-gcse.c: Likewise.
      	* postreload.c: Likewise.
      	* predict.c: Likewise.
      	* pretty-print.h: Likewise.
      	* profile.c: Likewise.
      	* protoize.c: Likewise.
      	* ra-conflict.c: Likewise.
      	* real.c: Likewise.
      	* recog.c: Likewise.
      	* regclass.c: Likewise.
      	* regs.h: Likewise.
      	* reload.c: Likewise.
      	* rtl-error.c: Likewise.
      	* rtlanal.c: Likewise.
      	* scan.h: Likewise.
      	* sched-rgn.c: Likewise.
      	* see.c: Likewise.
      	* stmt.c: Likewise.
      	* target.h: Likewise.
      	* tree-dfa.c: Likewise.
      	* tree-eh.c: Likewise.
      	* tree-flow-inline.h: Likewise.
      	* tree-inline.c: Likewise.
      	* tree-into-ssa.c: Likewise.
      	* tree-loop-distribution.c: Likewise.
      	* tree-nested.c: Likewise.
      	* tree-parloops.c: Likewise.
      	* tree-pass.h: Likewise.
      	* tree-pretty-print.c: Likewise.
      	* tree-profile.c: Likewise.
      	* tree-scalar-evolution.c: Likewise.
      	* tree-sra.c: Likewise.
      	* tree-ssa-alias-warnings.c: Likewise.
      	* tree-ssa-ccp.c: Likewise.
      	* tree-ssa-coalesce.c: Likewise.
      	* tree-ssa-dom.c: Likewise.
      	* tree-ssa-dse.c: Likewise.
      	* tree-ssa-forwprop.c: Likewise.
      	* tree-ssa-live.c: Likewise.
      	* tree-ssa-live.h: Likewise.
      	* tree-ssa-loop-im.c: Likewise.
      	* tree-ssa-loop-ivopts.c: Likewise.
      	* tree-ssa-loop-niter.c: Likewise.
      	* tree-ssa-loop-prefetch.c: Likewise.
      	* tree-ssa-phiopt.c: Likewise.
      	* tree-ssa-phiprop.c: Likewise.
      	* tree-ssa-sccvn.c: Likewise.
      	* tree-ssa-ter.c: Likewise.
      	* tree-ssa-threadupdate.c: Likewise.
      	* tree-ssa.c: Likewise.
      	* tree-vect-analyze.c: Likewise.
      	* tree-vect-transform.c: Likewise.
      	* tree-vectorizer.c: Likewise.
      	* tree-vn.c: Likewise.
      	* tree-vrp.c: Likewise.
      	* tree.c: Likewise.
      	* tree.def: Likewise.
      	* tree.h: Likewise.
      	* unwind-dw2-fde.c: Likewise.
      	* unwind.inc: Likewise.
      	* value-prof.c: Likewise.
      	* vmsdbgout.c: Likewise.
      
      From-SVN: r136425
      Ralf Wildenhues committed
  18. 07 May, 2008 1 commit
    • [multiple changes] · becfd6e5
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
              PATCH rtl/7335
              PATCH rtl/33826
              * see.c (see_copy_insn): Copy new pure const attributes for new
              call.
              * c-decl.c (merge_decls): Ditto.
              * postreload.c (record_opr_changes): Change CONST_OR_PURE_CALL_P
              to RTL_CONST_OR_PURE_CALL_P.
              * tree.c (define_local_buitin): Rename DECL_IS_PURE to
              DECL_PURE_P.  Initialized DECL_LOOPING_CONST_PURE.
              (process_call_operands): Set tree_side_effects properly.
              * tree.h (TREE_READONLY_DECL_P): Removed.
              (DECL_IS_PURE): Renamed to DECL_PURE_P.
              (DECL_LOOPING_OR_CONST_P): New macro.
              (struct tree_function_decl): Added looping_const_or_pure_p.
              (ECF_*) Renumbered.
              (ECF_LOOPING_OR_CONST_P): New macro,
              * rtlanal.c (pure_const_p): Removed.
              * builtins.c (expand_builtin): Rename DECL_IS_PURE to DECL_PURE_P.
              * reorg.c (delete_prior_computation) Changed CONST_OR_PURE_CALL_P
              to RTL_CONST_CALL_P.
              * ipa-pure-const.c (pure_const_state_e): Added looping field.
              (check_decl, check_tree, check_call, scan_function): Initialize
              looping.
              (analyze_function): Rename DECL_IS_PURE to DECL_PURE_P.
              (static_execute): Set looping true for recursive functions.
              Undo setting state to IPA_NEITHER for recursive functions.
              * cse.c (cse_insn): 
              * ifcvt.c (noce_can_store_speculate_p): Changed
              CONST_OR_PURE_CALL_P and pure_call_p to RTL_CONST_CALL_P or 
              RTL_CONST_OR_PURE_CALL_P.
              * dse.c (scan_insn): Ditto.
              * local-alloc.c (validate_equiv_mem, memref_used_between_p): Ditto.
              * gcse.c (oprs_not_seen_p) Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              (store_killed_in_insn): Changed CONST_OR_PURE_CALL_P and
              pure_call_p to RTL_CONST_CALL_P.
              * gimplify.c (gimplify_call_expr): Clear side effects for
              non-looping pure and constant calls.
              * calls.c (emit_call_1): Set rtl flags from ecf flags.
              (flags_from_decl_or_type): Set ecf flags from decl flags.
              (initialize_argument_information): Turn off
              ECF_LOOPING_CONST_OR_PURE when turning off ECF_CONST.
              Change const to pure if callee_copies is true rather than just
              turning off const.
              (expand_call): Turn off ECF_LOOPING_PURE_CONST_CALL and remove old
              way of marking pure calls.
              (emit_library_call_value_1): Turn off ECF_LOOPING_PURE_CONST_CALL.
              Remove hack that was supposed to fix pr7335 and remove old
              way of marking pure calls.
              * emit-rtl.c (emit_copy_of_insn_after): Copy RTL_CONST_CALL_P,
              RTL_PURE_CALL_P, RTL_LOOPING_CONST_OR_PURE_CALL_P.
              * cselib.c (cselib_process_insn): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              * tree-ssa-pre.c (can_value_number_call): Fixed spacing.
              * loop-invariant.c (find_exits, find_invariant_bb): Changed
              CONST_OR_PURE_CALL_P to RTL_CONST_OR_PURE_CALL_P.
              * sched-deps.c (schedule_analyze): Ditto.
              * rtl.h (struct rtx_def): Use call field, unchanging field, and
              return_val field of calls to represent pure and const function
              info.
              (CONST_OR_PURE_CALL_P): Deleted macro.
              (RTL_CONST_CALL_P, RTL_PURE_CALL_P,
              RTL_LOOPING_CONST_OR_PURE_CALL_P, RTL_CONST_OR_PURE_P): New macros.
              * tree-inline.c (copy_body_r): Changed TREE_READONLY_DECL_P to
              TREE_READONLY.
              * tree-optimize.c (execute_fixup_cfg): Added test for
              ECF_LOOPING_CONST_OR_PURE.
              * c-common.c (handle_pure_attribute): Changed DECL_IS_PURE to
              DECL_PURE_P.
              * tree-cfg.c (update_call_expr_flags): Do not clear tree side
              effects for looping pure or const calls.
              (verify_gimple_expr): Added verification code. 
              * config/alpha/alpha.c (alpha_legitimize_address,
              alpha_emit_xfloating_libcall): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_CALL_P.
              * config/s390/s390.c (s390_emit_tls_call_insn): Ditto.
              * config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Ditto.
              * config/mips/mips.c (mips_call_tls_get_addr): Ditto.
              * cfgrtl.c (need_fake_edge_p): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              * dce.c (deletable_insn_p): Allow non looping, non sibling, pure
              and const calls to be deleted.
      
      java:
      2008-05-07  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* decl.c (java_init_decl_processing): Change DECL_IS_PURE to
      	DECL_PURE_P.
      
      cp:
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	 * decl.c (duplicate_decls): Merge in DECL_PURE_P, TREE_READONLY,
      	 DECL_LOOPING_CONST_OR_PURE_P attributes.
      	 * rtti.c (build_dynamic_cast_1): Rename DECL_IS_PURE to
      	 DECL_PURE_P.
      
      gfortran:
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	 * trans-decl.c (gfc_get_extern_function_decl, build_function_decl):
      	 Rename DECL_IS_PURE to DECL_PURE_P.
      
      From-SVN: r135053
      Kenneth Zadeck committed
  19. 25 Apr, 2008 1 commit
    • re PR testsuite/35843 (-fdump-rtl-expand does not exist anymore) · e3b5732b
      	PR testsuite/35843
      	* cfgexpand.c (pass_expand): Turn into RTL pass.
      	* passes.c (execute_one_pass): Do pass typechecking after execution.
      	* tree-pass.h (pass_expand): Turn into RTL pass.
      
      	* function.h (struct rtl_data): Move here fields
      	accesses_prior_frames, calls_eh_return, saves_all_registers,
      	has_nonlocal_goto, has_asm_statement, is_thunk,
      	all_throwers_are_sibcalls, limit_stack, profile, uses_const_pool,
      	uses_pic_offset_table, uses_eh_lsda, tail_call_emit,
      	arg_pointer_save_area_init from struct function; turn into bool.
      	(struct function): Move
      	calls_eh_return, saves_all_registers, has_nonlocal_goto,
      	has_asm_statement, is_thunk, all_throwers_are_sibcalls, limit_stack,
      	profile, uses_const_pool, uses_pic_offset_table, uses_eh_lsda,
      	tail_call_emit, arg_pointer_save_area_init
      	into struct rtl_data.  Remove recursive_call_emit and gimplified flags.
      	(current_function_returns_struct, current_function_returns_pcc_struct,
      	current_function_calls_setjmp, current_function_calls_alloca,
      	current_function_accesses_prior_frames,
      	current_function_calls_eh_return, current_function_is_thunk,
      	current_function_stdarg, current_function_profile,
      	current_function_limit_stack, current_function_uses_pic_offset_table,
      	current_function_uses_const_pool, current_function_has_nonlocal_label,
      	current_function_saves_all_registers,
      	current_function_has_nonlocal_goto,
      	current_function_has_asm_statement): Remove accesor macros.
      	* ra-conflict.c (global_conflicts): Update.
      	* tree-tailcall.c (suitable_for_tail_opt_p): Update.
      	(suitable_for_tail_call_opt_p): Update.
      	* builtins.c (expand_builtin_return_addr): Update.
      	(expand_builtin_setjmp_setup): Update.
      	(expand_builtin_nonlocal_goto): Update.
      	* final.c (final_start_function): Update.
      	(profile_function): Update.
      	(leaf_function_p): Update.
      	(only_leaf_regs_used): Update.
      	* df-scan.c (df_get_exit_block_use_set): Update.
      	* dojump.c (clear_pending_stack_adjust): Update.
      	* tree-stdarg.c (gate_optimize_stdarg): Update.
      	* gimple-low.c (lower_function_body): Update.
      	* global.c (compute_regsets): Update.
      	(global_alloc): Update.
      	* dwarf2out.c (dwarf2out_begin_prologue): Update.
      	* expr.c (expand_assignment): Update.
      	* dse.c (dse_step0): Update.
      	(dse_step1): Update.
      	* c-decl.c (store_parm_decls): Update.
      	* local-alloc.c (combine_regs): Update.
      	(find_free_reg): Update.
      	* function.c (assign_parms_augmented_arg_list): Update.
      	(assign_parm_find_data_types): Update.
      	(assign_parms): Update.
      	(allocate_struct_function): Update.
      	(expand_function_start): Update.
      	(expand_function_end): Update.
      	(get_arg_pointer_save_area): Update.
      	(thread_prologue_and_epilogue_insns): Update.
      	(rest_of_match_asm_constraints): Update.
      	* stor-layout.c (variable_size): Update.
      	* gcse.c (gcse_main): Update.
      	(bypass_jumps): Update.
      	* gimplify.c (gimplify_function_tree): Update.
      	* calls.c (emit_call_1): Update.
      	(expand_call): Update.
      	* bt-load.c (compute_defs_uses_and_gen): Update.
      	* except.c (sjlj_assign_call_site_values): Update.
      	(sjlj_emit_function_enter): Update.
      	(can_throw_external): Update.
      	(set_nothrow_function_flags): Update.
      	(expand_builtin_unwind_init): Update.
      	(expand_eh_return): Update.
      	(convert_to_eh_region_ranges): Update.
      	(output_function_exception_table): Update.
      	* emit-rtl.c (gen_tmp_stack_mem): Update.
      	* cfgexpand.c (expand_used_vars): Update.
      	(tree_expand_cfg): Update.
      	* cfgcleanup.c (rest_of_handle_jump): Update.
      	* explow.c (allocate_dynamic_stack_space): Update.
      	* varasm.c (assemble_start_function): Update.
      	(force_const_mem): Update.
      	(mark_constant_pool): Update.
      	* tree-optimize.c (tree_rest_of_compilation): Update.
      	* stack-ptr-mod.c (notice_stack_pointer_modification): Update.
      	* tree-cfg.c (notice_special_calls): Update.
      	(is_ctrl_altering_stmt): Update.
      	(tree_can_make_abnormal_goto): Update.
      	(tree_purge_dead_abnormal_call_edges): Update.
      	* config/alpha/predicates.md: Update.
      	* config/alpha/alpha.c (alpha_sa_mask): Update.
      	(alpha_sa_size): Update.
      	(alpha_does_function_need_gp): Update.
      	(alpha_expand_prologue): Update.
      	(alpha_start_function): Update.
      	(alpha_output_function_end_prologue): Update.
      	(alpha_expand_epilogue): Update.
      	* config/frv/frv.c (frv_stack_info): Update.
      	(frv_expand_epilogue): Update.
      	* config/s390/s390.c (s390_regs_ever_clobbered): Update.
      	(s390_register_info): Update.
      	(s390_frame_info): Update.
      	(s390_init_frame_layout): Update.
      	(s390_can_eliminate): Update.
      	(save_gprs): Update.
      	* config/spu/spu.c (spu_split_immediate): Update.
      	(need_to_save_reg): Update.
      	(spu_expand_prologue): Update.
      	(spu_expand_epilogue): Update.
      	* config/sparc/sparc.md: Update.
      	* config/sparc/sparc.c (eligible_for_return_delay): Update.
      	(sparc_tls_got): Update.
      	(legitimize_pic_address): Update.
      	(sparc_emit_call_insn): Update.
      	(sparc_expand_prologue): Update.
      	(output_return): Update.
      	(print_operand): Update.
      	(sparc_function_ok_for_sibcall): Update.
      	* config/sparc/sparc.h (EXIT_IGNORE_STACK): Update.
      	* config/m32r/m32r.md: Update.
      	* config/m32r/m32r.c (MUST_SAVE_RETURN_ADDR): Update.
      	(m32r_compute_frame_size): Update.
      	(m32r_expand_prologue): Update.
      	(m32r_expand_epilogue): Update.
      	(m32r_legitimize_pic_address): Update.
      	* config/m32r/m32r.h (FRAME_POINTER_REQUIRED): Update.
      	* config/i386/linux.h (SUBTARGET_FRAME_POINTER_REQUIRED): Update.
      	* config/i386/i386.c (ix86_frame_pointer_required): Update.
      	(gen_push): Update.
      	(ix86_save_reg): Update.
      	(ix86_compute_frame_layout): Update.
      	(ix86_expand_prologue): Update.
      	(ix86_expand_epilogue): Update.
      	* config/sh/sh.c (output_stack_adjust): Update.
      	(calc_live_regs): Update.
      	(sh5_schedule_saves): Update.
      	(sh_expand_prologue): Update.
      	(sh_expand_epilogue): Update.
      	(sh_setup_incoming_varargs): Update.
      	(sh_allocate_initial_value): Update.
      	(sh_get_pr_initial_val): Update.
      	* config/sh/sh.h (SHMEDIA_REGS_STACK_ADJUST): Update.
      	* config/sh/sh.md (label:): Update.
      	* config/avr/avr.c (out_movhi_mr_r): Update.
      	* config/crx/crx.h (enum): Update.
      	* config/xtensa/xtensa.h (along): Update.
      	* config/stormy16/stormy16.c Update.
      	(xstormy16_compute_stack_layout): Update.
      	* config/fr30/fr30.c (MUST_SAVE_RETURN_POINTER): Update.
      	(fr30_expand_prologue): Update.
      	* config/cris/cris.c (cris_conditional_register_usage): Update.
      	(cris_reg_saved_in_regsave_area): Update.
      	(cris_initial_frame_pointer_offset): Update.
      	(cris_simple_epilogue): Update.
      	(cris_expand_prologue): Update.
      	(cris_expand_epilogue): Update.
      	(cris_expand_pic_call_address): Update.
      	(cris_asm_output_symbol_ref): Update.
      	(cris_asm_output_label_ref): Update.
      	* config/cris/cris.md Update.
      	* config/iq2000/iq2000.c (compute_frame_size): Update.
      	(iq2000_expand_epilogue): Update.
      	* config/mt/mt.h (save_direction): Update.
      	* config/mn10300/mn10300.c (mn10300_function_value): Update.
      	* config/ia64/ia64.c (ia64_compute_frame_size): Update.
      	(ia64_secondary_reload_class): Update.
      	* config/m68k/m68k.c (m68k_save_reg): Update.
      	(m68k_expand_prologue): Update.
      	(m68k_expand_epilogue): Update.
      	(legitimize_pic_address): Update.
      	* config/rs6000/rs6000.c (rs6000_got_register): Update.
      	(first_reg_to_save): Update.
      	(first_altivec_reg_to_save): Update.
      	(compute_vrsave_mask): Update.
      	(compute_save_world_info): Update.
      	(rs6000_stack_info): Update.
      	(spe_func_has_64bit_regs_p): Update.
      	(rs6000_ra_ever_killed): Update.
      	(rs6000_emit_eh_reg_restore): Update.
      	(rs6000_emit_allocate_stack): Update.
      	(rs6000_emit_prologue): Update.
      	(rs6000_emit_epilogue): Update.
      	(rs6000_output_function_epilogue): Update.
      	(output_profile_hook): Update.
      	(rs6000_elf_declare_function_name): Update.
      	* config/rs6000/rs6000.h (rs6000_args): Update.
      	* config/rs6000/rs6000.md: Update.
      	* config/mcore/mcore.c (mcore_expand_prolog): Update.
      	* config/arc/arc.c (arc_output_function_epilogue): Update.
      	* config/arc/arc.h (FRAME_POINTER_REQUIRED): Update.
      	* config/darwin.c (machopic_function_base_name): Update.
      	* config/score/score3.c (score3_compute_frame_size): Update.
      	(rpush): Update.
      	(rpop): Update.
      	(score3_epilogue): Update.
      	* config/score/score7.c (score7_compute_frame_size): Update.
      	(score7_prologue): Update.
      	(score7_epilogue): Update.
      	* config/score/score.h (FRAME_POINTER_REQUIRED): Update.
      	* config/arm/linux-elf.h (SUBTARGET_FRAME_POINTER_REQUIRED): Update.
      	* config/arm/arm.c (use_return_insn): Update.
      	(require_pic_register): Update.
      	(arm_load_pic_register): Update.
      	(arm_compute_save_reg0_reg12_mask): Update.
      	(arm_compute_save_reg_mask): Update.
      	(thumb1_compute_save_reg_mask): Update.
      	(output_return_instruction): Update.
      	(arm_output_function_prologue): Update.
      	(arm_output_epilogue): Update.
      	(arm_get_frame_offsets): Update.
      	(arm_expand_prologue): Update.
      	(thumb_pushpop): Update.
      	(thumb_exit): Update.
      	(thumb1_expand_prologue): Update.
      	(thumb1_expand_epilogue): Update.
      	(arm_unwind_emit): Update.
      	(arm_output_fn_unwind): Update.
      	* config/arm/arm.h (FRAME_POINTER_REQUIRED): Update.
      	* config/arm/arm.md: Update.
      	* config/pa/pa.md: Update.
      	* config/pa/pa.c (legitimize_pic_address): Update.
      	(compute_frame_size): Update.
      	(hppa_expand_prologue): Update.
      	(hppa_expand_epilogue): Update.
      	(borx_reg_operand): Update.
      	* config/pa/pa.h (FRAME_POINTER_REQUIRED): Update.
      	(HARD_REGNO_RENAME_OK): Update.
      	* config/mips/mips.c (mips_global_pointer): Update.
      	(mips_save_reg_p): Update.
      	(mips_compute_frame_info): Update.
      	(mips_frame_pointer_required): Update.
      	(mips_expand_prologue): Update.
      	(mips_expand_epilogue): Update.
      	(mips_can_use_return_insn): Update.
      	(mips_reorg_process_insns): Update.
      	* config/v850/v850.c (compute_register_save_size): Update.
      	* config/mmix/mmix.h (FRAME_POINTER_REQUIRED): Update.
      	* config/mmix/mmix.c (along): Update.
      	(mmix_expand_epilogue): Update.
      	* config/bfin/bfin.c (legitimize_pic_address): Update.
      	(must_save_p): Update.
      	(stack_frame_needed_p): Update.
      	(add_to_reg): Update.
      	(bfin_expand_prologue): Update.
      	* stmt.c (expand_asm_operands): Update.
      	* reload1.c (reload): Update.
      	(init_elim_table): Update.
      
      From-SVN: r134682
      Jan Hubicka committed
  20. 17 Apr, 2008 1 commit
  21. 11 Apr, 2008 2 commits
  22. 07 Apr, 2008 1 commit
    • Removal of Return with Depressed Stack Pointer support · 9dd9bf80
      	Removal of Return with Depressed Stack Pointer support
      	* tree.h (TYPE_RETURNS_STACK_DEPRESSED): Delete.
      	(ECF_SP_DEPRESSED): Likewise.
      	(ECF_LIBCALL_BLOCK, ECF_NOVOPS): Adjust.
      	* calls.c (emit_call_1): Do not test ECF_SP_DEPRESSED.
      	(flags_from_decl_or_type): Do not test TYPE_RETURNS_STACK_DEPRESSED.
      	(expand_call): Do not test ECF_SP_DEPRESSED.
      	* dse.c (dse_step0): Do not test TYPE_RETURNS_STACK_DEPRESSED.
      	* function.c (keep_stack_depressed): Delete.
      	(handle_epilogue_set): Likewise.
      	(update_epilogue_consts): Likewise.
      	(emit_equiv_load): Likewise.
      	(thread_prologue_and_epilogue_insns): Remove support for Return with
      	Depressed Stack Pointer.
      	* print-tree.c (print_node): Do not test TYPE_RETURNS_STACK_DEPRESSED.
      
      ada/
      	* gigi.h (create_subprog_type): Remove returns_with_dsp parameter.
      	* decl.c (gnat_to_gnu_entity): Adjust for above new prototype.
      	* utils.c (create_subprog_type): Remove returns_with_dsp parameter.
      	* trans.c (gnat_to_gnu) <N_Return_Statement>: Remove code dealing with
      	Return by Depressed Stack Pointer.
      
      From-SVN: r133976
      Eric Botcazou committed
  23. 22 Mar, 2008 1 commit
    • re PR rtl-optimization/33927 (replace_read in dse.c could handle cases where… · 18b526e8
      re PR rtl-optimization/33927 (replace_read in dse.c could handle cases where GET_MODE_CLASS (read_mode) != GET_MODE_CLASS (store_mode) (and the size is the same))
      
      gcc/
      	PR rtl-optimization/33927
      	* Makefile.in (dse.o): Depend on $(TM_P_H).
      	* expr.h (extract_low_bits): Declare.
      	* expmed.c (extract_low_bits): New function.
      	* rtlhooks.c (gen_lowpart_general): Generalize SUBREG handling.
      	* dse.c: Include tm_p.h.
      	(find_shift_sequence): Remove the read_reg argument and return the
      	read value.  Emit the instructions instead of returning them.
      	Iterate on new_mode rather than calculating it each time.
      	Check MODES_TIEABLE_P.  Use simplify_gen_subreg to convert the
      	source to NEW_MODE and extract_low_bits to convert the shifted
      	value to READ_MODE.
      	(replace_read): Allow the load and store to have different mode
      	classes.  Use extract_low_bits when SHIFT == 0.  Create the shift
      	or extraction instructions before trying the replacement.  Update
      	dump-file code accordingly, avoiding use of REGNO (store_info->rhs).
      
      gcc/testsuite/
      	* gcc.target/mips/dse-1.c: Add checks for zeros.
      
      From-SVN: r133452
      Richard Sandiford committed
  24. 19 Mar, 2008 1 commit
    • re PR other/35094 (RTL dump file letters hosed and partly undocumented) · 8ddbbcae
      	* gcc.dg/20050811-2.c: Update dumping flags.
      	* gcc.dg/sms-2.c: Update dumping flags.
      	* gcc.dg/var-expand1.c: Update dumping flags.
      	* gcc.dg/var-expand3.c: Update dumping flags.
      	* gcc.dg/pr30957-1.c: Update dumping flags.
      	* gcc.dg/20050811-1.c: Update dumping flags.
      	* gcc.dg/cpp/cmdlne-dI-M.C: Do not xfail.
      	* gcc.dg/cpp/cmdlne-dM-M.C: Do not xfail.
      
      	PR other/35094
      	* toplev.c (decode_d_option): Handle all CPP flags.
      	* tree-vrp.c: Update tree_pass descriptors.
      	* regrename.c: Update tree_pass descriptors.
      	* fwprop.c: Update tree_pass descriptors.
      	* doc/invoke.texi: Remove documentation of dropped -d? flags.
      	* tree-into-ssa.c: Update tree_pass descriptors.
      	* tree-dump.c: Update tree_pass descriptors.
      	* tree-complex.c: Update tree_pass descriptors.
      	* tree-dump.h: Update tree_pass descriptors.
      	* see.c: Update tree_pass descriptors.
      	* cgraphbuild.c: Update tree_pass descriptors.
      	* tracer.c: Update tree_pass descriptors.
      	* tree-loop-distribution.c: Update tree_pass descriptors.
      	* cgraph.c: Update tree_pass descriptors.
      	* postreload-gcse.c: Update tree_pass descriptors.
      	* postreload.c: Update tree_pass descriptors.
      	* tree-ssa-loop-ch.c: Update tree_pass descriptors.
      	* tree-tailcall.c: Update tree_pass descriptors.
      	* tree-pass.h (tree_opt_pass): Rename to ...
      	(opt_pass) ... this one; add "type" field and remove letter field.
      	(gimple_opt_pass, rtl_opt_pass, simple_ipa_opt_pass): New.
      	(execute_pass_list, execute_ipa_pass_list, all_passes, all_ipa_passes,
      	all_lowering_passes): Update declaration.
      	* ipa-cp.c: Update tree_pass descriptors.
      	* final.c: Update tree_pass descriptors.
      	* omp-low.c: Update tree_pass descriptors.
      	* tree-ssa-dse.c: Update tree_pass descriptors.
      	* ipa-reference.c: Update tree_pass descriptors.
      	* tree-ssa-uncprop.c: Update tree_pass descriptors.
      	* auto-inc-dec.c: Update tree_pass descriptors.
      	* reorg.c: Update tree_pass descriptors.
      	* cgraphunit.c: Update tree_pass descriptors.
      	* tree-ssa-copyrename.c: Update tree_pass descriptors.
      	* tree-ssa-ccp.c: Update tree_pass descriptors.
      	* df-core.c: Update tree_pass descriptors.
      	* mode-switching.c: Update tree_pass descriptors.
      	* tree-nomudflap.c: Update tree_pass descriptors.
      	* modulo-sched.c: Update tree_pass descriptors.
      	* ipa-pure-const.c: Update tree_pass descriptors.
      	* cse.c: Update tree_pass descriptors.
      	* web.c: Update tree_pass descriptors.
      	* tree-stdarg.c: Update tree_pass descriptors.
      	* tree-ssa-math-opts.c: Update tree_pass descriptors.
      	* tree-ssa-dom.c: Update tree_pass descriptors.
      	* tree-nrv.c: Update tree_pass descriptors.
      	* tree-ssa-alias.c: Update tree_pass descriptors.
      	* loop-init.c: Update tree_pass descriptors.
      	* gimple-low.c: Update tree_pass descriptors.
      	* ipa-inline.c: Update tree_pass descriptors.
      	* tree-ssa-sink.c: Update tree_pass descriptors.
      	* global.c: Update tree_pass descriptors.
      	* ifcvt.c: Update tree_pass descriptors.
      	* jump.c: Update tree_pass descriptors.
      	* predict.c: Update tree_pass descriptors.
      	* tree-ssa-loop.c: Update tree_pass descriptors.
      	* recog.c: Update tree_pass descriptors.
      	* dse.c: Update tree_pass descriptors.
      	* tree-ssa-ifcombine.c: Update tree_pass descriptors.
      	* tree-eh.c: Update tree_pass descriptors.
      	* regmove.c: Update tree_pass descriptors.
      	* local-alloc.c
      	* function.c: Update tree_pass descriptors.
      	* tree-vectorizer.c: Update tree_pass descriptors.
      	* gcse.c: Update tree_pass descriptors.
      	* ipa-type-escape.c: Update tree_pass descriptors.
      	* tree-if-conv.c: Update tree_pass descriptors.
      	* init-regs.c: Update tree_pass descriptors.
      	* ipa.c: Update tree_pass descriptors.
      	* tree-ssa-phiopt.c: Update tree_pass descriptors.
      	* rtl-factoring.c: Update tree_pass descriptors.
      	* lower-subreg.c: Update tree_pass descriptors.
      	* bt-load.c: Update tree_pass descriptors.
      	* tree-dfa.c: Update tree_pass descriptors.
      	* except.c: Update tree_pass descriptors.
      	* emit-rtl.c: Update tree_pass descriptors.
      	* cfgexpand.c: Update tree_pass descriptors.
      	* tree-cfgcleanup.c: Update tree_pass descriptors.
      	* cfgcleanup.c: Update tree_pass descriptors.
      	* tree-ssa-pre.c: Update tree_pass descriptors.
      	* tree-sra.c: Update tree_pass descriptors.
      	* tree-mudflap.c: Update tree_pass descriptors.
      	* tree-ssa-copy.c: Update tree_pass descriptors.
      	* cfglayout.c: Update tree_pass descriptors.
      	* tree-ssa-forwprop.c: Update tree_pass descriptors.
      	* tree-ssa-dce.c: Update tree_pass descriptors.
      	* tree-ssa.c: Update tree_pass descriptors.
      	* regclass.c: Update tree_pass descriptors.
      	* integrate.c: Update tree_pass descriptors.
      	* tree-optimize.c: Update tree_pass descriptors.
      	* tree-ssa-phiprop.c: Update tree_pass descriptors.
      	* tree-object-size.c: Update tree_pass descriptors.
      	* combine.c: Update tree_pass descriptors.
      	* tree-outof-ssa.c: Update tree_pass descriptors.
      	* bb-reorder.c: Update tree_pass descriptors.
      	* stack-ptr-mod.c: Update tree_pass descriptors.
      	* var-tracking.c: Update tree_pass descriptors.
      	* tree-profile.c: Update tree_pass descriptors.
      	* tree-vect-generic.c: Update tree_pass descriptors.
      	* reg-stack.c: Update tree_pass descriptors.
      	* sched-rgn.c: Update tree_pass descriptors.
      	* tree-ssa-structalias.c: Update tree_pass descriptors.
      	* tree-cfg.c: Update tree_pass descriptors.
      	* passes.c (current_pass): Update declaration.
      	(finish_optimization_passes): Update.
      	(all_passes, all_ipa_passes, all_lowering_passes): Update declaration.
      	(register_one_dump_file, register_dump_files_1, next_pass_1):
       	Update arguments.
      	(init_optimization_passes): Update handling of new types.
      	(execute_one_pass, execute_pass_list, execute_ipa_pass_list): Update.
      	* ipa-struct-reorg.c: Update tree_pass descriptors.
      	* tree-ssa-reassoc.c: Update tree_pass descriptors.
      	* combine-stack-adj.c: Update tree_pass descriptors.
      	* cfgrtl.c: Update tree_pass descriptors.
      	* dce.c: Update tree_pass descriptors.
      	* tree-ssanames.c: Update tree_pass descriptors.
      
      From-SVN: r133342
      Jan Hubicka committed
  25. 26 Feb, 2008 1 commit
    • dbgcnt.def (cfg_cleanup, [...]): New counters. · 7d817ebc
              * dbgcnt.def (cfg_cleanup, cprop1, cprop2, dce_fast, dce_ud, dse1,
              dse2, gcse, if_conversion, if_after_combine, if_after_reload,
              jump_bypass): New counters.
              * cfgcleanup.c (cleanup_cfg): Add dbg_cnt.
              * dce.c (gate_ud_dce): Same.
              (gate_fast_dce): Same.
              * dse.c (gate_dse1): New function.
              (gate_dse2): New function.
              (gate_dse): Merge results of new gate functions.
              * gcse.c (gcse_main): Bracket cprop1 and cprop2 with dbg_cnt.
              (gate_handle_jump_bypass): Add dbg_cnt.
              (gate_handle_gcse): Add dbg_cnt.
              * ifcvt.c (gate_handle_if_conversion): Same.
              (gate_handle_if_after_combine): Same.
              (gate_handle_if_after_reload): Same.
              * Makefile.in: Add DBGCNT_H to cfgcleanup.o and ifcvt.o.
      
      From-SVN: r132684
      David Edelsohn committed
  26. 09 Nov, 2007 1 commit
  27. 15 Oct, 2007 1 commit
  28. 12 Oct, 2007 1 commit
    • dse.c (find_shift_sequence): Reinstate "<= UNITS_PER_WORD" condition. · 94a7682d
      gcc/
      	* dse.c (find_shift_sequence): Reinstate "<= UNITS_PER_WORD" condition.
      	* var-tracking.c (micro_operation_def): Update comment on u.loc.
      	(mode_for_reg_attrs, var_lowpart): New functions.
      	(add_uses): Consider recording a lowpart of LOC for MO_USE.
      	(add_stores): Likewise MO_SET and MO_COPY.  If the source of a set
      	or copy is known, set LOC to the SET that performs the set, instead
      	of the destination.
      	(find_src_status, find_src_set_src): Remove LOC parameter.
      	Replace INSN with the source value.
      	(compute_bb_dataflow, emit_notes_in_bb): Check for a SET u.loc when
      	handling MO_SET and MO_COPY.  Update the calls to find_src_status
      	and find_src_set_src.
      
      From-SVN: r129269
      Richard Sandiford committed
  29. 11 Oct, 2007 1 commit
    • re PR rtl-optimization/33638 (wrong code with -O2 -fforce-addr) · 50f0f366
      	PR rtl-optimization/33638
      	* dse.c (struct insn_info): Remove 'stack_read' field,
      	add 'stack_pointer_based' field.
      	(record_store): For a store with non-constant base, record
      	whether it is stack pointer based.
      	(scan_insn): For the call to a const function, remove stack
      	pointer based stores from the list of local active stores.
      	(scan_reads_nospill): Delete code dealing with const functions.
      
      From-SVN: r129226
      Eric Botcazou committed
  30. 04 Oct, 2007 1 commit
  31. 20 Sep, 2007 1 commit
  32. 18 Sep, 2007 1 commit
  33. 17 Sep, 2007 1 commit
  34. 16 Sep, 2007 1 commit
    • dse.c (find_shift_sequence): Allow word as well as subword shifts. · 348eea5f
      gcc/
      	* dse.c (find_shift_sequence): Allow word as well as subword shifts.
      	Do the tentative shift expansion with the DF_NO_INSN_RESCAN flag set.
      	Fix the call to insn_rtx_cost.  Skip access sizes that require a
      	real truncation of the store register.  Use convert_move instead
      	of gen_lowpart when narrowing the result.
      	(replace_read): Use convert_move instead of gen_lowpart when
      	narrowing the store rhs.
      
      gcc/testsuite/
      	* gcc.target/mips/dse-1.c: New test.
      
      From-SVN: r128530
      Richard Sandiford committed
  35. 14 Sep, 2007 1 commit
    • dse.c (find_shift_sequence): New function. · 8660aaae
      2007-09-13  Eric Christopher  <echristo@apple.com>
      	    Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* dse.c (find_shift_sequence): New function.
      	(replace_read): Add case to remove read if it requires shift.
      	* config/i386/i386.c (ix86_expand_prologue): Fixed typo in comment.
      	
      
      
      Co-Authored-By: Kenneth Zadeck <zadeck@naturalbridge.com>
      
      From-SVN: r128481
      Eric Christopher committed
  36. 05 Sep, 2007 1 commit
    • regrename.c (pass_regrename, [...]): Add RTL sharing verifier. · a36b8a1e
      	* regrename.c (pass_regrename, pass_cprop_hardreg): Add RTL sharing
      	verifier.
      	* fwprop.c (pass_rtl_fwprop, pass_rtl_fwprop_add): Likewise.
      	* see.c (pass_see): Likewise.
      	* tracer.c (pass_tracer): Likewise.
      	* postreload-gcse.c (pass_gcse2): Likewise.
      	* postreload.c (pass_postreload_cse): Likewise.
      	* mode-switching.c (pass_mode_switching): Likewise.
      	* modulo-sched.c (pass_sms): Likewise.
      	* cse.c (cse_insn): Likewise.
      	* web.c (pass_web): Likweise.
      	* combine-stack-adj.c (pass_stack_adjustments): Likewise.
      	* dce.c (pass_ud_rtl_dce, pass_fast_rtl_dce): Likewise.
      	* loop-init.c (pass_rtl_loop_init): Likewise.
      	(pass_rtl_loop_done, pass_rtl_move_loop_, pass_rtl_unswitch,
      	pass_rtl_unroll_and, pass_rtl_doloop): Likewise.
      	* global.c (pass_global_alloc): Likewise.
      	* ifcvt.c (pass_rtl_ifcvt, pass_if_after_combine,
      	pass_if_after_reload): Likewise.
      	* reload.c (pass_peephole2, pass_split_for_shoren_branches): Likewise.
      	* dse.c (pass_rtl_dse1, pass_rtl_dse2): Likewise.
      	* regmove.c (pass_regmove): Likewise.
      	* function.c (pass_thread_prologugues_epilogues): Likewise.
      	* gcse.c (pass_gcse): Likewise.
      	* rtl-factoring.c (pass_rtl_seqabstr): Likewise.
      	* lower-subreg.c (pass_lower_subreg2): Likewise.
      	* bt-load.c (pass_branch_target_load): Likewise.
      	* emit-rtl.c (pass_unshare_all_rtl): Likewise.
      	* cfgcleanup.c (pass_jump, pass_jump2): Likewise.
      	* combine.c (pass_combine): Likewise.
      	* bb-reorder.c (pass_duplicate_comp, pass_reorder_blocks): Likewise.
      	(pass_partition_blocks): Likewise.
      	* var-tracking.c (pass_variable_track): Likewise.
      	* reg-stack.c (pass_stack_regs_run): Likewise.
      	* sched-rgn.c (pass_sched, pass_sched2): Likewise.
      	* passes.c (pass_postreload): Likewise.
      	(execute_function_todo): Add TODO_verify_rtl_sharing handling code.
      	* tree-pass.h (TODO_verify_rtl_sharing): New.
      	(TODO_update_ssa, TODO_update_ssa_no_phi, TODO_update_ssa_full_phi,
      	TODO_update_ssa_only_virtuals, TODO_remove_unused_locals,
      	TODO_set_props, TODO_df_finish, TODO_df_verify,
      	TODO_mark_first_instance, TODO_rebuild_alias): Renumber.
      
      From-SVN: r128126
      Jan Hubicka committed
  37. 11 Aug, 2007 1 commit
    • alias.h (alias_set_type): Define new type. · 4862826d
      ./:	* alias.h (alias_set_type): Define new type.
      	(ALIAS_SET_MEMORY_BARRIER): Use it.
      	* rtl.h: Include alias.h.
      	(struct mem_attrs): Use alias_set_type.
      	* tree.h: Include alias.h
      	(struct tree_type): Use alias_set_type.
      	(struct tree_struct_field_tag): Likewise.
      	(struct tree_decl_common): Likewise.
      	* alias.c (struct alias_set_entry): Use alias_set_type.
      	(get_alias_set_entry, alias_set_subset_of): Likewise.
      	(alias_sets_conflict_p): Likewise.
      	(alias_sets_must_conflict_p): Likewise.
      	(objects_must_conflict_p): Likewise.
      	(get_alias_set, new_alias_set): Likewise.
      	(record_alias_subset, record_component_aliases): Likewise.
      	(varargs_set, frame_set): Change to alias_set_type.
      	(get_varargs_alias_set): Use alias_set_type.
      	(get_frame_alias_set): Likewise.
      	* builtins.c (setjmp_alias_set): Change to alias_set_type.
      	* dse.c (struct store_info): Use alias_set_type.
      	(struct read_info, struct clear_alias_mode_holder): Likewise.
      	(clear_alias_set_lookup, canon_address): Likewise.
      	(record_store, check_mem_read_rtx): Likewise.
      	(dse_record_singleton_alias_set): Likewise.
      	(dse_invalidate_singleton_alias_set): Likewise.
      	* emit-rtl.c (get_mem_attrs): Likewise.
      	(set_mem_attributes_minus_bitpos): Likewise.
      	(set_mem_alias_set): Likewise.
      	* expr.c (store_constructor_field, store_field): Likewise.
      	* gimplify.c (struct gimplify_init_ctor_preeval_data): Likewise.
      	* langhooks.c (lhd_get_alias_set): Likewise.
      	* langhooks-def.h (lhd_get_alias_set): Likewise.
      	* reload1.c (alter_reg): Likewise.
      	* tree-flow.h (struct fieldoff): Likewise.
      	* tree-ssa-alias.c (struct alias_map_d): Likewise.
      	(may_alias_p, get_smt_for, create_sft): Likewise.
      	* tree-ssa-alias-warnings.c (nonstandard_alias_types_p): Likewise.
      	* tree-ssa-structalias.c (set_uids_in_ptset): Likewise.
      	(merge_smts_into): Likewise.
      	* varasm.c (const_alias_set): Likewise.
      	* c-common.c (strict_aliasing_warning): Likewise.
      	(c_common_get_alias_set): Likewise.
      	* dse.h (dse_record_singleton_alias_set): Update declaration.
      	(dse_invalidate_singleton_alias_set): Likewise.
      	* emit-rtl.h (set_mem_alias_set): Likewise.
      	* c-common.h (c_common_get_alias_set): Likewise.
      	* print-rtl.c (print_rtx): Cast MEM_ALIAS_SET when printing it.
      	* print-tree.c (print_node): Likewise.
      	* config/alpha/alpha.c (alpha_sr_alias_set): Change to
      	alias_set_type.
      	(alpha_setup_incoming_varargs): Use alias_set_type.
      	* config/i386/i386.c (setup_incoming_varargs_64): Use
      	alias_set_type.
      	(setup_incoming_varargs_ms_64): Likewise.
      	(ix86_GOT_alias_set): Likewise.
      	* config/mn10300/mn10300.c (mn10300_builtin_saveregs): Likewise.
      	* config/rs6000/rs6000.c (setup_incoming_varargs): Likewise.
      	(set): Change to alias_set_type.
      	(get_TOC_alias_set): Use alias_set_type.
      	* config/rs6000/rs6000-protos.h (get_TOC_alias_set): Update
      	declaration.
      	* config/sh/sh.c (sh_builtin_saveregs): Use alias_set_type.
      	* config/sparc/sparc.c (sparc_sr_alias_set): Change to
      	alias_set_type.
      	(struct_value_alias_set): Likewise.
      	* Makefile.in (GTFILES): Add $(srcdir)/alias.h.
      ada/:
      	* misc.c (gnat_get_alias_set): Change return type to
      	alias_set_type.
      cp/:
      	* cp-objcp-common.c (cxx_get_alias_set): Change return type to
      	alias_set_type.
      	* cp/cp-tree.h (cxx_get_alias_set): Update declaration.
      fortran:/
      	* f95-lang.c (gfc_get_alias_set): Change return type to
      	alias_set_type.
      
      From-SVN: r127362
      Ian Lance Taylor committed
  38. 26 Jul, 2007 1 commit
  39. 25 Jul, 2007 1 commit
    • c-lex.c (c_lex_with_flags, lex_string): Constify. · 5f754896
      	* 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.
      	* cfg.c (bb_copy_original_hash, bb_copy_original_eq): Likewise.
      	* cfgloop.c (loop_exit_hash, loop_exit_eq): Likewise.
      	* ddg.c (compare_sccs): Likewise.
      	* df-scan.c (df_ref_compare, df_mw_compare): Likewise.
      	* dfp.c (decimal_real_from_string, decimal_to_decnumber,
      	decimal_to_binary, decimal_do_compare, decimal_real_to_decimal,
      	decimal_do_fix_trunc, decimal_real_to_integer,
      	decimal_real_to_integer2, decimal_real_maxval): Likewise.
      	* dse.c (const_group_info_t): New.
      	(invariant_group_base_eq, invariant_group_base_hash): Constify.
      	* dwarf2out.c (const_dw_die_ref): New.
      	(decl_die_table_hash, decl_die_table_eq, file_info_cmp): Constify.
      	* tree-browser.c (TB_parent_eq): Likewise.
      	* unwind-dw2-fde.c (__register_frame_info_bases,
      	__deregister_frame_info_bases, fde_unencoded_compare, fde_split,
      	add_fdes, linear_search_fdes, binary_search_unencoded_fdes):
      	Likewise.
      	* unwind-dw2-fde.h (get_cie, next_fde): Likewise.
      	* unwind-dw2.c (uw_frame_state_for): Likewise.
      	* value-prof.c (histogram_hash, histogram_eq): Likewise.
      	* value-prof.h (const_histogram_value): New.
      
      From-SVN: r126920
      Kaveh R. Ghazi committed