summaryrefslogtreecommitdiff
path: root/gcc/cse.c
Commit message (Collapse)AuthorAgeFilesLines
* alias.c: Change all uses of gen_rtx(FOO...) to gen_rtx_FOO...Richard Henderson1998-01-141-40/+41
| | | | | | | | | | | | | | | * alias.c: Change all uses of gen_rtx(FOO...) to gen_rtx_FOO; 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. From-SVN: r17357
* Bring in final gcc-2.8.0 changes.Jeff Law1998-01-141-1/+1
| | | | From-SVN: r17355
* * cse.c (rtx_cost): Remove conflicting default case.Jeffrey A Law1997-12-271-3/+0
| | | | From-SVN: r17245
* cse.c (max_insn_uid): New variable.Jim Wilson1997-12-241-1/+14
| | | | | | | | | * cse.c (max_insn_uid): New variable. (invalidate): Remove CYGNUS LOCAL patch. (cse_around_loop): Use max_insn_uid. (cse_main): Set max_insn_uid. From-SVN: r17231
* cse.c (rtx_cost): Add default case in enumeration switch.Kaveh R. Ghazi1997-12-221-0/+3
| | | | | | | | | | | | * cse.c (rtx_cost): Add default case in enumeration switch. * fix-header.c (recognized_macro): Likewise. (recognized_extern): Likewise. (write_rbrac): Likewise. * objc/objc-act.c (encode_aggregate): Likewise. (gen_declarator): Likewise. (gen_declspecs): Likewise. From-SVN: r17186
* Merge from gcc-2.8Jeff Law1997-12-061-2/+11
| | | | From-SVN: r16987
* m68k.c: Include tree.h for dwarf2out_cfi_label.Jeff Law1997-12-061-0/+5
| | | | | | | | | | | | | | | | * m68k.c: Include tree.h for dwarf2out_cfi_label. * gcc.c (process_command): Do not take address of function fatal when calling lang_specific_driver. * config/i386/cygwin32.h (DWARF2_UNWIND): Exception handling doesn't work with it yet, so set it to 0. * config/i386/xm-cygwin32.h (NO_SYS_SIGLIST): Define. * cse.c (cse_insn): Check for invalid entries when taking references. More assorted pending patches. From-SVN: r16978
* cse.c (cse_insn): Don't look at JUMP_LABEL field of a conditionl return.Jeffrey A Law1997-11-161-1/+3
| | | | | | | | * cse.c (cse_insn): Don't look at JUMP_LABEL field of a conditionl return. (cse_end_of_basic_block): Similarly. From-SVN: r16534
* Update mainline egcs to gcc2 snapshot 971021.Jeff Law1997-11-021-8/+73
| | | | From-SVN: r16278
* Patches to fix minor optimizer bugsJim Wilson1997-10-201-0/+10
| | | | | | | | | | Patches to fix minor optimizer bugs * expmed.c (extract_bit_field): Don't make flag_force_mem disable extzv for memory operands. * cse.c (simplify_ternary_operation, case IF_THEN_ELSE): Collapse redundant conditional moves to single operand. From-SVN: r16129
* * cse.c (this_insn_cc0_mode): Initialize.Jeffrey A Law1997-09-301-1/+1
| | | | From-SVN: r15816
* combine.c (try_combine): Use NULL_RTX instead of '0' where appropriate in ↵David S. Miller1997-09-221-1/+1
| | | | | | | | | | | | | | | | | calls to gen_rtx(). * combine.c (try_combine): Use NULL_RTX instead of '0' where appropriate in calls to gen_rtx(). * cse.c (cse_main): Likewise. * emit-rtl.c (gen_label_rtx): Likewise. * expr.c (init_expr_once): Likewise. * haifa-sched.c (flush_pending_lists, sched_analyze_insn, sched_analyze, init_rgn_data_dependences, compute_block_backward_dependences): Likewise. * sched.c (schedule_insns): Likewise. * varasm.c (immed_double_const): Likewise. From-SVN: r15630
* cse.c (simplify_relational_operation): Set h0u just like h0s.Jeffrey A Law1997-09-211-16/+2
| | | | | | | * cse.c (simplify_relational_operation): Set h0u just like h0s. Similarly for h1u and h1s. From-SVN: r15616
* cse.c (simplify_relational_operation): If MODE specifies a mode wider than ↵Jeffrey A Law1997-09-151-2/+16
| | | | | | | | | | | | HOST_WIDE_INT... * cse.c (simplify_relational_operation): If MODE specifies a mode wider than HOST_WIDE_INT, then the high word of a CONST_INT is derived from the sign bit of the low word. Brought over from r5900 branch. From-SVN: r15454
* Fix irix6 execute/921117-1.c c-torture failure.Jim Wilson1997-09-011-0/+4
| | | | | | * cse.c (cse_insn): Don't record BLKmode values. From-SVN: r15024
* * Integrate alias analysis changes from jfc@mit.eduJeffrey A Law1997-08-111-299/+131
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (OBJS): Add alias.o (alias.o): Add dependencies. * alias.c: New file. * sched.c: Remove alias analysis code. It lives in alias.c now. (reg_last_uses_size): Declare. (sched_analyze_2): Add new arguments to true_dependence. (sched_analyze_insn): Use reg_last_uses_size instead of max_reg. (schedule_block): Initialize reg_last_uses_size. (schedule_insns): Always call init_alias_analysis. * calls.c (expand_call): Note calls to malloc, calloc, and realloc; mark return value from such functions as a pointer and keep track of them for alias analysis. If a return value from a function is a pointer, mark it as such. * combine.c (distribute_notes): Handle REG_NOALIAS. * cse.c (struct write_data): Delete. No longer needed. (invalidate): Don't call set_nonvarying_address_components anymore. Use true_dependence to decide if an entry should be removed from the hash table. (invalidate_memory): Remove WRITES argument, simplify appropriately. Fix all callers. (note_mem_written): Similarly for WRITE_PTR argument. (invalidate_from_clobbers): Similarly for W argument. (invalidate_for_call): Remove memory elements from the hash table. (refers_to_mem_p, cse_rtx_addr_varies_p): Deleted. (cse_rtx_varies_p): New function. Derived from old cse_rtx_addr_varies_p. (cse_insn): Remove WRITES_MEMORY and INIT variables and all references. Don't call note_mem_written anymore. Stack pushes invalidate the stack pointer if PUSH_ROUNDING is defined. No longer need to call cse_rtx_addr_varies_p to decide if a MEM should be invalidated. (skipped_writes_memory): Remove variable. (invalidate_skipped_set): Simplify and wewrite to use invalidate_memory. (invalidate_skipped_block): Simplify for new alias analysis code. (cse_set_around_loop): Likewise. (cse_main): Call init_alias_analysis. * flags.h (flag_alias_check, flag_argument_noalias): Declare. * toplev.c (flag_alias_check, flag_argument_noalias): Define. (f_options): Add new alias checking arguments. (main): Set flag_alias_check when optimizing. * local_alloc (validate_equiv_mem_from_store): Add new arguments to true_dependence. (memref_referenced_p): Likewise. * loop.c (NUM_STORES): Increase to 30. (prescan_loop): Only non-constant calls set unknown_address_altered. (invariant_p): Add new arguments to true_dependence. (record_giv): Initialize unrolled and shared fields. (emit_iv_add_mult): Call record_base_value as needed. * loop.h (struct induction): Add unrolled and shared fields. * unroll.c (unroll_loop): Call record_base_value as needed. (copy_loop_body): Likewise. (final_biv_value): Likewise. (final_giv_value): Likewise. (find_splittable_regs): Likewise. Only create one new pseudo if we have multiple address GIVs that were combined with the same dst_reg GIV. Note when a new register is created due to unrolling. * rtl.c (reg_note_name): Add REG_NOALIAS. * rtl.h (enum reg_note): Similarly. (rtx_varies_p, may_trap_p, side_effects_p): Declare. (volatile_refs_p, volatile_insn_p, remove_note): Likewise. (note_stores, refers_to_regno_p, reg_overlap_mentioned_p): Likewise. (true_dependence, read_dependence, anti_dependence): Likewise. (output_dependence, init_alias_analysis, end_alias_analysis): Likewise. (mark_user_reg, mark_reg_pointer): Likewise. jfc's alias analysis code. From-SVN: r14768
* (cse_insn): Ignore paradoxical SUBREGs unless we are looking for such.Richard Kenner1997-08-021-0/+31
| | | | From-SVN: r14625
* (find_best_addr): Add missing rtx_cost arguments.Jim Wilson1997-07-011-2/+2
| | | | From-SVN: r14367
* Delete erroneous references to (pseudo) in comments.Doug Evans1997-06-261-6/+6
| | | | From-SVN: r14325
* Use accessor macros to access arrays based on regno; move many of the arrays ↵Michael Meissner1997-05-301-5/+5
| | | | | | into a single structure. From-SVN: r14140
* (notreg_cost): New function, extracted from COST macro.Richard Kenner1997-05-171-13/+24
| | | | | | (COST): Use notreg_cost. From-SVN: r14075
* (cse_insn): Don't record a SRC that's a MEM and the same as aRichard Kenner1997-05-171-0/+15
| | | | | | REG_EQUIV note if DEST is set more than once. From-SVN: r14074
* (fold_rtx, case PLUS): When seeing if negative of constant is around,Richard Kenner1997-04-211-4/+10
| | | | | | make sure not dealing with largest negative. From-SVN: r13953
* (canon_reg, cse_insn): Don't examine insn_n_dups if recog_memoizedRichard Kenner1997-04-131-2/+6
| | | | | | fails to find a match. From-SVN: r13888
* cse.c (invalidate_from_clobbers): Delete unnecessary test for (clobber nil).Doug Evans1997-02-071-9/+7
| | | | | | | * cse.c (invalidate_from_clobbers): Delete unnecessary test for (clobber nil). From-SVN: r13618
* Get the right COST for a SUBREG when truncatingIan Lance Taylor1997-01-231-7/+19
| | | | From-SVN: r13549
* Check SMALL_REGISTER_CLASSES at runtimeIan Lance Taylor1996-12-131-1/+2
| | | | From-SVN: r13302
* (fold_rtx): Fold inside ASM_OPERANDS.Richard Kenner1996-09-231-0/+6
| | | | From-SVN: r12788
* Correct comments.Richard Kenner1996-09-231-1/+1
| | | | From-SVN: r12775
* (canon_hash, cse_insn): MEM is not unchanging if it is in the frame (sinceRichard Kenner1996-07-241-2/+4
| | | | | | the temp slot might be reused). From-SVN: r12562
* (note_mem_written): Varying structure memory access withJim Wilson1996-07-081-2/+7
| | | | | | AND address can alias scalars. From-SVN: r12417
* formatting tweaksMike Stump1996-07-031-18/+21
| | | | From-SVN: r12390
* (simplify_binary_operation...Jim Wilson1996-06-071-0/+5
| | | | | | | | (simplify_binary_operation, case MULT): Check for case where width is larger than HOST_BITS_PER_WIDE_INT, and upper most bit is set. We can not generate a simple shift in this case. From-SVN: r12238
* (cse_process_notes): Handle SUBREG like ZERO_EXTEND.Jim Wilson1996-04-211-0/+1
| | | | From-SVN: r11864
* (invalidate_skipped_set): Ignore CLOBBER after callingRichard Kenner1996-04-151-7/+7
| | | | | | note_mem_written, not before. From-SVN: r11786
* (simplify_unary_operation): Add new arg to REAL_VALUE_FROM_INT.Richard Kenner1996-04-141-3/+3
| | | | From-SVN: r11765
* (note_mem_written): Delete obsolete code for handlingJim Wilson1996-03-201-3/+0
| | | | | | (mem (scratch)). From-SVN: r11585
* (find_best_addr): Make sure folded address better before using.Richard Kenner1995-12-271-3/+15
| | | | From-SVN: r10873
* (insert): Don't put a REG into qty_const.Richard Kenner1995-11-261-3/+5
| | | | From-SVN: r10607
* (invalidate): For a pseudo register, do a loop to invalidate all tableRichard Kenner1995-11-051-1/+9
| | | | | | entries, irrespective of mode. From-SVN: r10556
* (set_nonvarying_address_components, case AND): Add *pend to end.Richard Kenner1995-10-031-1/+2
| | | | | | | (set_nonvarying_address_components, case AND): Add *pend to end. Add constant to start instead of subtracting it. From-SVN: r10426
* (recorded_label_ref): New variable.Richard Kenner1995-09-161-6/+9
| | | | | | | (insert): Set instead of cse_jumps_altered. (cse_main): Initialize it and return 1 if nonzero at end. From-SVN: r10368
* (insert): Set cse_jumps_altered when inserting a LABEL_REF.Richard Kenner1995-09-151-0/+8
| | | | From-SVN: r10366
* (canon_hash, CONST_DOUBLE): Hash integer and real differently.Richard Kenner1995-08-311-5/+9
| | | | From-SVN: r10303
* Fix spelling errors.Richard Kenner1995-08-281-1/+1
| | | | From-SVN: r10289
* (set_nonvarying_address_components): Handle addresses which are the sum of ↵Richard Kenner1995-08-131-0/+50
| | | | | | | | | | two constant pseudo regs. (set_nonvarying_address_components): Handle addresses which are the sum of two constant pseudo regs. (cse_rtx_addr_varies_p): Likewise. From-SVN: r10220
* (cse_insn): When do special handling for (set REG0 REG1), must deleteRichard Kenner1995-07-261-0/+6
| | | | | | REG_EQUAL note from insn if it mentions REG0. From-SVN: r10169
* (cse_insn): Ifdef out code that pre-truncates src_folded.Richard Kenner1995-07-141-0/+8
| | | | From-SVN: r10127
* Update FSF address.Richard Kenner1995-06-151-1/+2
| | | | From-SVN: r9959
* (cse_basic_block): Fix test for whether block ends with a barrier.Richard Kenner1995-06-091-9/+12
| | | | | | Return next insn, not 0, if block ends in a barrier. From-SVN: r9916