summaryrefslogtreecommitdiffstats
path: root/gcc/cse.c
Commit message (Collapse)AuthorAgeFilesLines
...
* * cse.c (cse_insn): Set "cse_jumps_altered" when collapsinglaw1993-12-241-0/+1
| | | | | | | | | a switch statement into an unconditional jump. * toplev.c (rest_of_compilation): Rerun jump_optimize before the second CSE pass. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6305 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation): Can fold multi-word operations when first iskenner1993-12-241-6/+13
| | | | | | | | | CONST_INT. (simplify_binary_operation, case PLUS, MINUS): Don't call plus_constant when OP0 is VOIDmode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6298 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, case *SHIFT*): Reduce arg1 astege1993-12-241-12/+3
| | | | | | | defined by SHIFT_COUNT_TRUNCATED. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6296 138bc75d-0d04-0410-961f-82ee72b054a4
* (delete_reg_equiv): Don't reference elements of REG_{NEXT,PREV}_EQVkenner1993-12-231-3/+5
| | | | | | | that are not defined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6276 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_insn): Call `invalidate' also for STRICT_LOW_PART andrms1993-11-041-12/+44
| | | | | | | | | | | ZERO_EXTRACT (three places). (invalidate_from_clobbers): Likewise (two places). (cse_around_loop): Likewise. (invalidate_skipped_set): Likewise. (cse_set_around_loop): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5993 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_insn): When using src_related, copy the rtx.rms1993-10-271-2/+2
| | | | | | | Likewise for src_eqv_here. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5922 138bc75d-0d04-0410-961f-82ee72b054a4
* (fold_rtx): Alter previous change: don't fold the shiftrms1993-10-211-1/+26
| | | | | | | | | | | | if the count exceeds the width of the value inside the subreg. (note_mem_written): (mem (scratch)) means clobber everything. (fold_rtx): Special case handling for folding a subreg of the result of a left shift. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5854 138bc75d-0d04-0410-961f-82ee72b054a4
* (record_jump_cond): At end, make missing equivalencesrms1993-10-131-14/+9
| | | | | | | first, and then merge them. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5769 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation): Test value of SHIFT_COUNT_TRUNCATED if itkenner1993-10-111-4/+8
| | | | | | | is defined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5731 138bc75d-0d04-0410-961f-82ee72b054a4
* (record_jump_cond): Rehash OP1 if OP0's insert_regs returns nonzero.kenner1993-10-061-0/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5631 138bc75d-0d04-0410-961f-82ee72b054a4
* (insert_regs): Always return something.tege1993-10-021-4/+2
| | | | | | | | | | (simplify_unary_operation): Remove unused variable. (cse_process_notes): Likewise. (invalidate_skipped_block): Likewise. (cse_set_around_loop): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5555 138bc75d-0d04-0410-961f-82ee72b054a4
* * cse.c: (FIXED_REGNO_P): HARD_FRAME_POINTER_REGNUM is fixed.dje1993-09-241-11/+22
| | | | | | | | | | | | | | (CHEAP_REG): HARD_FRAME_POINTER_REGNUM is cheap. (FIXED_BASE_PLUS): Allow hard frame pointer as base. (NONZERO_BASE_PLUS_P): Likewise. (cannon_hash, case REG): Add HARD_FRAME_POINTER_REGNUM to list of special registers for SMALL_REGISTER_CLASSES. (find_best_addr): Addresses containing HARD_FRAME_POINTER_REGNUM cannot be replaced. (cse_main): value in HARD_FRAME_POINTER_REGNUM is preserved across calls. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5451 138bc75d-0d04-0410-961f-82ee72b054a4
* (fold_rtx, case MINUS): Copy result obtained from hash table.kenner1993-09-171-1/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5347 138bc75d-0d04-0410-961f-82ee72b054a4
* (fold_rtx, case SUBREG): If paradoxical SUBREG of a constant, returnkenner1993-09-171-4/+10
| | | | | | | the constant. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5346 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_insn): After inserting src_eqv, check to see if it iswilson1993-08-101-0/+8
| | | | | | | | identical to any uninserted SET_SRCs, and if so, set their src_elt to src_eqv_elt. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5129 138bc75d-0d04-0410-961f-82ee72b054a4
* Include stdio.h before rtl.h.rms1993-07-091-1/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4884 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, case MINUS): Fix backwardsrms1993-07-061-1/+1
| | | | | | | test added in last change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4859 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_*_operation, fold_rtx, record_jump_cond, cse_insn): Usekenner1993-06-281-25/+19
| | | | | | | INTEGRAL_MODE_P and FLOAT_MODE_P. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4780 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix typo in copyright line.kenner1993-06-171-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4686 138bc75d-0d04-0410-961f-82ee72b054a4
* (invalidate_skipped_set): Promote "nonscalar" to "all".rms1993-06-141-0/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4679 138bc75d-0d04-0410-961f-82ee72b054a4
* (record_jump_cond): Look up op1 again after inserting op0.rms1993-06-121-0/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4669 138bc75d-0d04-0410-961f-82ee72b054a4
* (fold_rtx): Correct check for associating shifts andrms1993-05-281-5/+13
| | | | | | | | ending up with a shift count too large; convert to the largest valid for ASHIFTRT and don't fold all others. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4585 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, simplify_relational_operation): Check forkenner1993-05-061-7/+7
| | | | | | | MODE_CC modes, not just CCmode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4352 138bc75d-0d04-0410-961f-82ee72b054a4
* (record_jump_cond): Use mode of op0 or op1, not MODE,rms1993-05-021-4/+13
| | | | | | | when testing for narrowing or widening subregs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4301 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation): Reject CCmode in A & (~A) -> 0.rms1993-05-011-4/+5
| | | | | | | Also fix typos in previous change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4295 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_insn): Reset the INSN_CODE for conditionalrms1993-04-301-3/+18
| | | | | | | or computed jumps which have been converted into simplejumps. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4287 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, case SMAX): Cast to unsiged HOST_WIDE_INTkenner1993-04-281-1/+2
| | | | | | | instead of unsigned int. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4259 138bc75d-0d04-0410-961f-82ee72b054a4
* (invalidate): Use proper type for in_table.kenner1993-04-241-1/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@4208 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, case MULT): When testing forkenner1993-03-311-4/+12
| | | | | | | | floating-point equality, make sure we do so inside a region protected from traps. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3963 138bc75d-0d04-0410-961f-82ee72b054a4
* (insert_regs): If a REG already is in a class but not in the mode wekenner1993-03-311-3/+8
| | | | | | | want, don't do anything to the classes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3951 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation): real_value_truncaterms1993-03-311-5/+5
| | | | | | | | | | | | returns REAL_VALUE_TYPE. Convert rtx_code into tree_code for argument to REAL_ARITHMETIC. (simplify_unary_operation): Use new ..._RNDZINT macros instead of casting value of REAL_VALUE_FIX_TRUNCATE and REAL_VALUE_UNSIGNED_FIX_TRUNCATE. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3943 138bc75d-0d04-0410-961f-82ee72b054a4
* (CHEAP_REG): Add missing parens.kenner1993-03-241-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3861 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_process_notes): Replace NULL_RTX with just zero.wilson1993-03-201-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3795 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_plus_minus): Count CONSTs coming in and going out; we havekenner1993-03-191-6/+10
| | | | | | | | simplified things if we have more CONSTs going out even if we have the same number of total terms. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3787 138bc75d-0d04-0410-961f-82ee72b054a4
* (FIXED_REGNO_P): Remove previous change; all callers but one already check.kenner1993-03-161-10/+7
| | | | | | | | (CHEAP_REG): Only call FIXED_REGNO_P for hard regs. (fold_rtx): Clarify comments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3762 138bc75d-0d04-0410-961f-82ee72b054a4
* (FIXED_REGNO_P): Pseudos can't be fixed regs.jrv1993-03-161-5/+9
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3757 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_plus_minus): Remove last change. Instead, count initialkenner1993-03-151-13/+4
| | | | | | | operands and test against that count to see if we did anything. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3748 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_plus_minus): Reject "simplifications" that are too complexkenner1993-03-141-1/+11
| | | | | | | in form. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3733 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_plus_minus): Correct sign error in expanding NOT.kenner1993-03-141-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3732 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_plus_minus): When seeing if we have reduced the number ofkenner1993-03-141-5/+11
| | | | | | | operands, ensure we count a CONST result as two operands. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3729 138bc75d-0d04-0410-961f-82ee72b054a4
* (refers_to_mem_p): Use rtx_equal_p to see if bases are equal.kenner1993-03-121-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3719 138bc75d-0d04-0410-961f-82ee72b054a4
* (set_nonvarying_address_components): Fix type mismatch with caller.kenner1993-03-121-3/+4
| | | | | | | (refers_to_mem_p): Call properly in second call. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3718 138bc75d-0d04-0410-961f-82ee72b054a4
* (CHEAP_REG): New macro; makes virtual regs cheap too.kenner1993-03-121-7/+13
| | | | | | | | (COST): Use CHEAP_REG. (rtx_cost, case REG): Use CHEAP_REG to return zero for some REGs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3708 138bc75d-0d04-0410-961f-82ee72b054a4
* * cse.c (set_nonvarying_address_components): New function.law1993-03-111-110/+88
| | | | | | | | | | (invalidate): Use set_nonvarying_address_components instead of computing them. (refers_to_mem_p): Likewise. Simplify checks for conflicting memory accesses. Make static. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3703 138bc75d-0d04-0410-961f-82ee72b054a4
* (cse_gen_binary, simplify_plus_minus): New functions.kenner1993-03-081-215/+249
| | | | | | | | | | | (find_best_addr): Use cse_gen_binary. (simplify_binary_operation, fold_rtx): Likewise. Remove most special-cases for PLUS and MINUS and call simplify_plus_minus instead. Clean up some tests for FP. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3680 138bc75d-0d04-0410-961f-82ee72b054a4
* Add prototypes for static functions.kenner1993-03-081-50/+80
| | | | | | | | | (struct cse_basic_block_data): Move to front of file since it constains struct used in a prototype. (refers_to_p, find_best_addr): Now static. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3675 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation): Move integer CONST_DOUBLE folding out ofkenner1993-03-051-5/+60
| | | | | | | | | | REAL_IS_NOT_DOUBLE conditional. (simplify_relational_operation): Put float CONST_DOUBLE folding under a REAL_IS_NOT_DOUBLE conditional. Add folding for integer CONST_DOUBLE comparisons. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3661 138bc75d-0d04-0410-961f-82ee72b054a4
* (note_mem_written): QImode varying structure memory accesses can alias scalars.wilson1993-03-051-3/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3654 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_relation_operation): We can compute the result of akenner1993-01-281-2/+6
| | | | | | | | comparison of CONST_INTs no matter what mode the computation is to be done in. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3372 138bc75d-0d04-0410-961f-82ee72b054a4
* (simplify_binary_operation, case SMAX): Correctly compute largestkenner1993-01-271-1/+1
| | | | | | | possible signed integer. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3360 138bc75d-0d04-0410-961f-82ee72b054a4
OpenPOWER on IntegriCloud