oota-llvm.git
17 years agoFor PR950:
Reid Spencer [Mon, 20 Nov 2006 01:22:35 +0000 (01:22 +0000)]
For PR950:
First in a series of patches to convert SetCondInst into ICmpInst and
FCmpInst using only two opcodes and having the instructions contain their
predicate value. Nothing uses these classes yet. More patches to follow.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31867 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFor PR950:
Reid Spencer [Sun, 19 Nov 2006 23:07:00 +0000 (23:07 +0000)]
For PR950:
Retain the signedness of the old integer types in a new TypeInfo structure
so that it can be used in the grammar to implement auto-upgrade of things
that depended on signedness of types. This doesn't implement any new
functionality in the AsmParser, its just plumbing for future changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31866 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCorrections from review.
Reid Spencer [Sun, 19 Nov 2006 03:00:14 +0000 (03:00 +0000)]
Corrections from review.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31865 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDon't transform in another bad case: if the block is empty, it should be
Chris Lattner [Sat, 18 Nov 2006 22:25:39 +0000 (22:25 +0000)]
Don't transform in another bad case: if the block is empty, it should be
simplified before we do this xform so that our cost model is accurate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31864 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix another case we *don't* want to do this xform.
Chris Lattner [Sat, 18 Nov 2006 21:56:39 +0000 (21:56 +0000)]
Fix another case we *don't* want to do this xform.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31861 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUpdate a reference to the old setcc instruction.
Reid Spencer [Sat, 18 Nov 2006 21:55:45 +0000 (21:55 +0000)]
Update a reference to the old setcc instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31860 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFor PR950:
Reid Spencer [Sat, 18 Nov 2006 21:50:54 +0000 (21:50 +0000)]
For PR950:
Documentation preview of the upcoming icmp and fcmp instructions that
will replace the various setcc instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31859 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMachineInstr includes this
Chris Lattner [Sat, 18 Nov 2006 21:48:05 +0000 (21:48 +0000)]
MachineInstr includes this

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31858 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoImplement operator<< for machine basic blocks to make it easier to dump them.
Chris Lattner [Sat, 18 Nov 2006 21:47:36 +0000 (21:47 +0000)]
Implement operator<< for machine basic blocks to make it easier to dump them.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31857 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agomake the previous change more aggressive, moving any block with no fallthrough.
Chris Lattner [Sat, 18 Nov 2006 21:30:35 +0000 (21:30 +0000)]
make the previous change more aggressive, moving any block with no fallthrough.
This speeds up yacr2 by 7% on a core2.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31856 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMinor code layout tweak: if we have something like this:
Chris Lattner [Sat, 18 Nov 2006 20:47:54 +0000 (20:47 +0000)]
Minor code layout tweak: if we have something like this:

  if (cond) goto BB2
BB1:
    ...
    return;
BB2:
   ...

Move BB1 to the end of the function so that the code falls through in the
non-return case.  This has the effect of moving assert (and other no-return
call) bodies and return blocks out of loops.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31855 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDo not convert massive blocks on phi nodes into select statements. Instead
Chris Lattner [Sat, 18 Nov 2006 19:19:36 +0000 (19:19 +0000)]
Do not convert massive blocks on phi nodes into select statements.  Instead
only do these transformations if there are a small number of phi's.
This speeds up Ptrdist/ks from 2.35s to 2.19s on my mac pro.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31853 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoconverting massive blocks of phis into selects like this is silly.
Chris Lattner [Sat, 18 Nov 2006 19:17:52 +0000 (19:17 +0000)]
converting massive blocks of phis into selects like this is silly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31852 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMake the awk filter print out which files its eliminating.
Reid Spencer [Sat, 18 Nov 2006 18:30:18 +0000 (18:30 +0000)]
Make the awk filter print out which files its eliminating.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31851 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoThis is a utility for preparing patches against LLVM. It runs cvs diff with
Reid Spencer [Sat, 18 Nov 2006 18:02:30 +0000 (18:02 +0000)]
This is a utility for preparing patches against LLVM. It runs cvs diff with
the correct options, places the patch content in order that makes sense for
review, and filters cruft out of the patch (like diffs in *.cvs files). It
produces both a NAME.patch.raw (unfiltered) and NAME.patch (filtered) file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31850 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoProvide a list of gccld optimization switches.
Reid Spencer [Sat, 18 Nov 2006 17:14:09 +0000 (17:14 +0000)]
Provide a list of gccld optimization switches.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31849 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix bugs in this. What was I thinking??? :)
Reid Spencer [Sat, 18 Nov 2006 08:06:17 +0000 (08:06 +0000)]
Fix bugs in this. What was I thinking??? :)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31848 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMovind newly-intorudced dll* linkage stuff & windows CC to "supported"
Anton Korobeynikov [Sat, 18 Nov 2006 08:04:48 +0000 (08:04 +0000)]
Movind newly-intorudced dll* linkage stuff & windows CC to "supported"
list

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31847 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix bug
Chris Lattner [Sat, 18 Nov 2006 07:52:10 +0000 (07:52 +0000)]
fix bug

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31846 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofirst draft of 1.9 release notes
Chris Lattner [Sat, 18 Nov 2006 07:51:14 +0000 (07:51 +0000)]
first draft of 1.9 release notes

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31845 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFail even if opt doesn't print anything.
Reid Spencer [Sat, 18 Nov 2006 06:08:21 +0000 (06:08 +0000)]
Fail even if opt doesn't print anything.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31844 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd a simple test to make sure getModRefInfo is 1/2 way sane.
Reid Spencer [Sat, 18 Nov 2006 05:52:18 +0000 (05:52 +0000)]
Add a simple test to make sure getModRefInfo is 1/2 way sane.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31842 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoHave ConstantExprs upgrade opcodes the same way as instructions.
Reid Spencer [Sat, 18 Nov 2006 04:37:19 +0000 (04:37 +0000)]
Have ConstantExprs upgrade opcodes the same way as instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31841 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoon ppc64, float arguments take 8-byte stack slots not 4-byte stack slots.
Chris Lattner [Sat, 18 Nov 2006 01:57:19 +0000 (01:57 +0000)]
on ppc64, float arguments take 8-byte stack slots not 4-byte stack slots.
Also, valist should create a pointer RC reg class value, not a GPRC value.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31840 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agomake sure to safe LR8 in the right stack slot for PPC64
Chris Lattner [Sat, 18 Nov 2006 01:34:43 +0000 (01:34 +0000)]
make sure to safe LR8 in the right stack slot for PPC64

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31839 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoPretty print 'rldicr r2, r2, 2, 61' as 'sldi r2, r2, 2'.
Chris Lattner [Sat, 18 Nov 2006 01:23:56 +0000 (01:23 +0000)]
Pretty print 'rldicr r2, r2, 2, 61' as 'sldi r2, r2, 2'.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31838 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRewrite the branch selector to be correct in the face of large functions.
Chris Lattner [Sat, 18 Nov 2006 00:32:03 +0000 (00:32 +0000)]
Rewrite the branch selector to be correct in the face of large functions.
The algorithm it used before wasn't 100% correct, we now use an iterative
expansion model.  This fixes assembler errors when compiling 403.gcc with
tail merging enabled.

Change the way the branch selector works overall: Now, the isel generates
PPC::BCC instructions (as it used to) directly, and these BCC instructions
are emitted to the output or jitted directly if branches don't need
expansion.  Only if branches need expansion are instructions rewritten
and created.  This should make branch select faster, and eliminates the
Bxx instructions from the .td file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31837 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd encoding for BCC, after finally wrestling strange ppc/tblgen endianness
Chris Lattner [Fri, 17 Nov 2006 23:53:28 +0000 (23:53 +0000)]
add encoding for BCC, after finally wrestling strange ppc/tblgen endianness
issues to the ground.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31836 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoconvert PPC::BCC to use the 'pred' operand instead of separate predicate
Chris Lattner [Fri, 17 Nov 2006 22:37:34 +0000 (22:37 +0000)]
convert PPC::BCC to use the 'pred' operand instead of separate predicate
value and CR reg #.  This requires swapping the order of these everywhere
that touches BCC and requires us to write custom matching logic for
PPCcondbranch :(

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31835 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agorename PPC::COND_BRANCH to PPC::BCC
Chris Lattner [Fri, 17 Nov 2006 22:14:47 +0000 (22:14 +0000)]
rename PPC::COND_BRANCH to PPC::BCC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31834 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agostart using PPC predicates more consistently.
Chris Lattner [Fri, 17 Nov 2006 22:10:59 +0000 (22:10 +0000)]
start using PPC predicates more consistently.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31833 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFor unsigned 8-bit division. Use movzbw to set the lower 8 bits of AX while
Evan Cheng [Fri, 17 Nov 2006 22:10:14 +0000 (22:10 +0000)]
For unsigned 8-bit division. Use movzbw to set the lower 8 bits of AX while
clearing the upper 8-bits instead of issuing two instructions. This also
eliminates the need to target the AH register which can be problematic on
x86-64.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31832 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoHopefully a good crack at making debugging work on intel -disable-fp-elim.
Jim Laskey [Fri, 17 Nov 2006 21:19:15 +0000 (21:19 +0000)]
Hopefully a good crack at making debugging work on intel -disable-fp-elim.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31830 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd a x86-64 test case: movb %sil, %ah is illegal.
Evan Cheng [Fri, 17 Nov 2006 20:41:55 +0000 (20:41 +0000)]
Add a x86-64 test case: movb %sil, %ah is illegal.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31829 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAssert unhandled case.
Jim Laskey [Fri, 17 Nov 2006 18:49:39 +0000 (18:49 +0000)]
Assert unhandled case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31828 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCase sensitive not.
Jim Laskey [Fri, 17 Nov 2006 18:00:39 +0000 (18:00 +0000)]
Case sensitive not.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31827 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCheck for MaxAlign.
Jim Laskey [Fri, 17 Nov 2006 17:19:49 +0000 (17:19 +0000)]
Check for MaxAlign.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31826 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoTests to verify PowerPC ABI.
Jim Laskey [Fri, 17 Nov 2006 16:54:21 +0000 (16:54 +0000)]
Tests to verify PowerPC ABI.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31825 91177308-0d34-0410-b5e6-96231b3b80d8

17 years ago1. Ignore the -disable-fp-elim when the routine is a leaf.
Jim Laskey [Fri, 17 Nov 2006 16:09:31 +0000 (16:09 +0000)]
1. Ignore the -disable-fp-elim when the routine is a leaf.
2. Offsets on 64-bit stores are still in bytes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31824 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoTypo. Fix the nightly tests.
Jim Laskey [Fri, 17 Nov 2006 14:06:41 +0000 (14:06 +0000)]
Typo. Fix the nightly tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31823 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFixing the ENABLE_OPTIMIZED=1 DISABLE_ASSERTIONS=1 build.
Jim Laskey [Fri, 17 Nov 2006 13:07:55 +0000 (13:07 +0000)]
Fixing the ENABLE_OPTIMIZED=1 DISABLE_ASSERTIONS=1 build.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31822 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNeed <iostream> for the time being.
Bill Wendling [Fri, 17 Nov 2006 10:09:22 +0000 (10:09 +0000)]
Need <iostream> for the time being.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31821 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNeed iostream to be included for the time being.
Bill Wendling [Fri, 17 Nov 2006 10:05:07 +0000 (10:05 +0000)]
Need iostream to be included for the time being.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31820 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMoved definition of llvm_ostream wrappers to the Streams.cpp file.
Bill Wendling [Fri, 17 Nov 2006 09:54:47 +0000 (09:54 +0000)]
Moved definition of llvm_ostream wrappers to the Streams.cpp file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31819 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUsed llvm_ostream instead of std::ostream objects. This will reduce use
Bill Wendling [Fri, 17 Nov 2006 09:52:49 +0000 (09:52 +0000)]
Used llvm_ostream instead of std::ostream objects. This will reduce use
of the icky <iostream> class.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31818 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdded wrappers for the std::cerr/std::cout objects. The wrappers will
Bill Wendling [Fri, 17 Nov 2006 09:51:22 +0000 (09:51 +0000)]
Added wrappers for the std::cerr/std::cout objects. The wrappers will
soon replace all uses of those objects.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31817 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNeeded <iostream> for now.
Bill Wendling [Fri, 17 Nov 2006 09:44:28 +0000 (09:44 +0000)]
Needed <iostream> for now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31816 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNeeds the iostream include.
Bill Wendling [Fri, 17 Nov 2006 09:38:03 +0000 (09:38 +0000)]
Needs the iostream include.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31815 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemoved iostream #includes. Replaced std::cerr with DOUT.
Bill Wendling [Fri, 17 Nov 2006 08:03:48 +0000 (08:03 +0000)]
Removed iostream #includes. Replaced std::cerr with DOUT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31814 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemoved even more std::cerr and #include <iostream> things.
Bill Wendling [Fri, 17 Nov 2006 07:52:03 +0000 (07:52 +0000)]
Removed even more std::cerr and #include <iostream> things.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31813 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoReplaced DEBUG(std::cerr with DOUT.
Bill Wendling [Fri, 17 Nov 2006 07:36:54 +0000 (07:36 +0000)]
Replaced DEBUG(std::cerr with DOUT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31812 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoReplace DEBUG(std::cerr with DOUT. Removed some iostream #includes.
Bill Wendling [Fri, 17 Nov 2006 07:33:59 +0000 (07:33 +0000)]
Replace DEBUG(std::cerr with DOUT. Removed some iostream #includes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31811 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemoved unneeded <iostream> #include.
Bill Wendling [Fri, 17 Nov 2006 07:10:51 +0000 (07:10 +0000)]
Removed unneeded <iostream> #include.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31810 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoIf an indvar with a variable stride is used by the exit condition, go ahead
Chris Lattner [Fri, 17 Nov 2006 06:17:33 +0000 (06:17 +0000)]
If an indvar with a variable stride is used by the exit condition, go ahead
and handle it like constant stride vars.  This fixes some bad codegen in
variable stride cases.  For example, it compiles this:

void foo(int k, int i) {
  for (k=i+i; k <= 8192; k+=i)
    flags2[k] = 0;
}

to:

LBB1_1: #bb.preheader
        movl %eax, %ecx
        addl %ecx, %ecx
        movl L_flags2$non_lazy_ptr, %edx
LBB1_2: #bb
        movb $0, (%edx,%ecx)
        addl %eax, %ecx
        cmpl $8192, %ecx
        jle LBB1_2      #bb
LBB1_5: #return
        ret

or (if the array is local and we are in dynamic-nonpic or static mode):

LBB3_2: #bb
        movb $0, _flags2(%ecx)
        addl %eax, %ecx
        cmpl $8192, %ecx
        jle LBB3_2      #bb

and:

        lis r2, ha16(L_flags2$non_lazy_ptr)
        lwz r2, lo16(L_flags2$non_lazy_ptr)(r2)
        slwi r3, r4, 1
LBB1_2: ;bb
        li r5, 0
        add r6, r4, r3
        stbx r5, r2, r3
        cmpwi cr0, r6, 8192
        bgt cr0, LBB1_5 ;return

instead of:

        leal (%eax,%eax,2), %ecx
        movl %eax, %edx
        addl %edx, %edx
        addl L_flags2$non_lazy_ptr, %edx
        xorl %esi, %esi
LBB1_2: #bb
        movb $0, (%edx,%esi)
        movl %eax, %edi
        addl %esi, %edi
        addl %ecx, %esi
        cmpl $8192, %esi
        jg LBB1_5       #return

and:

        lis r2, ha16(L_flags2$non_lazy_ptr)
        lwz r2, lo16(L_flags2$non_lazy_ptr)(r2)
        mulli r3, r4, 3
        slwi r5, r4, 1
        li r6, 0
        add r2, r2, r5
LBB1_2: ;bb
        li r5, 0
        add r7, r3, r6
        stbx r5, r2, r6
        add r6, r4, r6
        cmpwi cr0, r7, 8192
        ble cr0, LBB1_2 ;bb

This speeds up Benchmarks/Shootout/sieve from 8.533s to 6.464s and
implements LoopStrengthReduce/var_stride_used_by_compare.ll

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31809 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNew testcase.
Chris Lattner [Fri, 17 Nov 2006 06:09:49 +0000 (06:09 +0000)]
New testcase.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31808 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUndo removal of the runtime libraries. While this may have been a bit
Reid Spencer [Fri, 17 Nov 2006 03:32:33 +0000 (03:32 +0000)]
Undo removal of the runtime libraries. While this may have been a bit
premature, these libraries will be going away for the 2.0 release. Other
arrangements for profiling, gc, etc. should be made in the next few months.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31807 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMore removal of std::cerr and DEBUG, replacing with DOUT instead.
Bill Wendling [Fri, 17 Nov 2006 02:09:07 +0000 (02:09 +0000)]
More removal of std::cerr and DEBUG, replacing with DOUT instead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31806 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoimplement a todo: change a map into a vector
Chris Lattner [Fri, 17 Nov 2006 01:52:23 +0000 (01:52 +0000)]
implement a todo: change a map into a vector

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31805 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd opcode to TargetInstrDescriptor.
Evan Cheng [Fri, 17 Nov 2006 01:46:27 +0000 (01:46 +0000)]
Add opcode to TargetInstrDescriptor.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31804 91177308-0d34-0410-b5e6-96231b3b80d8

17 years ago#ifndef NDEBUG the "if (Stream) ..." stuff.
Bill Wendling [Fri, 17 Nov 2006 01:43:48 +0000 (01:43 +0000)]
#ifndef NDEBUG the "if (Stream) ..." stuff.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31803 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd opcode to TargetInstrDescriptor.
Evan Cheng [Fri, 17 Nov 2006 01:36:01 +0000 (01:36 +0000)]
Add opcode to TargetInstrDescriptor.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31802 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdjusted the // comments so that doxygen picks them up.
Bill Wendling [Fri, 17 Nov 2006 01:13:12 +0000 (01:13 +0000)]
Adjusted the // comments so that doxygen picks them up.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31801 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoReplace std::cerr uses of the "DEBUG" macro with "DOUT" instead. Removes
Bill Wendling [Fri, 17 Nov 2006 00:50:36 +0000 (00:50 +0000)]
Replace std::cerr uses of the "DEBUG" macro with "DOUT" instead. Removes
a #include of iostream.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31800 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix typo
Chris Lattner [Fri, 17 Nov 2006 00:49:36 +0000 (00:49 +0000)]
fix typo

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31799 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdded "DOUT" macro. This is used as a replacement for the std::cerr
Bill Wendling [Fri, 17 Nov 2006 00:49:12 +0000 (00:49 +0000)]
Added "DOUT" macro. This is used as a replacement for the std::cerr
stream. It centralizes the use of std::cerr so that static c'tor/d'tors
aren't scattered around all over the place. The way to use it is like this:

       DOUT << "This is a status line: " << Var << "\n";

If "-debug" is specified, it will print. Otherwise, it'll not print. If
NDEBUG is defined, the DOUT does nothing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31798 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoimplicit_def_vrrc doesn't generate code.
Chris Lattner [Thu, 16 Nov 2006 23:49:52 +0000 (23:49 +0000)]
implicit_def_vrrc doesn't generate code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31797 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoNew test case.
Evan Cheng [Thu, 16 Nov 2006 23:38:21 +0000 (23:38 +0000)]
New test case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31796 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCorrect instructions for moving data between GR64 and SSE registers; also correct...
Evan Cheng [Thu, 16 Nov 2006 23:33:25 +0000 (23:33 +0000)]
Correct instructions for moving data between GR64 and SSE registers; also correct load i64 / store i64 from v2i64.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31795 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a potential bug: MOVPDI2DI, etc. are not copy instructions.
Evan Cheng [Thu, 16 Nov 2006 23:22:26 +0000 (23:22 +0000)]
Fix a potential bug: MOVPDI2DI, etc. are not copy instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31794 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoIn LLVM 2.0 we won't use the runtime libraries as llvm-gcc3 support will
Reid Spencer [Thu, 16 Nov 2006 23:17:27 +0000 (23:17 +0000)]
In LLVM 2.0 we won't use the runtime libraries as llvm-gcc3 support will
be dropped. This patch pertains to removing the runtime directory from LLVM.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31793 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoThis is a general clean up of the PowerPC ABI. Address several problems and
Jim Laskey [Thu, 16 Nov 2006 22:43:37 +0000 (22:43 +0000)]
This is a general clean up of the PowerPC ABI.  Address several problems and
bugs including making sure that the TOS links back to the previous frame,
that the maximum call frame size is not included twice when using frame
pointers, no longer growing the frame on calls, double storing of SP and
a cleaner/faster dynamic alloca.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31792 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix a regression that I introduced. stdu should scale the offset by 4
Chris Lattner [Thu, 16 Nov 2006 21:45:30 +0000 (21:45 +0000)]
fix a regression that I introduced.  stdu should scale the offset by 4
before printing it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31791 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAlign stubs on 4 byte boundary. This fixes 447.dealII.
Evan Cheng [Thu, 16 Nov 2006 20:13:34 +0000 (20:13 +0000)]
Align stubs on 4 byte boundary. This fixes 447.dealII.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31790 91177308-0d34-0410-b5e6-96231b3b80d8

17 years ago*** empty log message ***
Bill Wendling [Thu, 16 Nov 2006 20:11:33 +0000 (20:11 +0000)]
*** empty log message ***

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31789 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAllow target to specify alignment for function stub.
Evan Cheng [Thu, 16 Nov 2006 20:04:54 +0000 (20:04 +0000)]
Allow target to specify alignment for function stub.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31788 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMatch MachineCodeEmitter changes.
Evan Cheng [Thu, 16 Nov 2006 20:04:04 +0000 (20:04 +0000)]
Match MachineCodeEmitter changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31787 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUse a release version of bugpoint, if found. Include gccld passes.
Reid Spencer [Thu, 16 Nov 2006 18:32:47 +0000 (18:32 +0000)]
Use a release version of bugpoint, if found. Include gccld passes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31786 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd a statistic
Chris Lattner [Thu, 16 Nov 2006 18:13:49 +0000 (18:13 +0000)]
add a statistic

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31785 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCleaned up the document. Added "doc_code" divisions for code examples.
Bill Wendling [Thu, 16 Nov 2006 09:31:19 +0000 (09:31 +0000)]
Cleaned up the document. Added "doc_code" divisions for code examples.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31784 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDon't recompute getNumOperands for each iteration.
Bill Wendling [Thu, 16 Nov 2006 07:35:18 +0000 (07:35 +0000)]
Don't recompute getNumOperands for each iteration.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31783 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdded "removeRange", which takes and removes an entire LiveRange.
Bill Wendling [Thu, 16 Nov 2006 02:43:32 +0000 (02:43 +0000)]
Added "removeRange", which takes and removes an entire LiveRange.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31781 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdded a new method "CreateNewLiveInterval" which, given a list of
Bill Wendling [Thu, 16 Nov 2006 02:41:50 +0000 (02:41 +0000)]
Added a new method "CreateNewLiveInterval" which, given a list of
LiveRanges, creates a new LiveInterval from them. The LiveRanges should
have existed already in another LiveInterval, but removed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31780 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agomake this harder
Chris Lattner [Thu, 16 Nov 2006 01:22:52 +0000 (01:22 +0000)]
make this harder

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31779 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix broken encoding
Chris Lattner [Thu, 16 Nov 2006 01:01:28 +0000 (01:01 +0000)]
fix broken encoding

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31778 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoenable the branch folding pass for the JIT.
Chris Lattner [Thu, 16 Nov 2006 01:00:07 +0000 (01:00 +0000)]
enable the branch folding pass for the JIT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31777 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd ppc64 r+i stores with update.
Chris Lattner [Thu, 16 Nov 2006 00:57:19 +0000 (00:57 +0000)]
add ppc64 r+i stores with update.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31776 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd patterns for ppc32 preinc stores. ppc64 next.
Chris Lattner [Thu, 16 Nov 2006 00:41:37 +0000 (00:41 +0000)]
add patterns for ppc32 preinc stores.  ppc64 next.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31775 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoswitch these back to the 'bad old way'
Chris Lattner [Thu, 16 Nov 2006 00:33:34 +0000 (00:33 +0000)]
switch these back to the 'bad old way'

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31774 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix an incorrectly inverted condition.
Evan Cheng [Thu, 16 Nov 2006 00:08:20 +0000 (00:08 +0000)]
Fix an incorrectly inverted condition.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31773 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoChangeToRegister should clear IsImp bit.
Evan Cheng [Wed, 15 Nov 2006 23:55:03 +0000 (23:55 +0000)]
ChangeToRegister should clear IsImp bit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31772 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix ppc64 epilog bug.
Chris Lattner [Wed, 15 Nov 2006 23:35:30 +0000 (23:35 +0000)]
Fix ppc64 epilog bug.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31771 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoStop using isTwoAddress, switching to operand constraints instead.
Chris Lattner [Wed, 15 Nov 2006 23:24:18 +0000 (23:24 +0000)]
Stop using isTwoAddress, switching to operand constraints instead.

Tell the codegen emitter that specific operands are not to be encoded, fixing
JIT regressions w.r.t. pre-inc loads and stores (e.g. lwzu, which we generate
even when general preinc loads are not enabled).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31770 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemove the isTwoAddress property from the CodeGenInstruction class. It should
Chris Lattner [Wed, 15 Nov 2006 23:23:02 +0000 (23:23 +0000)]
Remove the isTwoAddress property from the CodeGenInstruction class.  It should
not be used for anything other than backwards compat constraint handling.

Add support for a new DisableEncoding property which contains a list of
registers that should not be encoded by the generated code emitter.  Convert
the codeemitter generator to use this, fixing some PPC JIT regressions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31769 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd a new field needed by the code emitter generator.
Chris Lattner [Wed, 15 Nov 2006 22:55:04 +0000 (22:55 +0000)]
add a new field needed by the code emitter generator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31768 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix typo pointed out by Bryan Adams
Chris Lattner [Wed, 15 Nov 2006 21:04:15 +0000 (21:04 +0000)]
Fix typo pointed out by Bryan Adams

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31766 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoProperly transfer kill / dead info.
Evan Cheng [Wed, 15 Nov 2006 20:58:11 +0000 (20:58 +0000)]
Properly transfer kill / dead info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31765 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoKill / dead info has been moved to MI's.
Evan Cheng [Wed, 15 Nov 2006 20:56:39 +0000 (20:56 +0000)]
Kill / dead info has been moved to MI's.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31764 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agocommuteInstruction should propagate kill / dead info.
Evan Cheng [Wed, 15 Nov 2006 20:56:03 +0000 (20:56 +0000)]
commuteInstruction should propagate kill / dead info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31763 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMatch live variable changes.
Evan Cheng [Wed, 15 Nov 2006 20:55:15 +0000 (20:55 +0000)]
Match live variable changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31762 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMinor updates.
Evan Cheng [Wed, 15 Nov 2006 20:54:29 +0000 (20:54 +0000)]
Minor updates.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31761 91177308-0d34-0410-b5e6-96231b3b80d8