summaryrefslogtreecommitdiff
path: root/gcc/recog.c
Commit message (Collapse)AuthorAgeFilesLines
* * recog.c (push_operand, pop_operand): VOIDmode needn't match modes.rth1999-03-071-2/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@25624 138bc75d-0d04-0410-961f-82ee72b054a4
* Only call update_flow_info if instruction scheduling is enabled.nickc1999-02-051-1/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@25042 138bc75d-0d04-0410-961f-82ee72b054a4
* Bob Manson <manson@charmed.cygnus.com>rth1999-02-021-0/+81
| | | | | | | | | | | | | | | | * resource.c, resource.h: New files. * haifa-sched.c (regno_use_in): Moved to rtlanal.c. (split_block_insns): Moved to recog.c. (update_flow_info): Make public. * reorg.c: Moved the functions dealing with computing resource usage to resource.c. * sched.c (regno_use_in): Moved to rtlanal.c. (update_flow_info): Make public. (schedule_insns): Use split_block_insns. * recog.c (split_block_insns): New function. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24982 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.c (check_asm_operands): Treat indeterminate operand okrth1999-02-011-8/+24
| | | | | | | | | | results as success. Try harder to resolve a matching constraint. * stmt.c (expand_asm_operands): Recognize when an output operand's constraint does not allow memory. Treat indeterminate operand ok results as failure. Try harder to resolve a matching constraint. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24959 138bc75d-0d04-0410-961f-82ee72b054a4
* * final.c (bb_str): Qualify a char* with the keyword `const'.ghazi1999-01-231-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | (add_bb_string, final_scan_insn, output_asm_insn): Likewise. * fix-header.c (read_scan_file): Likewise. * genoutput.c (output_epilogue, process_template): Likewise. * local-alloc.c (requires_inout, block_alloc): Likewise. * output.h (output_asm_insn, assemble_string): Likewise. * recog.c (recog_constraints, check_asm_operands, decode_asm_operands, extract_insn, preprocess_constraints, constrain_operands): Likewise. * recog.h (operand_alternative, recog_constraints, insn_template, insn_outfun, insn_operand_constraint, insn_name): Likewise. * regclass.c (record_reg_classes, scan_one_insn): Likewise. * regmove.c (find_matches): Likewise. * reload.c (alternative_allows_memconst): Likewise. * reload1.c (constraint_accepts_reg_p, reload_cse_simplify_operands): Likewise. * rtl.h (decode_asm_operands): Likewise. * scan.h (fn_decl): Likewise. * varasm.c (assemble_string): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24834 138bc75d-0d04-0410-961f-82ee72b054a4
* * cse.c (fold_rtx): Revert 29 Dec change.rth1999-01-211-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cse_insn): Revert 12 Jan change. * expr.c (expand_builtin): Don't emit CONST around CONSTANT_P_RTX. * regclass.c (reg_scan_mark_refs): Revert 29 Dec change. * rtl.def: Likewise. * rtl.h (CONSTANT_P): Likewise. * expr.c (emit_move_insn): Never try to flush CONSTANT_P_RTX to memory. * recog.c (immediate_operand): Accept CONSTANT_P_RTX. * alpha.c (input_operand): Likewise. * c4x.c (const_operand): Likewise. * explow.c (allocate_dynamic_stack_space): Use register_operand instead of arith_operand, which does not exist. * 1750a.h: Fix comment closure. * a29k.c (a29k_set_memflags): Fix typo in 19 Jan change. * arc.md (one_cmplsi2_set_cc_insn): Fix set mode mismatch. * arm.h (TARGET_SWITCHES): Fix typo. * i370.md (anon mult and div patterns): Fix set mode mismatch. * i860.c (output_delayed_branch): Fix operands to constrain_operands. (output_delay_insn): Likewise. * m88k.md (anon rotate insns): Fix set mode mismatch. (anon BLKmode moves): Commonize and fix set mode mismatches. * ns32k.md (udivmoddi[shq]i4_internal): Fix mode mismatch. * romp.md (movdf): Fix typo. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24796 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.c (pop_operand): New function.rth1999-01-191-0/+33
| | | | | | | | * recog.h (pop_operand): Declare it. * genrecog.c (preds): Define it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24774 138bc75d-0d04-0410-961f-82ee72b054a4
* * rtl.h (rtx_def): Update documentation.mmitchel1999-01-191-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (MEM_IN_STRUCT_P): Likewise. (MEM_SCALAR_P): New macro. (MEM_COPY_ATTRIBUTES): Likewise. (MEM_SET_IN_STRUCT_P): Likewise. * rtl.texi (MEM_SCALAR_P): Document. * alias.c (canon_rtx): Use MEM_COPY_ATTRIBUTES. (fixed_scalar_and_varying_struct_p): New function. Use MEM_SCALAR_P rather than !MEM_IN_STRUCT_P. (aliases_everything_p): Likewise. (true_dependence): Use them. (write_dependence_p): New function, containing code common to anti_dependence and output_dependence. (anti_dependence): Use it. (output_dependence): Likewise. * calls.c (save_fixed_argument_area): Don't clear MEM_IN_STRUCT_P. (expand_call): Use MEM_SET_IN_STRUCT_P. (emit_library_call): Don't clear MEM_IN_STRUCT_P. (emit_library_call_value): Likewise. (store_one_arg): Use MEM_SET_IN_STRUCT_P. * combine.c (simplify_rtx): Use MEM_COPY_ATTRIBUTES. (make_extraction): Likewise. (simplify_shift_const): Likewise. (gen_lowpart_for_combine): Likewise. * cse.c (gen_lowpart_if_possible): Use MEM_COPY_ATTRIBUTES. * emit-rtl.c (operand_subword): Likewise. (change_address): Likewise. * explow.c (stabilize): Use MEM_COPY_ATTRIBUTES. * expr.c (protect_from_queue): Use MEM_COPY_ATTRIBUTES. (emit_group_store): Use MEM_SET_IN_STRUCT_P. (copy_blkmode_from_reg): Likewise. (store_field): Likewise. (expand_expr): Remove bogus guesswork setting MEM_IN_STRUCT_P heuristically. Use MEM_SET_IN_STRUCT_P. (get_memory_rtx): Likewise. * final.c (alter_subreg): Use MEM_COPY_ATTRIBUTES. * function.c (assign_stack_temp): Clear MEM_SCALAR_P and MEM_ALIAS_SET on newly returned MEMs. (assign_temp): Use MEM_SET_IN_STRUCT_P. (put_reg_into_stack): Likewise. (fixup_var_refs1): Use MEM_COPY_ATTRIBUTES. (gen_mem_addressof): Use MEM_SET_IN_STRUCT_P. (assign_parms): Likewise. (expand_function): Likewise. * integrate.c (expand_inline_function): Likewise. (copy_rtx_and_substitute): Use MEM_COPY_ATTRIBUTES. * loop.c (note_addr_stored): Remove check on MEM_IN_STRUCT_P. * optabs.c (gen_move_insn): Use MEM_COPY_ATTRIBUTES. * print-rtl.c (print_rtx): Print /f for frame_related. * recog.c (validate_replace_rtx_1): Use MEM_COPY_ATTRIBUTES. * reload1.c (reload): Copy MEM_SCALAR_P as well. * stmt.c (expand_decl): Use MEM_SET_IN_STRUCT_P. (expand_anon_union_decl): Use MEM_COPY_ATTRIBUTES. * varasm.c (make_decl_rtl): Use MEM_SET_IN_STRUCT_P. (output_constant_def): Likewise. * a29k.c (a29k_set_memflags_1): Take scalar_p. Set MEM_SCALAR_P. (a29k_set_memflags): Use it. * alpha.c (get_aligned_mem): Use MEM_COPY_ATTRIBUTES. * c4x.c (c4x_scan_for_ld): Likewise. * h8300.c (fix_bit_operand): Likewise. * m88k.c (legitimize_address): Likewise. (block_move_loop): Likewise. (block_move_no_loop): Likewise. (block_move_sequence): Likewise. (m88k_builtin_saveregs): Use MEM_SET_IN_STRUCT_P. * mips/abi64.h (SETUP_INCOMING_VARARGS): Likewise. * rs6000.c (expand_block_move_insn): Use MEM_COPY_ATTRIBUTES. * sh.c (sh_builtin_saveregs): Use MEM_SET_IN_STRUCT_P. * arm.h (arm_gen_load_multiple): Take scalar_p. (arm_store_load_multiple): Likewise. * arm.c (arm_gen_load_multiple): Likewise. (arm_gen_store_multiple): Likewise. (arm_gen_movstrqi): Treat MEM_SCALAR_P like MEM_IN_STRUCT_P. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24759 138bc75d-0d04-0410-961f-82ee72b054a4
* Warning fixes:ghazi1999-01-181-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | * loop.c (insert_bct): Hide the definition of variables `increment_direction', `compare_direction', `add_iteration' and `loop_var_mode'. * recog.c (mode_dependent_address_p): Mark parameter `addr' with ATTRIBUTE_UNUSED. Mark label `win' with ATTRIBUTE_UNUSED_LABEL. (mode_independent_operand): Mark label `lose' with ATTRIBUTE_UNUSED_LABEL. * regclass.c (n_occurrences): Remove prototype and definition. * reload.c (find_reloads_address_1): Mark variable `tem' with ATTRIBUTE_UNUSED. * reload1.c (reload): Cast the first two arguments of `bcopy' to PTR. * sbitmap.c (sbitmap_copy): Likewise. * scan-decls.c (scan_decls): Hide label `handle_comma'. * toplev.c (output_lang_identify): Mark prototype with ATTRIBUTE_UNUSED. * tree.c (make_node): Cast the first argument of `bzero' to PTR. (make_tree_vec): Likewise. (build1): Likewise. * varasm.c (assemble_static_space): Mark variable `tem' with ATTRIBUTE_UNUSED. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24740 138bc75d-0d04-0410-961f-82ee72b054a4
* * expr.c (queued_subexp_p): Make public.rth1999-01-151-5/+222
| | | | | | | | | | | | | * expr.h (queued_subexp_p): Declare it. * recog.c (asm_operand_ok): New function. (check_asm_operands): Use it. After reload, use constrain_operands instead. * recog.h (asm_operand_ok): Declare it. * stmt.c (expand_asm_operands): Use it to try harder to make asms initially satisfy their constraints. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24686 138bc75d-0d04-0410-961f-82ee72b054a4
* Warning fixes:ghazi1998-12-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * alias.c (record_alias_subset): Remove ignored `&'. (init_alias_once): Likewise. * c-lex.c (UNGETC): Cast first argument of comma expression to void. * config/mips/mips.c (mips_asm_file_end): Cast the result of fwrite to `int' when comparing against one. * config/mips/mips.h (CAN_ELIMINATE): Add parens around && within ||. (INITIAL_ELIMINATION_OFFSET): Add braces to avoid ambiguous `else'. * cse.c (rehash_using_reg): Change type of variable `i' to unsigned int. * dwarf2out.c (initial_return_save): Cast -1 to unsigned before assigning it to one. * except.c (duplicate_eh_handlers): Remove unused variable `tmp'. * final.c (final_scan_insn): Likewise for variable `i'. (output_asm_insn): Cast a char to unsigned char when used as an array index. * gcse.c (compute_pre_ppinout): Cast -1 to SBITMAP_ELT_TYPE when assigning it to one. * loop.c (strength_reduce): Remove unused variables `count' and `temp'. * recog.c (preprocess_constraints): Cast a char to unsigned char when used as an array index. * regmove.c (find_matches): Likewise. * reload1.c (calculate_needs): Add default case in switch. (eliminate_regs_in_insn): Initialize variable `offset'. (set_offsets_for_label): Change type of variable `i' to unsigned. (reload_as_needed): Wrap variable `i' in macro check on AUTO_INC_DEC || INSN_CLOBBERS_REGNO_P. * scan-decls.c (scan_decls): Mark parameters `argc' and `argv' with ATTRIBUTE_UNUSED. Cast variable `start_written' to size_t when comparing against one. * stor-layout.c (layout_decl): Cast maximum_field_alignment to unsigned when comparing against one. Likewise for GET_MODE_ALIGNMENT(). (layout_record): Cast record_align to int when comparing against a signed value. (layout_type): Cast TYPE_ALIGN() to int when comparing against a signed value. * tree.c (get_identifier): Cast variable `len' to unsigned when comparing against one. (maybe_get_identifier): Likewise git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24403 138bc75d-0d04-0410-961f-82ee72b054a4
* * final.c (cleanup_subreg_operands): Delete some unused code.crux1998-12-041-0/+111
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * recog.h (MAX_RECOG_ALTERNATIVES): New macro. (struct insn_alternative): New structure definition. (recog_op_alt): Declare variable. (preprocess_constraints): Declare function. * recog.c (recog_op_alt): New variable. (extract_insn): Verify number of alternatives is in range. (preprocess_constraints): New function. * reg-stack.c: Include recog.h. (constrain_asm_operands): Delete. (get_asm_operand_lengths): Delete. (get_asm_operand_n_inputs): New function. (record_asm_reg_life): Delete OPERANDS, CONSTRAINTS, N_INPUTS and N_OUTPUTS args. All callers changed. Compute number of inputs and outputs here by calling get_asm_operand_n_inputs. Instead of constrain_asm_operands, call extract_insn, constrain_operands and preprocess_constaints. Use information computed by these functions throughout. (record_reg_life): Delete code that is unused due to changes in record_asm_reg_life. (subst_asm_stack_regs): Delete OPERANDS, OPERAND_LOC, CONSTRAINTS, N_INPUTS and N_OUTPUTS args. All callers changed. Similar changes as in record_asm_reg_life. (subst_stack_regs): Move n_operands declaration into the if statement where it's used. Delete code that is unused due to changes in subst_asm_stack_regs. * stmt.c (expand_asm_operands): Verify number of alternatives is in range. * Makefile.in (reg-stack.o): Depend on recog.h. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24090 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.h (enum op_type): Define.law1998-11-041-47/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (constrain_operands): Adjust prototype. (recog_op_type): Declare new variable. * recog.c (recog_op_type): New variable. (insn_invalid_p): Allow modifying an asm statement after reload. (extract_insn): Set up recog_op_type. (constrain_operands): Lose INSN_CODE_NUM arg. All callers changed. Don't compute operand types, use recog_op_type. Use the information computed by extract_insn instead of the previous method of finding it by insn code number. * caller-save.c (init_caller_save): Use extract_insn, not insn_extract. * reorg.c (fill_slots_from_thread): Likewise. * reload1.c (reload_as_needed): Likewise. (gen_reload): Likewise. (inc_for_reload): Likewise. (reload_cse_simplify_operands): Likewise. Use the information computed by extract_insn instead of the previous method of finding it by insn code number. * genattrtab.c (write_attr_case): Generate call to extract_insn, not insn_extract. * final.c (final_scan_insn): Use extract_insn, not insn_extract. (cleanup_operand_subregs): Use extract_insn, not insn_extract. Use the information computed by extract_insn instead of the previous method of finding it by insn code number. * regmove.c (find_matches): Likewise. Change meaning of the return value to be nonzero if the optimization can be performed, zero if not. All callers changed. Shorten some variable names to fix formatting problems. (regmove_optimize): Shorten some variable names to fix formatting problems. Use the information computed by extract_insn instead of the previous method of finding it by insn code number. * regclass.c (scan_one_insn): Likewise. (record_reg_classes): Don't compute operand types, use recog_op_type. * reload.c (find_reloads): Lose CONSTRAINTS1 variable; use recog_constraints instead. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@23529 138bc75d-0d04-0410-961f-82ee72b054a4
* Warning fixes:ghazi1998-10-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (recog.o): Depend on toplev.h. (insn-emit.o): Depend on recog.h. (insn-peep.o): Depend on recog.h and insn-config.h. * combine.c (simplify_set): Remove unused variable `scratches'. * final.c (final_scan_insn): Wrap declaration of variables `vlen' and `idx' in macro conditional controlling their use. * genemit.c (main): Make the generated output file include recog.h. Don't have it declare `insn_operand_constraint', since we get it from recog.h. * genpeep.c (main): Make the generated output file include insn-config.h and recog.h. * recog.c: Include toplev.h. (extract_insn): Remove unused variable `p'. * regclass.c (fix_register): Add missing braces around initializer for `what_option'. (allocate_reg_info): Move variable `i' into the scope where it is used. Change its type to `size_t'. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@23307 138bc75d-0d04-0410-961f-82ee72b054a4
* * regclass.c (regclass): Break out some code into new functionlaw1998-10-221-10/+40
| | | | | | | | | | | | | scan_one_insn, and into regclass_init. (init_cost): New static variable, moved out of regclass. (regclass_init): Initialize it here, not in . (scan_one_insn): New static function, broken out of regclass. * recog.c (apply_change_group): Break out some code into new function insn_invalid_p. (insn_invalid_p): New static fn, broken out of apply_change_group. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@23236 138bc75d-0d04-0410-961f-82ee72b054a4
* * Makefile.in (insn-extract.o): Fix dependencies.law1998-10-171-0/+123
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * genextract.c (main): Generate includes for insn-config.h and recog.h. Delete generation of declarations which are now in recog.h. * genrecog.c (main): Delete generation of definitions which are now in recog.c. * local-alloc.c (block_alloc): Use extract_insn and the variables it sets up instead of looking up values by insn_code. * recog.c (recog_operand, recog_operand_loc, recog_dup_loc, recog_dup_num): Define here instead of generating the definition in genrecog.c. (recog_n_operands, recog_n_dups, recog_n_alternatives, recog_operand_mode, recog_constraints, recog_operand_address_p): New variables. (extract_insn): New function. * recog.h (extract_insn): Declare function. (which_alternative, recog_n_operands, recog_n_dups, recog_n_alternatives, recog_operand_mode, recog_constraints, recog_operand_address_p): Declare variables. * regclass.c (n_occurrences): New static function. * reload.c (n_occurrences): Delete function. (find_reloads): Use extract_insn. * reload.h (n_occurrences): Delete declaration. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@23147 138bc75d-0d04-0410-961f-82ee72b054a4
* Warning fixes:ghazi1998-10-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (sched.o): Depend on recog.h. * alias.c (REG_BASE_VALUE): Cast the result of REGNO() macro to (unsigned) when comparing against one. (find_base_value): Likewise. (record_base_value): Cast variable `regno' to (unsigned) when comparing against one. Cast the result of REGNO() macro to (unsigned) when comparing against one. (memrefs_conflict_p): Change type of variables `r_x' and `r_y' to unsigned. (init_alias_analysis): Add unsigned variable `ui'. Use it as loop variable where an unsigned index is needed. * caller-save.c (init_caller_save): Cast `-1' to (enum insn_code) before comparing against one. * collect2.c: Add prototypes for functions `error', `fatal' and `fatal_perror'. Make these functions take variable arguments instead of faking it with a fixed number of args. (write_c_file_stat): Cast the argument of ctype macro to (unsigned char). * combine.c (can_combine_p): Mark parameter `pred' with ATTRIBUTE_UNUSED. (find_split_point): Cast variable `src' to (unsigned HOST_WIDE_INT) when comparing against one. HOST_WIDE_INT) when comparing against one. (simplify_rtx): Cast 1 to (unsigned HOST_WIDE_INT) in shift. (simplify_logical): Likewise. (force_to_mode): Cast result of INTVAL() macro to (unsigned HOST_WIDE_INT) when comparing against one. Cast 1 to (unsigned HOST_WIDE_INT) in shift. (simplify_and_const_int): Cast result of INTVAL() macro to `unsigned HOST_WIDE_INT' when comparing against one. (merge_outer_ops): Cast variable const0 to `unsigned HOST_WIDE_INT' when comparing against the result of GET_MODE_MASK() macro. (simplify_comparison): Likewise for variable `c0'. Cast variable `const_op' to `unsigned HOST_WIDE_INT' when comparing against one. Cast `1' to `unsigned HOST_WIDE_INT' in shift. Cast the result of `GET_MODE_MASK()/2' to `HOST_WIDE_INT' when comparing against one. Cast `1' to `unsigned HOST_WIDE_INT' in shift. Cast result of INTVAL() macro to `unsigned HOST_WIDE_INT' when comparing against one. (distribute_notes): Wrap variable `cc0_setter' in macro `HAVE_cc0'. config/mips/mips.c (gen_int_relational): Cast result of INTVAL() macro to `unsigned HOST_WIDE_INT' when comparing against one. (output_block_move): Cast `sizeof' expression to (int) when comparing against one. (function_arg): Cast BITS_PER_WORD to `unsigned' when comparing against one. (save_restore_insns): Cast `base_offset' to `long' to match format specifier in fprintf. * config/mips/mips.h (Pmode): Cast the result of `Pmode' macro to `enum machine_mode'. * flow.c (life_analysis_1): Remove unused variable `insn'. * gcc.c (translate_options): Move variables `j' and `k' into the scope in which they are used. Change their types to `size_t'. (set_spec): Cast the argument of ctype macro to `unsigned char'. (read_specs): Likewise. (process_command): Cast `sizeof' to (int) when comparing against one. (do_spec_1): Cast the argument of ctype macro to `unsigned char'. (handle_braces): Cast both sides of `==' expression to `long' to ensure sign matching. (main): Cast variable `i' to `int' when comparing against one. * gcov-io.h (__fetch_long): Change type of parameter `bytes' from int to size_t. Cast variable `i' to size_t when comparing against one. * genattrtab.c (convert_set_attr_alternative): Remove unused parameter `insn_code'. All callers changed. (convert_set_attr): Likewise. * genrecog.c (add_to_sequence): Cast result of XVECLEN() macro to size_t when comparing against one. Likewise for variable `len'. * global.c (global_alloc): Cast variable `max_regno' to size_t when comparing against one. Likewise for variable `max_allocno'. * jump.c (sets_cc0_p): Mark parameter `x' with ATTRIBUTE_UNUSED. * local-alloc.c (validate_equiv_mem_from_store): Mark parameter `set' with ATTRIBUTE_UNUSED. (find_free_reg): Cast `sizeof' expression to (int) when comparing against one. * loop.c (count_loop_regs_set): Remove unused variable `dest'. (strength_reduce): Mark parameter `bct_p' with ATTRIBUTE_UNUSED. (get_condition): Cast variable `const_val' to `unsigned HOST_WIDE_INT' when comparing against one. Cast unsigned expression to HOST_WIDE_INT when comparing against one. (insert_loop_mem): Mark parameter `data' with ATTRIBUTE_UNUSED. (load_mems_and_recount_loop_regs_set): Cast variable `nregs' to `unsigned' when comparing against one. * protoize.c (is_id_char): Change type of parameter `ch' to unsigned char. (munge_compile_params): Cast argument of ctype macro to (const unsigned char). (process_aux_info_file): Cast variable `aux_info_size' to int when comparing against one. (forward_to_next_token_char): Cast argument of ctype macro to `const unsigned char'. (edit_formals_lists): Likewise. (find_rightmost_formals_list): Likewise. (add_local_decl): Likewise. (add_global_decls): Likewise. (edit_fn_definition): Likewise. (do_cleaning): Likewise. (scan_for_missed_items): Likewise. (edit_file): Cast variable `orig_size' to (int) when comparing against one. (main): Cast argument of ctype macro to `const unsigned char'. * recog.c (const_int_operand): Mark parameter `mode' with ATTRIBUTE_UNUSED. * regclass.c (record_reg_classes): Change type of variable `c' to `unsigned char'. Cast `char' array index to `unsigned char'. * reload.c (push_secondary_reload): Cast argument to REG_CLASS_FROM_LETTER() macro to `unsigned char'. * reload1.c (calculate_needs): Cast `char' array index to `unsigned char'. (set_label_offsets): Change type of variable `i' to unsigned int. Cast result of XVECLEN() macro to unsigned when comparing against one. (mark_not_eliminable): Change type of variable `i' to unsigned. (order_regs_for_reload): Likewise. Cast `max_regno' to unsigned when comparing against one. (reload_as_needed): Cast macro NUM_ELIMINABLE_REGS to (int) when comparing against one. (choose_reload_regs): Hide unused label `fail'. (reload_cse_simplify_operands): Cast `char' array index to `unsigned char'. (reload_combine_note_store): Mark parameter `set' with ATTRIBUTE_UNUSED. Cast UNITS_PER_WORD to unsigned when comparing against one. (reload_cse_move2add): Remove unused variable `src2'. * sched.c: Include recog.h. (sched_note_set): Remove unused parameter `b'. All callers changed. (split_hard_reg_notes): Likewise for parameter `orig_insn'. (blockage_range): Cast result of UNIT_BLOCKED() macro to (int) when comparing against one. * stupid.c (stupid_find_reg): Mark parameter `changes_size' with ATTRIBUTE_UNUSED. Cast `sizeof' expression to (int) when comparing against one. * unroll.c (precondition_loop_p): Remove unused parameter `loop_end'. All callers changed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@23079 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.c (alter_subreg): Delete declaration.law1998-10-021-3/+0
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@22749 138bc75d-0d04-0410-961f-82ee72b054a4
* * combine.c (make_extraction): If no mode is specified forlaw1998-09-151-2/+10
| | | | | | | | | | | | | | | an operand of insv, extv, or extzv, default it to word_mode. (simplify_comparison): Similarly. * expmed.c (store_bit_field): Similarly. (extract_bit_field): Similarly. * function.c (fixup_var_regs_1): Similarly. * recog.c (validate_replace_rtx_1): Similarly. * mips.md (extv, extzv, insv expanders): Default modes for most operands. Handle TARGET_64BIT. (movdi_uld, movdi_usd): New patterns. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@22439 138bc75d-0d04-0410-961f-82ee72b054a4
* law1998-08-221-0/+10
| | | | | | | | | | * recog.c (validate_replace_rtx_group): New function. * recog.h (validate_replace_rtx_group): Declare it. * regmove.c (optimize_reg_copy_3): If any substitution fails, then undo the entire group of substitutions. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@21909 138bc75d-0d04-0410-961f-82ee72b054a4
* * rtl.h (rtx_function): New type.law1998-08-191-21/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (for_each_rtx): New function. * rtlanal.c (for_each_rtx): Define it. * recog.c (change_t): New type. (change_objects, change_old_codes, change_locs, change_olds): Replace with ... (changes): New variable. (validate_change): Dynamically allocate room for more changes, if necessary. Uses changes array instead of change_objects, etc. (apply_change_group): Use changes array instead of change_objects, etc. * loop.c (loop_mem_info): New type. (loop_mems): New variable. (loop_mems_idx): Likewise. (looop_mems_allocated): Likewise. (scan_loop): Remove nregs parameter. (next_insn_in_loop): New function. (load_mems_and_recount_loop_regs_set): Likewise. (load_mems): Likewise. (insert_loop_mem): Likewise. (replace_loop_mem): Likewise. (replace_label): Likewise. (INSN_IN_RANGE_P): New macro. (loop_optimize): Don't pass max_reg_num() to scan_loop. (scan_loop): Remove nregs parameter, compute it after any new registers are created by load_mems. Use INSN_IN_RANGE_P and next_insn_in_loop rather than expanding them inline. Call load_mems to load memory into pseudos, if appropriate. (prescan_loop): Figure out whether or not there are jumps from the loop to targets other than the label immediately following the loop. Call insert_loop_mem to notice all the MEMs used in the loop, if it could be safe to pull MEMs into REGs for the duration of the loop. (strength_reduce): Use next_insn_in_loop. Tweak comments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@21845 138bc75d-0d04-0410-961f-82ee72b054a4
* * Global CSE and constant/copy propagation.law1998-05-201-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (OBJS): Add gcse.o (STAGESTUFF): Add *.gcse. (gcse.o): Add dependencies. (mostlyclean): Remove *.gcse and */*.gcse. * gcse.c: New file. * loop.c (loop_optimize): Move call to init_alias_analysis. * recog.c (validate_replace_src): New function. * toplev.c (gcse_dump): New global variable. (flag_gcse, gcse_time): Likewise. (compile_file): Initialize gcse_time and clean out the gcse dump file if necessary. (rest_of_compilation): Call gcse_main as requested. Dump RTL after gcse if requested. (main): Enable gcse for -O2 and above. Handle -dG. Enable gcse dumps for -da. * gcc.texi: Add gcse related internal documentation. * invoke.texi: Note new command line options for gcse. * tm.texi: Document AVOID_CCMODE_COPIES. * mips.h (AVOID_CCMODE_COPIES): Define. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@19901 138bc75d-0d04-0410-961f-82ee72b054a4
* typo typo fixes fixeslaw1998-05-061-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@19601 138bc75d-0d04-0410-961f-82ee72b054a4
* Forgot to check in last night.law1998-04-171-0/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@19257 138bc75d-0d04-0410-961f-82ee72b054a4
* Major cutover to using system.h:ghazi1998-03-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (alias.o, bitmap.o, c-aux-info.o, c-common.o, c-decl.o, c-iterate.o, c-lang.o, c-lex.o, c-pragma.o, c-typeck.o, caller-save.o, calls.o, collect2.o, combine.o, cse.o, dbxout.o, dwarf2out.o, dwarfout.o, emit-rtl.o, except.o, explow.o, expmed.o, expr.o, final.o, flow.o, function.o, getpwd.o, global.o, integrate.o, jump.o, local-alloc.o, loop.o, optabs.o, pexecute.o, prefix.o, print-rtl.o, print-tree.o, profile.o, real.o, recog.o, reg-stack.o, regclass.o, regmove.o, reload.o, reload1.o, reorg.o, rtl.o, rtlanal.o, sdbout.o, stmt.o, stor-layout.o, stupid.o, tlink.o, toplev.o, tree.o, unroll.o, varasm.o, xcoffout.o): Depend on system.h. * alias.c, bitmap.c, c-aux-info.c, c-common.c, c-decl.c, c-iterate.c, c-lang.c, c-lex.c, c-pragma.c, c-typeck.c, caller-save.c, calls.c, collect2.c, combine.c, cse.c, dbxout.c, dwarf2out.c, dwarfout.c, emit-rtl.c, except.c, explow.c, expmed.c, expr.c, final.c, flow.c, function.c, gcc.c, getpwd.c, global.c, integrate.c, jump.c, local-alloc.c, loop.c, optabs.c, pexecute.c, prefix.c, print-rtl.c, print-tree.c, profile.c, real.c, recog.c, reg-stack.c, regclass.c, regmove.c, reload.c, reload1.c, reorg.c, rtl.c, rtlanal.c, sched.c, sdbout.c, stmt.c, stor-layout.c, stupid.c, tlink.c, toplev.c, tree.c, unroll.c, varasm.c, xcoffout.c: Include system.h. Organize include ordering so that stdarg/varargs comes before other system headers. Remove spurious casts of functions assured of a prototype in system.h. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@18726 138bc75d-0d04-0410-961f-82ee72b054a4
* * varasm.c (output_constant_pool): Bring back 'done' label insidelaw1998-02-141-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | an appropriate #ifdef. * bitmap.c (bitmap_element_allocate): Wrap variable 'i' in an appropriate #ifdef. (bitmap_copy, bitmap_operation): Likewise. * combine.c (combinable_i3pat): Similarly for 'src'. * function.c (fixup_var_refs_1): Similarly for 'outerdest'. (locate_and_pad_parm): Similarly for 'reg_parm_stack_space'. * regclass.c (copy_cost): Similarly for 'secondary_class'. * reload.c (make_memloc): Simliarly for 'i'. (find_reloads_address_1): Similarly for 'link'. * reload1.c (reload): Similarly for 'previous_frame_pointer_needed'. (emit_reload_insns): Similarly for 'second_reloadreg'. * unroll.c (iteration_info): Similarly for 'v'. * caller-save.c (insert_save_restore): Remove unused variable 'i'. * calls.c (expand_call): Similarly for 'i'. (emit_library_call, emit_library_call_value): Similarly for 'mode'. * fold-const.c (strip_compund_expr): Similarly for 'type'. * function.c (fixup_var_refs_1): Similarly for 'width'. (fixup_memory_subreg): Similarly for 'saved'. (locate_and_pad_parm): Similarly for 'boundary_in_bytes.' (setjmp_protect): Similarly for 'sub'. (thread_prologue_and_epilogue_insns): Similarly for 'insn'. * loop.c (record_giv): Similarly for 'p'. (combine_givs): Similarly for 'temp_iv'. (indirect_jump_in_function_p): Similarly for 'is_indirect_jump'. * recog.c (validate_replace_rtx_1): Similarly for 'width'. * tree.c (get_set_constructor_bytes): Similarly for 'vals'. * unroll.c (unroll_loop): Similarly for 'copy'. (iteration_info): Similarly for 'b'. * varasm.c (assemble_string): Similarly for 'i'. * i386.h (LEGITIMIZE_ADDRESS): Similarly for 'orig_x'. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@17973 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.c (validate_replace_rtx_1): Only perform substitutionslaw1998-01-251-7/+12
| | | | | | | of arguments to commutative and comparison operators once. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@17482 138bc75d-0d04-0410-961f-82ee72b054a4
* * alias.c: Change all uses of gen_rtx(FOO...) to gen_rtx_FOO;rth1998-01-141-17/+34
| | | | | | | | | | | | | | | change gen_rtx(expr...) to gen_rtx_fmt_foo(expr...). * caller-save.c, calls.c, combine.c, cse.c: Likewise. * dwarf2out.c, except.c, explow.c, expmed.c, expr.c: Likewise. * final.c, flow.c, function.c, genpeep.c, haifa-sched.c: Likewise. * halfpic.c, integrate.c, jump.c, local-alloc.c, loop.c: Likewise. * profile.c, recog.c, reg-stack.c, regclass.c, regmove.c: Likewise. * reload.c, reload1.c, reorg.c, sched.c, stmt.c, stupid.c: Likewise. * unroll.c, varasm.c: Likewise. * config/alpha/alpha.c, config/alpha/alpha.md: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@17357 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands): When checking earlyclobbers, usewilson1997-06-251-2/+2
| | | | | | | operands_match_p instead of rtx_equal_p. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@14300 138bc75d-0d04-0410-961f-82ee72b054a4
* (validate_replace_rtx_1, case MINUS): New case.kenner1997-04-131-3/+16
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@13869 138bc75d-0d04-0410-961f-82ee72b054a4
* Accept a unary operator in constrain_operandsian1996-10-231-1/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@13017 138bc75d-0d04-0410-961f-82ee72b054a4
* (register_operand): Don't reject subreg of complex mode.kenner1996-09-291-1/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@12868 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands): Don't test clobbered constraints.kenner1996-09-241-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@12793 138bc75d-0d04-0410-961f-82ee72b054a4
* formatting tweaksmrs1996-07-031-3/+4
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@12390 138bc75d-0d04-0410-961f-82ee72b054a4
* * recog.c (constrain_operands, case 'V'): Don't calllaw1996-03-121-1/+6
| | | | | | | offsettable_memref_p before reload has completed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@11515 138bc75d-0d04-0410-961f-82ee72b054a4
* (register_operand): Disallow subreg of reg not allowed to change size.kenner1995-07-011-0/+11
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@10094 138bc75d-0d04-0410-961f-82ee72b054a4
* Update FSF address.kenner1995-06-151-1/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@9964 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix typos in comments.kenner1995-05-161-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@9712 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands, case 'E'): Make this work liketege1995-04-101-0/+2
| | | | | | | constraint character `F' when REAL_ARITHMETIC is defined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@9357 138bc75d-0d04-0410-961f-82ee72b054a4
* Check target endianness at run time, not compile timeian1994-11-161-13/+10
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@8470 138bc75d-0d04-0410-961f-82ee72b054a4
* Update comment.kenner1994-10-171-3/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@8283 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands): Properly handle '#' in constraint.kenner1994-03-061-2/+8
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6704 138bc75d-0d04-0410-961f-82ee72b054a4
* (indirect_operand): Verify mode of OP is correct.kenner1993-12-121-0/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6222 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands): Correctly ignore MATCH_OPERATOR operands.kenner1993-06-121-2/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4664 138bc75d-0d04-0410-961f-82ee72b054a4
* (constrain_operands, case 'r'): If STRICT, a REG isn't valid if it iskenner1993-02-261-1/+2
| | | | | | | a pseudo even if GENERAL_REGS == ALL_REGS. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3542 138bc75d-0d04-0410-961f-82ee72b054a4
* (general_operand, immediate_operand, const_double_operand): Allow CONST_INTkenner1992-10-111-4/+8
| | | | | | | | with MODE_PARTIAL_INT. (nonmemory_operand): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@2399 138bc75d-0d04-0410-961f-82ee72b054a4
* entered into RCSmycroft1992-07-061-10/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1483 138bc75d-0d04-0410-961f-82ee72b054a4
* *** empty log message ***rms1992-06-241-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1263 138bc75d-0d04-0410-961f-82ee72b054a4
* *** empty log message ***kenner1992-05-271-2/+10
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1095 138bc75d-0d04-0410-961f-82ee72b054a4
* *** empty log message ***rms1992-05-071-3/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@930 138bc75d-0d04-0410-961f-82ee72b054a4