Merge these patches:

2009-02-24  J"orn Rennecke  <joern.rennecke@arc.com>
        * loop-doloop.c (doloop_valid_p): Rename to:
        (validize_doloop).  Try to fix up loops with conditons for infinite
        looping by enclosing them in an outer loop.
        Changed caller.
        (add_test): Add new parameter edgep.  Changed caller.

2009-05-20  J"orn Rennecke  <joern.rennecke@arc.com>
        * config/rs6000/rs6000.md (doloop_end): Accept extra operand.
        * config/spu/spu.md (doloop_end): Accept extra operand.
2008-12-04  J"orn Rennecke  <joern.rennecke@arc.com>
        * config/sh/sh.md (doloop_end): Accept extra operand.
[Needs other ports adjusted too]
2008-08-29  J"orn Rennecke  <joern.rennecke@arc.com>
        * loop-doloop.c (doloop_modify): Pass doloop_end pattern to
        gen_doloop_begin.
        * config/c4x/c4x.md (doloop_begin): Operand 4 is doloop_end pattern.
        * loop-doloop.c (doloop_optimize): Pass flag to indicate if loop is
        entered at top to gen_doloop_end.
        * config/arc/arc.c (arc_reorg): If we can't find the loop entry at
        the loop top, search entire function for a matching loop begin,
        and record information about it if found.
        * config/arc/arc.md (doloop_begin): Now takes five operands.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2574 8ad889b4-764b-0410-b193-d8a7b30fb157
2012-08-14  Joern Rennecke  <joern.rennecke@embecosm.com>
        * target.def: Merge in definitions and documentation for
        TARGET_CAN_FOLLOW_JUMP / TARGET_PRESERVE_RELOAD_P.
        * doc/tm.texi.in: Add documentation locations for the above.
        * doc/tm.texi: Regenerate.

2008-12-10  J"orn Rennecke  <joern.rennecke@arc.com>
        * reorg.c (fill_slots_from_thread): Initialize crossing.
2008-12-08  J"orn Rennecke  <joern.rennecke@arc.com>
        * hooks.c (hook_bool_const_rtx_const_rtx_true): New function.
        * hooks.h (hook_bool_const_rtx_const_rtx_true): Declare.
        * reorg.c (follow_jumps): New parameters jump and cp.
        Changed all callers.

2008-08-29  J"orn Rennecke  <joern.rennecke@arc.com>
        * reload.c (push_reload): Mark values flagged by
        targetm.preserve_reload_p as RELOAD_OTHER.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2575 8ad889b4-764b-0410-b193-d8a7b30fb157
Remove excess 'crossing' variable.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2576 8ad889b4-764b-0410-b193-d8a7b30fb157
Add ARCompact port to gcc 4.8, merged to that point that cc1 can be linked.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2577 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.h (REG_OK_FOR_{BASE,INDEX}_P_{,NON}STRICT):
        Fix mixup.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2578 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.c (arc_compare_op0, arc_compare_op1): Delete.
        (gen_compare_reg): Change type of first argument; get operands from
        there, and force into registers if needed.  Changed all callers.
        Use CC_REG.
        * config/arc/arc.md (R12_REG): Define.
        (cmpsi, seq, sne, sgt, sle, sge, slt, sgtu, sleu, sgeu, sltu): Delete.
        (SDF, OPTFPE_CMP): New mode iterators.
        (cmp): New mode attribute.
        (cbranchsi4, cstoresi4, cstore<SDF:mode>4): New patterns.
        (scc_insn, branch_insn): No longer suppress generator functions.
        (beq, bne, bgt, ble, bge, blt, bgtu, bleu, bgeu, bltu, bunge): Delete.
        (bungt, bunle, bunlt, buneq, bltgt, bordered, bunordered): Likewise.
        (cbranch<SDF:mode>4): New patterns.
        (cmpsf, cmpdf): Delete.
        (cmp_float): Use RETURN_ADDR_REGNUM and R12_REG.
        (cmpsf_eq, cmpsf_gt, cmpsf_ge, cmpsf_uneq, cmpsf_ord): Describe with
        OPTFPE_CMP mode iteration.
        (cmpdf_eq, cmpdf_gt, cmpdf_ge, cmpdf_uneq, cmpdf_ord): Likewise.
        * config/arc/arc-protos.h (gen_compare_reg): Update prototype.

        * config/arc/arc.c (arc_print_operand): Check that we have an actual
        JUMP_INSN before using INSN_ANNULLED_BRANCH_P.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2579 8ad889b4-764b-0410-b193-d8a7b30fb157
Move arc libgcc configuration to proper place in new toplevel libgcc directory:
libgcc:
        * config.host (arc-*-elf*, arc600-*-linux-uclibc*): New configurations.
        (arc601-*-linux-uclibc*, arc*-*-linux-uclibc*): Likewise.
        * config/arc: New Directory.
gcc:
        * config.gcc: Move ARC libgcc configuration bits into libgcc's
        config.host.
        * config/arc/t-arc: Move ARC libgcc configuration bits to its
        proper place in the new libgcc toplevel directory.
        * config/arc/asm.h, config/arc/libgcc-excl.ver: Likewise (entire file).
        * config/arc/crtg.asm, config/arc/crti.asm: Likewise.
        * config/arc/crtn.asm, config/arc/initfini.c: Likewise.
        * config/arc/t-arc700-uClibc, config/arc/dp-hack.h: Likewise.
        * config/arc/fp-hack.h, config/arc/lib1funcs.asm: Likewise.
        * config/arc/crtgend.asm, config/arc/t-arc-newlib: Likewise.
        * config/arc/divtab-arc700.c, config/arc/t-arc600-uClibc: Likewise.
        * config/arc/ieee-754, config/arc/gmon: Likewise (entire directory).

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2580 8ad889b4-764b-0410-b193-d8a7b30fb157
        *config/arc/arc.c (arc_legitimize_address): Rename to ..
        (arc_legitimize_address_0): .. this.  Changed all callers.
        (arc_legitimize_address): New function, to provide the expected
        return on failure for the TARGET_LEGITIMIZE_ADDRESS hook.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2581 8ad889b4-764b-0410-b193-d8a7b30fb157
	* config/arc/arc.c (arc_can_eliminate): Fix logic.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2582 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/crtg.asm, config/arc/crti.asm config/arc/crtn.asm:
        Move, respectively, to:
        * config/arc/crtg.S, config/arc/crti.S config/arc/crtn.S.
        * config/arc/crtgend.asm, config/arc/lib1funcs.asm:
        Move, respectively, to:
        * config/arc/crtgend.S, config/arc/lib1funcs.S.
        * config/arc/t-arc: Reflect above name changes.  Remove $(T).
        (crti.o, crtn.o): Remove rules.
        * config/arc/t-arc600-uClibc: Remove $(T).
        * config/arc/t-arc700-uClibc, config/arc/t-arc-newlib: Likewise.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2583 8ad889b4-764b-0410-b193-d8a7b30fb157
Merge in this change:

2008-11-19  J"orn Rennecke  <joern.rennecke@arc.com>

        Wrap up of changes going back to r59971
        * final.c (get_attr_length_1): Use direct recursion rather than
        calling get_attr_length.
        (get_attr_lock_length): New function.
        (INSN_VARIABLE_LENGTH_P): Define.
        (shorten_branches): Take HAVE_ATTR_lock_length into account.
        Don't overwrite non-delay slot insn lengths with the lengths of
        delay slot insns with same uid.
        * genattrtab.c (lock_length_str): New variable.
        (make_length_attrs): New parameter base.
        (main): Initialize lock_length_str.
        Generate lock_lengths attributes.
        * genattr.c (gen_attr): Emit declarations for lock_length attributes.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2584 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.c (arc_init): Always default to ARC700.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2585 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.md (attribute delay_slot_filled): : Check that we
        have an actual JUMP_INSN before using INSN_ANNULLED_BRANCH_P.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2586 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.h (TARGET_CPU_CPP_BUILTIN): Define __Xnorm /
        __Xbarrel_shifter here depending on hardware selection ...
        (CPP_SPEC) .. instead of here depending on a single switch.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2587 8ad889b4-764b-0410-b193-d8a7b30fb157
        * acinclude.m4 (GLIBCXX_ENABLE_SJLJ_EXCEPTIONS): In auto-test,
        also scan for _Unwind_SjLj_Register.
        * configure: Regenerate.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2588 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.md (cbranchsi4): Emit last insn.
        (cstoresi4, cstore<SDF:mode>4, cbranch<SDF:mode>4): Likewise.
        (scc_insn, branch_insn): Separate out expander, preserving mode
        of CC_REG.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2589 8ad889b4-764b-0410-b193-d8a7b30fb157
        * web.c (union_match_dups): Avoid NULL dereference at end of
        loop; also, actually scan each reference.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2590 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.c (CCFSM_DBR_ISCOMPACT): Check that we
        have an actual JUMP_INSN before using INSN_ANNULLED_BRANCH_P.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2591 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.c (emit_store_direct, arc_initialize_trampoline):
        Expect a block of memory instead of its address.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2592 8ad889b4-764b-0410-b193-d8a7b30fb157
        * config/arc/arc.c (arc_rtx_costs) <ASHIFT,ASHIFTRT,LSHIFTRT>:
        Avoid negative cost.

git-svn-id: svn+ssh://thomas.embecosm.com/embecosm/Customer-Projects/synopsys/arc_gnu/branches/arc_gnu_4.8/gcc-4.8@2593 8ad889b4-764b-0410-b193-d8a7b30fb157