1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-24 21:42:54 +02:00
Commit Graph

1273 Commits

Author SHA1 Message Date
Evan Cheng
34ce8e7297 Mark all (not just the first) predicate operand M_PREDICATE_OPERAND.
llvm-svn: 37061
2007-05-15 01:20:36 +00:00
Evan Cheng
0afaeec496 PredicateOperand related bug fix.
llvm-svn: 37060
2007-05-15 01:19:51 +00:00
Evan Cheng
f3da111f16 Remove duplicated line.
llvm-svn: 37040
2007-05-14 18:03:45 +00:00
Evan Cheng
41d7d13158 If a PredicateOperand has an empty ExecuteAlways field, treat it as if a normal operand for isel.
llvm-svn: 36946
2007-05-08 21:04:07 +00:00
Bill Wendling
dc82c5a195 Add an "implies" field to features. This indicates that, if the current
feature is set, then the features in the implied list should be set also.
The opposite is also enforced: if a feature in the implied list isn't set,
then the feature that owns that implies list shouldn't be set either.

llvm-svn: 36756
2007-05-04 20:38:40 +00:00
Lauro Ramos Venancio
4b7c032c6e Make my proxy happy.
llvm-svn: 36665
2007-05-03 14:05:07 +00:00
Nate Begeman
e32b8f8b4b A bit of feedback from Chris that I missed; error rather than asserting.
llvm-svn: 36619
2007-05-01 06:08:36 +00:00
Nate Begeman
767ee95d29 llvm bug #1350, parts 1, 2, and 3.
llvm-svn: 36618
2007-05-01 05:57:02 +00:00
Dan Gohman
eaa7a3889e Update a comment to reflect recent changes in the type system.
llvm-svn: 36486
2007-04-26 19:43:14 +00:00
Lauro Ramos Venancio
40822aaf24 bugfix: remember that ResNode was declared.
llvm-svn: 36477
2007-04-26 17:03:22 +00:00
Christopher Lamb
56768513ee Fix generation of certain scheduler itineraries.
llvm-svn: 36338
2007-04-22 09:04:24 +00:00
Evan Cheng
59dcbfde67 Bug fix; add super-registers sets.
llvm-svn: 36296
2007-04-21 00:55:29 +00:00
Lauro Ramos Venancio
bc32d90b46 Implement "general dynamic", "initial exec" and "local exec" TLS models for
X86 32 bits.

llvm-svn: 36283
2007-04-20 21:38:10 +00:00
Evan Cheng
842e2c48a0 Add sub-registers sets.
llvm-svn: 36278
2007-04-20 21:13:46 +00:00
Reid Spencer
f12ab5a55b For PR1328:
Don't assert everytime an intrinsic name isn't recognized. Instead, make
the assert optional when callin getIntrinsicID(). This allows the assembler
to handle invalid intrinsic names gracefully.

llvm-svn: 36120
2007-04-16 06:54:34 +00:00
Tanya Lattner
425b614986 Adding target triplet to be passed to database.
llvm-svn: 35958
2007-04-13 04:36:48 +00:00
Jeff Cohen
8d7aaa4843 Correctly report version of GCC used.
llvm-svn: 35866
2007-04-10 19:13:43 +00:00
Reid Spencer
543d051aad Update for PathWithStatus
llvm-svn: 35745
2007-04-07 19:49:35 +00:00
Reid Spencer
ed3e05f699 Terminate some lines that need to be.
llvm-svn: 35725
2007-04-07 05:20:07 +00:00
Reid Spencer
ed64d11c33 Reinstate the SVN capability without requiring Date::Parse. As before the
SVN Repository is only used if requested with -usesvn option otherwise it
uses CVS.

llvm-svn: 35721
2007-04-07 04:41:16 +00:00
Reid Spencer
22ecfc9cc9 Revert this until the Date::Parse module can be installed on the nightly
testers.

llvm-svn: 35657
2007-04-04 06:59:36 +00:00
Reid Spencer
fcebed346e Prepare for Subversion migration by implementing a -usesvn to tell the
script to to check out llvm and llvm-test from Subversion instead of CVS.
Without this option the script will continue to check out from CVS. To
specify the Subversion URL, set the SVNURL environment variable or pass
-svnurl followed by the URL. For now, -svnurl will default to Reid's
temporary (read-only, daily snapshot) SVN server. Try it out if you like!

llvm-svn: 35621
2007-04-03 08:28:44 +00:00
Reid Spencer
5b8b959d29 For PR1297:
Implement code generation for overloaded intrinsic functions. The basic
difference is that "actual" argument types must be provided when
constructing intrinsic names and types. Also, for recognition, only the
prefix is examined. If it matches, the suffix is assumed to match. The
suffix is checked by the Verifier, however.

llvm-svn: 35539
2007-04-01 07:20:02 +00:00
Bill Wendling
d764cbdfbb Add better support for keywords.
llvm-svn: 35386
2007-03-27 20:23:56 +00:00
Bill Wendling
a42484728c Add support for the v1i64 type. This makes better code for this:
#include <mmintrin.h>

extern __m64 C;

void baz(__v2si *A, __v2si *B)
{
  *A = C;
  _mm_empty();
}

We get this:

_baz:
        call "L1$pb"
"L1$pb":
        popl %eax
        movl L_C$non_lazy_ptr-"L1$pb"(%eax), %eax
        movq (%eax), %mm0
        movl 4(%esp), %eax
        movq %mm0, (%eax)
        emms
        ret

GCC gives us this:

_baz:
        pushl   %ebx
        call    L3
"L00000000001$pb":
L3:
        popl    %ebx
        subl    $8, %esp
        movl    L_C$non_lazy_ptr-"L00000000001$pb"(%ebx), %eax
        movl    (%eax), %edx
        movl    4(%eax), %ecx
        movl    16(%esp), %eax
        movl    %edx, (%eax)
        movl    %ecx, 4(%eax)
        emms
        addl    $8, %esp
        popl    %ebx
        ret

llvm-svn: 35351
2007-03-26 07:53:08 +00:00
Duncan Sands
9ee02c3f2e The -funcresolve and -raise options no longer exist.
llvm-svn: 35272
2007-03-22 21:06:50 +00:00
Evan Cheng
a54c20ca4e Recognize target instruction flag 'isReMaterializable'.
llvm-svn: 35159
2007-03-19 06:20:37 +00:00
Anton Korobeynikov
85d6c1ebad Refactoring of formal parameter flags. Enable properly use of
zext/sext/aext stuff.

llvm-svn: 35008
2007-03-07 16:25:09 +00:00
Anton Korobeynikov
6da6c8c48b Use new SDIselParamAttr enumeration. This removes "magick" constants
from formal attributes' flags processing.

llvm-svn: 34963
2007-03-06 08:12:33 +00:00
Chris Lattner
b7edd45f41 rename some CCActions
llvm-svn: 34724
2007-02-28 05:29:06 +00:00
Chris Lattner
2b616c0c0a implement CCPromoteToType
llvm-svn: 34720
2007-02-28 04:43:48 +00:00
Chris Lattner
35b160f990 reapply
llvm-svn: 34697
2007-02-27 22:08:27 +00:00
Chris Lattner
33bdd3ed53 *** empty log message ***
llvm-svn: 34696
2007-02-27 22:05:51 +00:00
Evan Cheng
06b5bb9888 Backing out
CodeGenTarget.cpp updated: 1.82 -> 1.83
Record.cpp updated: 1.55 -> 1.56
Record.h updated: 1.59 -> 1.60
TableGen.cpp updated: 1.47 -> 1.48
It's missing CallingConvEmitter.h

llvm-svn: 34693
2007-02-27 21:44:08 +00:00
Chris Lattner
5e2b19c767 initial support for calling convention generation, still unfinished.
llvm-svn: 34682
2007-02-27 20:43:37 +00:00
Chris Lattner
d01ebce896 emit an enum value for the # of target registers.
llvm-svn: 34624
2007-02-26 03:34:38 +00:00
Chris Lattner
ddb46d765a the lengths of the strings are known, just use memcmp
llvm-svn: 34321
2007-02-15 19:26:16 +00:00
Chris Lattner
5d0b16f797 Implement Function::getIntrinsicID without it needing to call Value::getName,
which allocates a string.  This speeds up instcombine on 447.dealII by 5%.

llvm-svn: 34318
2007-02-15 19:17:16 +00:00
Reid Spencer
e7ff3305d6 For PR1195:
Change use of "packed" term to "vector" in comments, strings, variable
names, etc.

llvm-svn: 34300
2007-02-15 03:39:18 +00:00
Reid Spencer
55e4e98a2a For PR1195:
Rename PackedType -> VectorType, ConstantPacked -> ConstantVector, and
PackedTyID -> VectorTyID. No functional changes.

llvm-svn: 34293
2007-02-15 02:26:10 +00:00
Chris Lattner
a4853a3340 remove obsolete path
llvm-svn: 34273
2007-02-14 07:39:35 +00:00
Jim Laskey
c27aed3dc0 Automatically generating intrinsic declarations from Dan Gohman. Modified
to construct FunctionType in separate function, and, have getDeclaration
return a Function instead of a Constant.

llvm-svn: 34008
2007-02-07 20:38:26 +00:00
Reid Spencer
9f642b1776 Set the new NO_INSTALL flag for build-only tools.
llvm-svn: 33967
2007-02-06 18:51:28 +00:00
Jim Laskey
52c07ebe15 Error check and eliminate unnecessary value.
llvm-svn: 33966
2007-02-06 18:30:58 +00:00
Jim Laskey
4fd5f28165 Regenerate.
llvm-svn: 33965
2007-02-06 18:20:07 +00:00
Jim Laskey
595ef8f868 Deemed too cute to live.
llvm-svn: 33964
2007-02-06 18:19:44 +00:00
Jim Laskey
bc1fb68dc6 Regenerate.
llvm-svn: 33963
2007-02-06 18:03:31 +00:00
Jim Laskey
7d5ddeb668 Support var arg intrinsics.
llvm-svn: 33962
2007-02-06 18:02:54 +00:00
Reid Spencer
b32cc501f5 Use opt to generate the list of passes to run.
llvm-svn: 33903
2007-02-05 06:10:19 +00:00
Jim Laskey
9d10e4e1fe Make the constant honest.
llvm-svn: 33557
2007-01-26 23:00:54 +00:00
Jim Laskey
1bab68f592 Files missing from LABEL check in.
llvm-svn: 33539
2007-01-26 17:29:20 +00:00
Chris Lattner
135e17b756 Make tblgen error more useful. Patch by B. Scott Michel
llvm-svn: 33295
2007-01-17 07:45:12 +00:00
Reid Spencer
ad67732a72 Fix this tool for use on Darwin which requires the file to come after the
commands. Linux is more forgiving.

Patch by Gordon Henriksen. Thanks, Gordon!

llvm-svn: 33285
2007-01-17 03:38:22 +00:00
Reid Spencer
bbcedcf45d Join two lines that caused awk to squak on some platforms.
llvm-svn: 33274
2007-01-16 22:41:12 +00:00
Reid Spencer
373d2bccea For PR1064:
Implement the arbitrary bit-width integer feature. The feature allows
integers of any bitwidth (up to 64) to be defined instead of just 1, 8,
16, 32, and 64 bit integers.

This change does several things:
1. Introduces a new Derived Type, IntegerType, to represent the number of
   bits in an integer. The Type classes SubclassData field is used to
   store the number of bits. This allows 2^23 bits in an integer type.
2. Removes the five integer Type::TypeID values for the 1, 8, 16, 32 and
   64-bit integers. These are replaced with just IntegerType which is not
   a primitive any more.
3. Adjust the rest of LLVM to account for this change.

Note that while this incremental change lays the foundation for arbitrary
bit-width integers, LLVM has not yet been converted to actually deal with
them in any significant way. Most optimization passes, for example, will
still only deal with the byte-width integer types.  Future increments
will rectify this situation.

llvm-svn: 33113
2007-01-12 07:05:14 +00:00
Reid Spencer
9963189831 Put in some needed \ at the end of lines!!!
llvm-svn: 33070
2007-01-11 06:51:56 +00:00
Reid Spencer
0e73246942 For PR950:
Convert signed integer types to signless.

llvm-svn: 32786
2006-12-31 05:50:28 +00:00
Reid Spencer
142f27dfd4 Remove some clutter and make it keep going instead of stopping at the
first difference.

llvm-svn: 32645
2006-12-18 00:37:37 +00:00
Jim Laskey
023e836c5b Ignore entries with blank names.
llvm-svn: 32491
2006-12-12 20:55:58 +00:00
Jim Laskey
b039172d58 Rollback changes to take a different tack.
llvm-svn: 32488
2006-12-12 19:26:50 +00:00
Jim Laskey
8a5cea99ed Honor the command line specification for machine type.
llvm-svn: 32483
2006-12-12 16:07:33 +00:00
Reid Spencer
d5ba7eadcc Provide a script that can track down which optimization pass causes
different code to be produced between two llvm builds that differe slightly.
This is useful in tracking down mis-optimization bugs.

llvm-svn: 32435
2006-12-11 17:42:12 +00:00
Reid Spencer
f2048c9717 Allow the input of the test program to be specified.
Don't generate the reference output for each comparison.

llvm-svn: 32395
2006-12-09 04:42:33 +00:00
Reid Spencer
6254d95a45 Add the -ldl library option.
llvm-svn: 32369
2006-12-08 18:58:38 +00:00
Bill Wendling
f13d78d3b8 What should be the last unnecessary <iostream>s in the library.
llvm-svn: 32333
2006-12-07 22:21:48 +00:00
Evan Cheng
7eb095f346 Match TargetInstrInfo changes.
llvm-svn: 32107
2006-12-01 22:57:41 +00:00
Reid Spencer
5605ecd40d Only show the first few lines of difference.
llvm-svn: 31901
2006-11-25 04:07:06 +00:00
Reid Spencer
a10284b03f Add an option to enable lli (interpreter mode) testing.
llvm-svn: 31899
2006-11-24 20:34:16 +00:00
Reid Spencer
336bf8354e Stop early if there is no mis-optimization.
llvm-svn: 31893
2006-11-22 03:46:45 +00:00
Chris Lattner
670eb9da78 Fix PR1001, patch by Nikhil Patil!
llvm-svn: 31880
2006-11-20 18:54:33 +00:00
Reid Spencer
ce839fd108 Make the awk filter print out which files its eliminating.
llvm-svn: 31851
2006-11-18 18:30:18 +00:00
Reid Spencer
e52a08d399 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.

llvm-svn: 31850
2006-11-18 18:02:30 +00:00
Reid Spencer
e5c34cf38e Provide a list of gccld optimization switches.
llvm-svn: 31849
2006-11-18 17:14:09 +00:00
Evan Cheng
e1ca976ce4 Add opcode to TargetInstrDescriptor.
llvm-svn: 31804
2006-11-17 01:46:27 +00:00
Reid Spencer
a9ff1e4cec Use a release version of bugpoint, if found. Include gccld passes.
llvm-svn: 31786
2006-11-16 18:32:47 +00:00
Chris Lattner
4a2af4e374 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.

llvm-svn: 31769
2006-11-15 23:23:02 +00:00
Chris Lattner
efcd65f335 ADd support for adding constraints to suboperands
llvm-svn: 31748
2006-11-15 02:38:17 +00:00
Chris Lattner
1c86ab0ffe restore some 'magic' code that I removed: it is needed. Add comments explaining
why.

llvm-svn: 31743
2006-11-14 22:17:10 +00:00
Chris Lattner
927a143285 minimal hack to get patterns whose result type is iPTR to be selected.
llvm-svn: 31742
2006-11-14 21:50:27 +00:00
Chris Lattner
1cbfe99b60 remove some dead code
llvm-svn: 31740
2006-11-14 21:41:35 +00:00
Chris Lattner
7e5cbf9ee0 Add support for nodes that return iPTR.
llvm-svn: 31739
2006-11-14 21:32:01 +00:00
Chris Lattner
03cc8c84ef changes to get ptr_rc to be accepted in patterns. This is needed for ppc preinc
stores.

llvm-svn: 31738
2006-11-14 21:18:40 +00:00
Chris Lattner
796d72272b Fix a bug handling nodes with variable arguments. The code was fixed to assume
that there were two input operands before the variable operand portion.  This
*happened* to be true for all call instructions, which took a chain and a
destination, but was not true for the PPC BCTRL instruction, whose destination
is implicit.

Making this code more general allows elimination of the custom selection logic
for BCTRL.

llvm-svn: 31732
2006-11-14 18:41:38 +00:00
Reid Spencer
c7d7e1ed9c Add some output so the user is informed while they wait.
llvm-svn: 31700
2006-11-13 16:08:51 +00:00
Reid Spencer
6c8c157f98 Add -lstdc++ to the link line for C++ programs.
llvm-svn: 31678
2006-11-11 10:22:48 +00:00
Chris Lattner
6836cbaf9d allow ptr_rc to explicitly appear in an instructions operand list, it doesn't
have to be a subpart of a complex operand.

llvm-svn: 31618
2006-11-10 02:01:40 +00:00
Evan Cheng
8743c67826 Remove M_2_ADDR_FLAG.
llvm-svn: 31583
2006-11-09 02:22:54 +00:00
Reid Spencer
872f4226e4 Don't run bugpoint if we can't find a misoptimization.
llvm-svn: 31582
2006-11-09 01:47:04 +00:00
Reid Spencer
1d8fddc5b0 Print a usage message if too few arguments to program.
llvm-svn: 31581
2006-11-09 00:50:32 +00:00
Reid Spencer
dbb1ac36fa 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.

llvm-svn: 31580
2006-11-09 00:26:17 +00:00
Evan Cheng
6921c1c0a7 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).

llvm-svn: 31575
2006-11-08 23:01:03 +00:00
Evan Cheng
42fb21c3c5 Always pass the root node to ComplexPattern isel matching function.
llvm-svn: 31570
2006-11-08 20:31:10 +00:00
Chris Lattner
c1d27af4b8 emit TIED_TO correctly
llvm-svn: 31484
2006-11-07 01:27:55 +00:00
Chris Lattner
908ea22022 Mark predicate operands as such in operand info.
llvm-svn: 31483
2006-11-06 23:53:31 +00:00
Chris Lattner
e1960fc065 simplify the way operand flags and constraints are handled, making it easier
to extend.

llvm-svn: 31481
2006-11-06 23:49:51 +00:00
Chris Lattner
04b6336b73 recognize ppc's blr instruction as predicated
llvm-svn: 31480
2006-11-06 21:44:54 +00:00
Chris Lattner
97e9292cf3 regenerate
llvm-svn: 31472
2006-11-05 23:28:58 +00:00
Jeff Cohen
e1003da1a2 Unbreak VC++ build.
llvm-svn: 31464
2006-11-05 19:31:28 +00:00
Evan Cheng
8e65006b5e Clean up some code.
llvm-svn: 31451
2006-11-04 09:40:23 +00:00
Chris Lattner
8dac4564af Parse PredicateOperand's. When an instruction takes one, have the generated
isel fill in the instruction operands with the 'execute always' value
automatically.

llvm-svn: 31448
2006-11-04 05:12:02 +00:00
Chris Lattner
f7ad33f01b First steps to getting PredicateOperand's to work. This handles instruction
and pat pattern definitions.  Codegen is not right for them yet.

llvm-svn: 31444
2006-11-04 01:35:50 +00:00
Chris Lattner
5eca521156 eliminate need for the NumMIOperands field in Operand.
llvm-svn: 31432
2006-11-03 23:45:17 +00:00
Reid Spencer
da581ac715 Remove an unused variable.
llvm-svn: 31403
2006-11-03 01:48:30 +00:00
Chris Lattner
f6b840a1ae silence warning
llvm-svn: 31402
2006-11-03 01:45:13 +00:00
Reid Spencer
d41f385ed9 Don't write out variables that are never used.
llvm-svn: 31396
2006-11-03 01:28:12 +00:00
Chris Lattner
71ce2c5de5 silence warnings
llvm-svn: 31392
2006-11-03 01:11:05 +00:00
Reid Spencer
01f5071a4d Revert last patch which causes tblgen to segfault (why, I'm not sure).
llvm-svn: 31383
2006-11-02 21:07:40 +00:00
Reid Spencer
0d18610609 For PR786:
Remove unused variables.

llvm-svn: 31381
2006-11-02 20:46:16 +00:00
Reid Spencer
4bafa71dc1 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.

llvm-svn: 31380
2006-11-02 20:25:50 +00:00
Evan Cheng
05d73e7209 Tied-to constraint must be op_with_larger_idx = op_with_smaller_idx or else throw an exception.
llvm-svn: 31361
2006-11-01 23:03:11 +00:00
Evan Cheng
a585562f95 Not meant to be checked in.
llvm-svn: 31334
2006-11-01 00:27:59 +00:00
Evan Cheng
c566892bd5 Add operand constraints to TargetInstrInfo.
llvm-svn: 31333
2006-11-01 00:27:05 +00:00
Reid Spencer
bddf9a66ec 80 cols fix.
llvm-svn: 31050
2006-10-19 15:24:04 +00:00
Evan Cheng
f872538d4b Passing isel root and use operands to ComplexPattern functions, these should do the usual load folding checks as well.
llvm-svn: 30972
2006-10-16 06:33:44 +00:00
Evan Cheng
513dc7ed5f 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.

llvm-svn: 30956
2006-10-14 08:30:15 +00:00
Evan Cheng
c7283044d1 Really remove dead nodes from isel queue.
llvm-svn: 30923
2006-10-12 23:18:52 +00:00
Evan Cheng
5ff49d9410 Use RemoveDeadNode to kill dead node.
llvm-svn: 30917
2006-10-12 20:35:19 +00:00
Evan Cheng
65264c811f 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.

llvm-svn: 30897
2006-10-12 02:08:53 +00:00
Evan Cheng
7a185e0164 Added properties such as SDNPHasChain to ComplexPattern.
llvm-svn: 30890
2006-10-11 21:02:01 +00:00
Chris Lattner
461eba5c63 regenerate
llvm-svn: 30888
2006-10-11 18:13:09 +00:00
Chris Lattner
0c0f2eacfc Add support for let expressions around an mdef. This implements a new part
of Regression/TableGen/MultiClass.td.

llvm-svn: 30887
2006-10-11 18:12:44 +00:00
Chris Lattner
822d1b259e 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.

llvm-svn: 30871
2006-10-11 04:05:55 +00:00
Chris Lattner
ad597308ad Split some code out into a new method. The generated code is exactly
identical, this is just a refactoring.

llvm-svn: 30868
2006-10-11 03:35:34 +00:00
Evan Cheng
084d415941 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.

llvm-svn: 30845
2006-10-09 21:02:17 +00:00
Chris Lattner
b007ac9ecf regenerate
llvm-svn: 30799
2006-10-07 07:15:19 +00:00
Chris Lattner
b5b2e0340e Bugfix: this allows multiclasses to have default arguments.
llvm-svn: 30798
2006-10-07 07:14:48 +00:00
Chris Lattner
d55928d5f6 Fix more static dtor issues
llvm-svn: 30725
2006-10-04 21:52:35 +00:00
Jim Laskey
dca41cb87b Wrong directory.
llvm-svn: 30669
2006-09-29 17:31:45 +00:00
Jim Laskey
654a319cca Fix search file for -release.
llvm-svn: 30647
2006-09-28 18:45:11 +00:00
Jim Laskey
b9f4391b46 Add support for -release-asserts.
llvm-svn: 30646
2006-09-28 17:49:20 +00:00
Chris Lattner
4aa2739696 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.

llvm-svn: 30625
2006-09-27 16:44:09 +00:00
Chris Lattner
7c98cc2aab Actually, name the method PrintSpecial to match other stuff in AsmPrinter.h
llvm-svn: 30618
2006-09-26 23:47:10 +00:00
Chris Lattner
10e06fa138 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.

llvm-svn: 30617
2006-09-26 23:45:08 +00:00
Chris Lattner
86f1992481 don't allow 'imm' or specific imms, like '1' on the LHS of a binop.
This shrinks X86GenDAGISel by ~330 lines.

llvm-svn: 30574
2006-09-21 20:46:13 +00:00
Chris Lattner
28d7124afb Fit to 80 columns.
llvm-svn: 30572
2006-09-21 18:28:27 +00:00
Jim Laskey
a46690e7de Trim the home directory from the dejagnu test
llvm-svn: 30519
2006-09-20 09:20:22 +00:00
Evan Cheng
c5be7540d2 Allow PatFrag to be a leaf node.
llvm-svn: 30498
2006-09-19 19:08:04 +00:00
Evan Cheng
f020ff9440 Add result of a Xform to isel queue.
llvm-svn: 30497
2006-09-19 18:40:15 +00:00
Chris Lattner
87d05ea43b If multiple predicates are listed, they must all pass
llvm-svn: 30476
2006-09-19 00:41:36 +00:00
Chris Lattner
7498e29ca4 There!
llvm-svn: 30473
2006-09-18 22:41:07 +00:00
Chris Lattner
b54881691d Fix Regression/TableGen/2006-09-18-LargeInt.td
llvm-svn: 30472
2006-09-18 22:28:27 +00:00
Jim Laskey
86b2204935 Switching to NewNightlyTest.php
llvm-svn: 30394
2006-09-15 17:03:36 +00:00
Chris Lattner
8b65094e0f Relax this check.
llvm-svn: 30381
2006-09-14 23:54:24 +00:00
Jim Laskey
eda9265efc No longer used, and confuses maintainers
llvm-svn: 30248
2006-09-11 16:02:58 +00:00
Evan Cheng
f82eb13e3b 1) With X86 lowering change, the following can no longer happen since
the branch's chain is also produced by cmp.
          [ch, r : ld]
             ^ ^
             | |
      [XX]--/   \- [flag : cmp]
       ^             ^
       |             |
       \---[br flag]-

Remove an isel check which prevents loads from being folded into cmp / test
instructions.

2) Whenever possible, delete a selected node to allow more load folding
opportunities. Note not all nodes can be deleted after it has been
selected. Some may have simply morphed; some have not changed at all (e.g.
EntryToken).

llvm-svn: 30242
2006-09-11 02:24:43 +00:00
Evan Cheng
9d17d65cc4 Generated isel should favors explicit constant operand (+2) over an operand with a predicate (+1).
llvm-svn: 30180
2006-09-08 07:26:39 +00:00
Chris Lattner
382ed3f1d9 Fix JIT encoding of two-addr instructions.
llvm-svn: 30111
2006-09-05 03:01:52 +00:00
Chris Lattner
59a4d8dfcd Fix a long-standing wart in the code generator: two-address instruction lowering
actually *removes* one of the operands, instead of just assigning both operands
the same register.  This make reasoning about instructions unnecessarily complex,
because you need to know if you are before or after register allocation to match
up operand #'s with the target description file.

Changing this also gets rid of a bunch of hacky code in various places.

This patch also includes changes to fold loads into cmp/test instructions in
the X86 backend, along with a significant simplification to the X86 spill
folding code.

llvm-svn: 30108
2006-09-05 02:12:02 +00:00
Chris Lattner
997e7e3d45 Make sure to clear CurDefmPrefix = 0, otherwise stuff after a defm won't
parse right.  This fixes TableGen/MultiClass.td

llvm-svn: 30037
2006-09-01 22:07:27 +00:00
Chris Lattner
4c597bb380 fix an assertion with multidefs. Def inside of multiclasses don't need to
be complete.

llvm-svn: 30034
2006-09-01 21:59:03 +00:00
Chris Lattner
67e2187a04 regenerate
llvm-svn: 30029
2006-09-01 21:14:42 +00:00
Chris Lattner
948354e18e Add often-requested support for defining "multiclasses" which can be instantiated.
This allows you to define multiple definitions with one line, encouraging
more .td file factoring.

llvm-svn: 30027
2006-09-01 21:13:49 +00:00
Evan Cheng
77da6a9609 Issue cvs co with -P option to prune empty directories. Remove the unnecessary
update stage.

llvm-svn: 29955
2006-08-29 18:01:18 +00:00
Reid Spencer
3e62da9ed1 Add virtual methods to all subclasses so they are not overloaded.
llvm-svn: 29930
2006-08-28 00:12:25 +00:00
Chris Lattner
7890c00e2c Use compiler.h instead of hand rolling our own macro
llvm-svn: 29913
2006-08-27 13:16:24 +00:00
Evan Cheng
10a7268b85 Do not emit getTargetNode() and SelectNodeTo() which takes more than 3
SDOperand arguments. Use the variants which take an array and number instead.

llvm-svn: 29906
2006-08-27 08:11:28 +00:00
Evan Cheng
1c3d571e4b SelectNodeTo now returns a SDNode*.
llvm-svn: 29901
2006-08-26 08:00:10 +00:00
Evan Cheng
36c38110c4 Minor getCopyToReg() call change.
llvm-svn: 29900
2006-08-26 07:39:28 +00:00
Evan Cheng
2db7799507 Select() no longer require Result operand by reference.
llvm-svn: 29898
2006-08-26 05:34:46 +00:00
Evan Cheng
930bc5331d Remove dead code.
llvm-svn: 29897
2006-08-26 01:34:15 +00:00
Evan Cheng
2cc7e2ce0c A bit more clean up.
llvm-svn: 29893
2006-08-26 01:02:19 +00:00
Evan Cheng
b96b719724 - Clean up tablegen dag isel generator code.
- Clean up the code generated by tablegen:
  * AddToISelQueue now takes one argument.
  * ComplexPattern matching condition can now be shared.
  * Eliminate passing unnecessary arguments to emit routines.
  * Eliminate some unneeded SDOperand declarations in select routines.
  * Other minor clean ups.
- This reduces foot print slightly: X86ISelDAGToDAG.o is reduced from 971k
  to 823k.

llvm-svn: 29892
2006-08-26 00:59:04 +00:00
Patrick Jenkins
6c18e5e7b7 Corrected an error that was introduced yesterday that caused the GCC
version to be left blank if the build failed.

Also corrected a problem where if the build failed the nightly tester
would still try to read the results of the Dejagnutests log even
though it didnt exist.

llvm-svn: 29829
2006-08-22 18:11:19 +00:00
Patrick Jenkins
d3d74dec7b The new nightly tester should stop outputing a message stating the
testresults directory is not present unless the script is run as verbose.

llvm-svn: 29797
2006-08-21 20:45:57 +00:00
Patrick Jenkins
253fe71c46 These changes reflect the changes in the database for how tests are stored
and bring the handing of dejagnu tests into compliance with this new scheme.

llvm-svn: 29772
2006-08-18 18:00:21 +00:00
Patrick Jenkins
8a8893471f Changing the format dejagnu tests are submitted. We used to only submit multisource information for pass fail. Now we submit all pass/fail test information. This should fix the issue where some results were not being reported.
llvm-svn: 29757
2006-08-17 22:11:03 +00:00
Patrick Jenkins
de01f0e1c2 My last commit added some experimental features I have been working on. This commit rolls those back.
llvm-svn: 29738
2006-08-16 22:32:20 +00:00
Patrick Jenkins
ca80c08de2 Changed the call to countloc.sh so that the correct topdirectory of the llvm build is set.
llvm-svn: 29736
2006-08-16 22:18:41 +00:00
Evan Cheng
7fb75bbc8d SelectNodeTo() may return a SDOperand that is different from the input.
llvm-svn: 29726
2006-08-16 07:30:09 +00:00
Chris Lattner
9611f01574 The generated runloop shouldn't require Select to update 'Result'. In fact
we'd like to remove result entirely.

llvm-svn: 29713
2006-08-15 23:42:26 +00:00
Chris Lattner
3771e3035f allow Select to return the node being selected if RAU isn't needed.
llvm-svn: 29712
2006-08-15 23:27:50 +00:00
Reid Spencer
452be375b7 Simplify this a little bit.
llvm-svn: 29695
2006-08-15 03:50:10 +00:00
Reid Spencer
9d1b18e36e This script takes arguments so remove the check for number of arguments,
just check the first arg to see if its -topdir.

llvm-svn: 29694
2006-08-15 03:48:22 +00:00
Reid Spencer
7f2ce5b626 Make all tools that use llvmdo have a -topdir option that allows the top
source dir for LLVM to be specified explicitly. This removes the dependency
on the llvm-config script. If the option is not given, then the scripts use
llvm-config which should be both built and in the PATH. This arrangement
provides a useful default for most developers but also allows the nightly
tester to execute countloc.sh before llvm-config is built and without
altering the PATH.

llvm-svn: 29663
2006-08-14 18:49:05 +00:00
Patrick Jenkins
08a5429d76 Added some comments to clarify code around sub TestDirectory
llvm-svn: 29658
2006-08-14 16:07:14 +00:00
Reid Spencer
accb07b254 1. fix bug by ensuring we start at the llvm source root.
2. make use of the -code-only option on llvmdo
3. Add some debug print statements to find #1

llvm-svn: 29655
2006-08-13 19:03:06 +00:00
Reid Spencer
e309e97cbd Count the documentation. Otherwise we take a 30,000 hit in the LOC on the
nightly test graph. And, documentation is important.

llvm-svn: 29654
2006-08-13 18:59:40 +00:00
Reid Spencer
283f511a60 Use the new -code-only option to llvmdo so that we only count things that
are considered to be code. This will give a drop in the LOC count on the
nightly testers, but it is more accurate than previous estimates.

llvm-svn: 29653
2006-08-13 18:29:21 +00:00
Reid Spencer
08a7d6413f Add a -code-only option which restricts llvmdo to visiting just those
files that are considered to be code. Documentation is excluded.

llvm-svn: 29652
2006-08-13 18:28:27 +00:00
Reid Spencer
24b0f0757f Changes for LLVM coding standard compliance:
1. Remove tabs
  2. Wrap to 80 columns
  3. Put spaces between "if" or "elsif" and expression
  4. Put { on same line as if statement.
  5. Make indentation be 2 spaces.
Functionality change:
  Run utils/countloc.sh after the build is done. This is necessary because
  that script now uses llvm-config to find the top src directory.

llvm-svn: 29651
2006-08-13 09:53:02 +00:00
Reid Spencer
21f214fa6b Lexer.cpp is a generated file both in lib/AsmParser and projects/Stacker
so we remove it from being counted.

llvm-svn: 29641
2006-08-11 23:58:58 +00:00
Reid Spencer
69ce7523c9 Weed out some cruft and add in some missing extensions.
llvm-svn: 29638
2006-08-11 23:51:05 +00:00
Reid Spencer
89414d003f Weed out cruft that should not be counted and add in extensions we
previously missed.

llvm-svn: 29637
2006-08-11 23:50:27 +00:00
Patrick Jenkins
2428c13b4e Added two flags (-submit-server and -submit-script) which allow the user to specify where the test results are submitted too. If these are not specified they default to the LLVM.org server.
llvm-svn: 29633
2006-08-11 23:02:09 +00:00
Reid Spencer
8966f69927 Make this script not care where it is run from by getting the llvm src
root from the llvm-config script.

llvm-svn: 29632
2006-08-11 21:55:31 +00:00
Reid Spencer
c8a4b914d4 Make llvmdo and llvmgrep invulnerable to where they are run from by getting
the llvm source root from the llvm-config command. The dependency now is
that the correct llvm-config command is in the path. For most developers
this is the case.

llvm-svn: 29630
2006-08-11 21:53:27 +00:00
Reid Spencer
15ed5aec07 Clean up the HTML output. Add a -filedetails option to report the number of
lines contributed by each user to each file.

llvm-svn: 29624
2006-08-11 20:44:17 +00:00
Reid Spencer
d06abd82a2 Remove blank line at end of file, removing test user "foo" from CVS history.
llvm-svn: 29623
2006-08-11 19:42:11 +00:00
Reid Spencer
8746dd4a70 Drop the -details option, it was broken. If you want to know about a
particular directory, just pass that directory to the script. Also, clean
up the HTML output, put list of skipped dirs at the end, and make a few
other minor improvements.

llvm-svn: 29620
2006-08-11 18:36:55 +00:00
Evan Cheng
963d61dc86 Use SmallVector instead.
llvm-svn: 29619
2006-08-11 18:33:41 +00:00
Evan Cheng
5950c56f73 - Prevent some functions from being inlined to eliminate the code size bloat
introduced by previous commit.
- SelectCode now returns a SDNode*. If it is not null, the selected node
  produces the same number of results as the input node. The seletion loop
  is responsible for calling ReplaceAllUsesWith() to replace the input node
  with the output target node. For other cases, e.g. when load is folded,
  the selection code is responsible for calling ReplaceAllUsesOfValueWith()
  and SelectCode returns NULL.
- Other clean ups.

llvm-svn: 29602
2006-08-11 08:59:35 +00:00
Reid Spencer
99112f11ec Fix a comment.
llvm-svn: 29590
2006-08-09 19:40:13 +00:00
Chris Lattner
947ac60771 Revert previous patch
llvm-svn: 29585
2006-08-09 16:44:44 +00:00
Tanya Lattner
3707c6e4e3 Reverting back to original 1.8 version so I can manually merge in patch.
llvm-svn: 29584
2006-08-09 16:41:21 +00:00
Evan Cheng
3a9bcad4c4 Merge some NightlyTest.pl changes.
llvm-svn: 29579
2006-08-09 05:45:12 +00:00
Chris Lattner
7b1362fa52 Start eliminating temporary vectors used to create DAG nodes. Instead, pass
in the start of an array and a count of operands where applicable.  In many
cases, the number of operands is known, so this static array can be allocated
on the stack, avoiding the heap.  In many other cases, a SmallVector can be
used, which has the same benefit in the common cases.

I updated a lot of code calling getNode that takes a vector, but ran out of
time.  The rest of the code should be updated, and these methods should be
removed.

We should also do the same thing to eliminate the methods that take a
vector of MVT::ValueTypes.

It would be extra nice to convert the dagiselemitter to avoid creating vectors
for operands when calling getTargetNode.

llvm-svn: 29566
2006-08-08 02:23:42 +00:00
Patrick Jenkins
b2c90ef2c6 Removed unneccesary output from nightly tester
llvm-svn: 29565
2006-08-08 02:03:53 +00:00
Evan Cheng
c6627fc5d7 Making TableGen'd instruction selection code non-recursive. This fixes PR805.
llvm-svn: 29548
2006-08-07 22:17:58 +00:00
Patrick Jenkins
9ca71b7632 Reinstated the sending of a list of all dejagnutests run. Also fixed a rather embarresing error introduced during version 1.41 where i commented out the actual sending of the data to the results server.
llvm-svn: 29538
2006-08-07 01:54:37 +00:00
Patrick Jenkins
e9d04e428a no longer sending the list of all dejagnu tests because it is too big at the present time
llvm-svn: 29537
2006-08-06 21:47:43 +00:00