Commit Graph

1229 Commits

Author SHA1 Message Date
Reid Spencer
0244099956 Add some output so the user is informed while they wait.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31700 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-13 16:08:51 +00:00
Reid Spencer
2fe47fccb9 Add -lstdc++ to the link line for C++ programs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31678 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-11 10:22:48 +00:00
Chris Lattner
f196839562 allow ptr_rc to explicitly appear in an instructions operand list, it doesn't
have to be a subpart of a complex operand.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31618 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-10 02:01:40 +00:00
Evan Cheng
a1fd6504aa Remove M_2_ADDR_FLAG.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31583 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-09 02:22:54 +00:00
Reid Spencer
dd2b95534f Don't run bugpoint if we can't find a misoptimization.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31582 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-09 01:47:04 +00:00
Reid Spencer
e4d8f33b0f Print a usage message if too few arguments to program.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31581 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-09 00:50:32 +00:00
Reid Spencer
28b7c7feab Add a utility script to find a mis-optimization problem. This sometimes
helps when bugpoint can't find the problem directly because it needs the
set of optimizations that cause the program to fail.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31580 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-09 00:26:17 +00:00
Evan Cheng
892aaf8d74 Divide select methods into groups by SelectionDAG node opcodes (ISD::ADD,
X86ISD::CMP, etc.) instead of SDNode names (add, x86cmp, etc). We now allow
multiple SDNodes to map to the same SelectionDAG node (e.g. store, indexed
store).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31575 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-08 23:01:03 +00:00
Evan Cheng
811731e340 Always pass the root node to ComplexPattern isel matching function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31570 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-08 20:31:10 +00:00
Chris Lattner
29434364dd emit TIED_TO correctly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31484 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-07 01:27:55 +00:00
Chris Lattner
d9a7f4db5f Mark predicate operands as such in operand info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31483 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-06 23:53:31 +00:00
Chris Lattner
a0cca4ae26 simplify the way operand flags and constraints are handled, making it easier
to extend.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31481 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-06 23:49:51 +00:00
Chris Lattner
a818e92f8b recognize ppc's blr instruction as predicated
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31480 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-06 21:44:54 +00:00
Chris Lattner
5fa39df5ba regenerate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31472 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-05 23:28:58 +00:00
Jeff Cohen
d41b30def3 Unbreak VC++ build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31464 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-05 19:31:28 +00:00
Evan Cheng
c51737f46f Clean up some code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31451 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-04 09:40:23 +00:00
Chris Lattner
efe9f4a3b6 Parse PredicateOperand's. When an instruction takes one, have the generated
isel fill in the instruction operands with the 'execute always' value
automatically.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31448 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-04 05:12:02 +00:00
Chris Lattner
dfdaeb276e First steps to getting PredicateOperand's to work. This handles instruction
and pat pattern definitions.  Codegen is not right for them yet.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31444 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-04 01:35:50 +00:00
Chris Lattner
d438b53e76 eliminate need for the NumMIOperands field in Operand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31432 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-03 23:45:17 +00:00
Reid Spencer
fa3e3b9427 Remove an unused variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31403 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-03 01:48:30 +00:00
Chris Lattner
64a8dddb73 silence warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31402 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-03 01:45:13 +00:00
Reid Spencer
8b9ea8099e Don't write out variables that are never used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31396 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-03 01:28:12 +00:00
Chris Lattner
9c5d4de837 silence warnings
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31392 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-03 01:11:05 +00:00
Reid Spencer
63fd6ad77b Revert last patch which causes tblgen to segfault (why, I'm not sure).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31383 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-02 21:07:40 +00:00
Reid Spencer
9ec4849ff6 For PR786:
Remove unused variables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31381 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-02 20:46:16 +00:00
Reid Spencer
3ed469ccd7 For PR786:
Turn on -Wunused and -Wno-unused-parameter. Clean up most of the resulting
fall out by removing unused variables. Remaining warnings have to do with
unused functions (I didn't want to delete code without review) and unused
variables in generated code. Maintainers should clean up the remaining
issues when they see them. All changes pass DejaGnu tests and Olden.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31380 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-02 20:25:50 +00:00
Evan Cheng
4c2b7a3808 Tied-to constraint must be op_with_larger_idx = op_with_smaller_idx or else throw an exception.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31361 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-01 23:03:11 +00:00
Evan Cheng
0db427bb2d Not meant to be checked in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31334 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-01 00:27:59 +00:00
Evan Cheng
e2ba897588 Add operand constraints to TargetInstrInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31333 91177308-0d34-0410-b5e6-96231b3b80d8
2006-11-01 00:27:05 +00:00
Reid Spencer
93c456c4bd 80 cols fix.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31050 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-19 15:24:04 +00:00
Evan Cheng
13e9e9c235 Passing isel root and use operands to ComplexPattern functions, these should do the usual load folding checks as well.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30972 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-16 06:33:44 +00:00
Evan Cheng
ce1381afd9 When checking if a load can be folded, we check if there is any non-direct
way to reach the load via any nodes that would be folded. Start from the
root of the matched sub-tree.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30956 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-14 08:30:15 +00:00
Evan Cheng
4f77616c28 Really remove dead nodes from isel queue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30923 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-12 23:18:52 +00:00
Evan Cheng
1fae00f1ad Use RemoveDeadNode to kill dead node.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30917 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-12 20:35:19 +00:00
Evan Cheng
4326ef582b Prior load folding check on chain operand was too strict. It requires the
chain operand to point to the load being folded. Now we relax this, traversing
up the chain, if it doesn't reach the load, then it's ok. We will create a
TokenFactor (of all the chain operands and the load's chain) to capture all
the control flow dependencies.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30897 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-12 02:08:53 +00:00
Evan Cheng
94b3040fef Added properties such as SDNPHasChain to ComplexPattern.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30890 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-11 21:02:01 +00:00
Chris Lattner
bcc3f0a61d regenerate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30888 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-11 18:13:09 +00:00
Chris Lattner
1ceb6c830f Add support for let expressions around an mdef. This implements a new part
of Regression/TableGen/MultiClass.td.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30887 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-11 18:12:44 +00:00
Chris Lattner
39e73f7c83 Special case tblgen generated code for patterns like (and X, 255) or (or X, 42).
The dag/inst combiners often 'simplify' the masked value based on whether
or not the bits are live or known zero/one.  This is good and dandy, but
often causes special case patterns to fail, such as alpha's CMPBGE pattern,
which looks like "(set GPRC:$RC, (setuge (and GPRC:$RA, 255), (and GPRC:$RB, 255)))".
Here the pattern for (and X, 255) should match actual dags like (and X, 254) if
the dag combiner proved that the missing bits are already zero (one for 'or').

For CodeGen/Alpha/cmpbge.ll:test2 for example, this results in:

        sll $16,1,$0
        cmpbge $0,$17,$0
        ret $31,($26),1

instead of:

        sll $16,1,$0
        and $0,254,$0
        and $17,255,$1
        cmpule $1,$0,$0
        ret $31,($26),1

... and requires no target-specific code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30871 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-11 04:05:55 +00:00
Chris Lattner
be8e72120d Split some code out into a new method. The generated code is exactly
identical, this is just a refactoring.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30868 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-11 03:35:34 +00:00
Evan Cheng
d3eea90a9b Predicate function on the node should be matched before its childrean' matching
code. This is especially important now matching ISD::LOAD also requires a
Predicate_Load call.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30845 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-09 21:02:17 +00:00
Chris Lattner
dc52f17a30 regenerate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30799 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-07 07:15:19 +00:00
Chris Lattner
85899b8b10 Bugfix: this allows multiclasses to have default arguments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30798 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-07 07:14:48 +00:00
Chris Lattner
90aa839c88 Fix more static dtor issues
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30725 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-04 21:52:35 +00:00
Jim Laskey
7a8efced36 Wrong directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30669 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-29 17:31:45 +00:00
Jim Laskey
ba9f0431f0 Fix search file for -release.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30647 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-28 18:45:11 +00:00
Jim Laskey
27b8ba088b Add support for -release-asserts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30646 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-28 17:49:20 +00:00
Chris Lattner
259bda48e2 This:
AggregateString += "\0\0";

Doesn't add two nuls to the AggregateString (for obvious reasons), which
broke the asmprinter when the first character of an asm string was not
literal text.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30625 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-27 16:44:09 +00:00
Chris Lattner
16f046a6ce Actually, name the method PrintSpecial to match other stuff in AsmPrinter.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30618 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-26 23:47:10 +00:00
Chris Lattner
1bf6361dfd Add support for ${:foo} syntax, where "foo" is passed into "printSpecial" and
has no associated operand.  This is useful for portably encoding stuff like
the comment character into an asm string.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30617 91177308-0d34-0410-b5e6-96231b3b80d8
2006-09-26 23:45:08 +00:00