Commit Graph

48707 Commits

Author SHA1 Message Date
Steve Naroff 6b40b8ab27 Add RewriteTest.cpp to VC++ project.
llvm-svn: 57592
2008-10-15 19:49:15 +00:00
Steve Naroff e17f52fc23 Tighten up blocks rewriter to handle casts and some other interesting cases.
This fixes <rdar://problem/6289007> clang block rewriter: ^ in cast is not rewritten.

llvm-svn: 57591
2008-10-15 18:38:58 +00:00
Bill Wendling f998a65980 Testcase for PR1638.
llvm-svn: 57590
2008-10-15 18:27:15 +00:00
Dan Gohman c7e00ba60f Fix a missing space after the return type in invoke statements.
This fixes PR2894.

llvm-svn: 57589
2008-10-15 18:02:08 +00:00
Daniel Dunbar a0dcd78081 Use BatchEmitOwnedPtrs for writing multiple child exprs, per review.
Also added serialization support to OverloadExpr.

llvm-svn: 57588
2008-10-15 17:52:29 +00:00
Chris Lattner e0230f4646 Fix PR2115 by doxygenating Use more, and make some more methods private.
llvm-svn: 57587
2008-10-15 16:56:14 +00:00
Chris Lattner 9b83197b76 move PR1941 here.
llvm-svn: 57586
2008-10-15 16:33:52 +00:00
Bill Wendling 2d362a77c8 Unbreak the build. Please test out the proper fix for this by compiling LLVM
with the build directory different from the source directory.

llvm-svn: 57583
2008-10-15 16:20:13 +00:00
Chris Lattner 6d275fd6e1 move PR1604 here.
llvm-svn: 57582
2008-10-15 16:06:03 +00:00
Chris Lattner 843dacc937 move PR1488 into this file.
llvm-svn: 57579
2008-10-15 16:02:15 +00:00
Anton Korobeynikov 185c72103b Temporary revert r57567 and unbreak the build.
llvm-svn: 57578
2008-10-15 14:22:06 +00:00
Nuno Lopes 6cbd4430cc regenerate
llvm-svn: 57577
2008-10-15 12:05:02 +00:00
Nuno Lopes 99f3dc6798 fix memleak in GetForwardRefForGlobal()
llvm-svn: 57576
2008-10-15 12:04:36 +00:00
Nuno Lopes 6f6e4e94be regenerate
llvm-svn: 57575
2008-10-15 11:20:21 +00:00
Nuno Lopes a4a546cb40 fix memleak in getTypeVal()
llvm-svn: 57574
2008-10-15 11:19:34 +00:00
Nuno Lopes bb683f953e regenerate
llvm-svn: 57573
2008-10-15 11:11:12 +00:00
Nuno Lopes 48e9028000 fix memleak in ResolveTypeTo()
llvm-svn: 57572
2008-10-15 11:10:21 +00:00
Gabor Greif e4544f7f91 catch one more typo, canonicalize LLVMdev
llvm-svn: 57571
2008-10-15 10:47:24 +00:00
Gabor Greif 3b33cb1667 fix some validation errors, improve formatting, squash a strange plural
llvm-svn: 57570
2008-10-15 10:29:51 +00:00
Gabor Greif 57bb5aec25 remove legacy interfaces
llvm-svn: 57569
2008-10-15 09:52:56 +00:00
Mikhail Glushenkov fe292356a2 llvmc2: Documentation update. Describe recent work on plugins.
llvm-svn: 57568
2008-10-15 09:29:13 +00:00
Mikhail Glushenkov 98757b24ec llvmc2: Some Makefile fixes and renames.
llvm-svn: 57567
2008-10-15 09:28:50 +00:00
Mikhail Glushenkov 13095977c5 Use (a slightly modified) llvm.css for llvmc2 docs.
llvm-svn: 57566
2008-10-15 09:27:44 +00:00
Dan Gohman 29ad439782 Now that predicates can be composed, simplify several of
the predicates by extending simple predicates to create
more complex predicates instead of duplicating the logic
for the simple predicates.

This doesn't reduce much redundancy in DAGISelEmitter.cpp's
generated source yet; that will require improvements to
DAGISelEmitter.cpp's instruction sorting, to make it more
effectively group nodes with similar predicates together.

llvm-svn: 57565
2008-10-15 06:50:19 +00:00
Mon P Wang 1f71a69cb9 Removed pinsrd and pinsrq intrinsics because the code generator does not support
them since they map to insert element

llvm-svn: 57564
2008-10-15 06:27:16 +00:00
Mon P Wang d05269d13c Added pinsrd, pinsrq, and some other vector intrinsics
llvm-svn: 57563
2008-10-15 06:18:34 +00:00
Dan Gohman 6e979020cd Add support for having multiple predicates on a TreePatternNode.
This will allow predicates to be composed, which will allow the
predicate definitions to become less redundant, and eventually
will allow DAGISelEmitter.cpp to emit less redundant code.

llvm-svn: 57562
2008-10-15 06:17:21 +00:00
Chris Lattner 3f399451cd regenerate
llvm-svn: 57561
2008-10-15 06:16:57 +00:00
Chris Lattner 25f74dc574 Fix the .ll grammar rules to allow any type before an 'i32', not just an
integer type.  Invalid things like 'float 42' are now rejected by the
semantic analysis in the productions not the parser.  This fixes PR2733.

llvm-svn: 57560
2008-10-15 06:16:45 +00:00
Chris Lattner 9535c94015 regenerate
llvm-svn: 57559
2008-10-15 06:03:48 +00:00
Chris Lattner d253878724 Eliminate the "IntType ::= INTTYPE" production, just use
INTTYPE everywhere.

llvm-svn: 57558
2008-10-15 06:03:37 +00:00
Chris Lattner 117792afec add a note
llvm-svn: 57557
2008-10-15 05:53:25 +00:00
Chris Lattner ddb17ce4be add support for folding immediates into stores when they
are due to argument passing in calls.  This is significant because
it hits all immediate arguments to calls on x86-32.

llvm-svn: 57556
2008-10-15 05:38:32 +00:00
Chris Lattner 3ba293564a fold immediates into stores in simple cases, this produces diffs like
this:

-	movl	$0, %eax
-	movl	%eax, _yy_n_chars
+	movl	$0, _yy_n_chars

llvm-svn: 57555
2008-10-15 05:30:52 +00:00
Ted Kremenek bb7818b666 Enhance dead store checker to not flag preincrements to dead variables where the preincrement is a subexpression, e.g. foo(++x); This can cause false negatives, but will remove a whole class of false positives.
llvm-svn: 57554
2008-10-15 05:23:41 +00:00
Chris Lattner e388725aef fold compare of null pointer into compare with 0.
llvm-svn: 57553
2008-10-15 05:18:04 +00:00
Chris Lattner a0f9d4972f Some minor cleanups:
1. Compute action in X86SelectSelect based on MVT instead of type.
2. Use TLI.getValueType(..) instead of MVT::getVT(..) because the former
   handles pointers and the later doesn't.
3. Don't pass TLI into isTypeLegal, since it already has access to it as 
   an ivar.

#2 gives fast isel some minor new functionality: handling load/stores of
pointers.

llvm-svn: 57552
2008-10-15 05:07:36 +00:00
Chris Lattner 74e012839d Use switch on VT instead of Type* comparisons.
llvm-svn: 57551
2008-10-15 04:32:45 +00:00
Chris Lattner dc1c380f23 Use X86FastEmitCompare for FCMP_OEQ and FCMP_UNE: it doesn't
change the generated code, but makes the code simpler.

llvm-svn: 57550
2008-10-15 04:29:23 +00:00
Chris Lattner d46b9510b6 refactor compare emission out into a new X86FastEmitCompare method,
which makes it easy to share the compare/imm folding logic with 'setcc'.
This shaves a bunch of instructions off the common select case, which
happens a lot in llvm-gcc.

llvm-svn: 57549
2008-10-15 04:26:38 +00:00
Chris Lattner 88f4754f8f Fold immediates into compares when possible, producing "cmp $4, %eax" instead of
loading 4 into a register and then doing the compare.

llvm-svn: 57548
2008-10-15 04:13:29 +00:00
Chris Lattner 47bef25c01 more minor refactoring of X86SelectBranch, no functionality change.
llvm-svn: 57547
2008-10-15 04:02:26 +00:00
Chris Lattner 0ce717ac6b factor buildmi calls in X86SelectBranch
llvm-svn: 57546
2008-10-15 03:58:05 +00:00
Chris Lattner f32ce221e4 factor some more BuildMI's in X86SelectCmp
llvm-svn: 57545
2008-10-15 03:52:54 +00:00
Chris Lattner a3596db462 factor some BuildMI calls, no functionality change.
llvm-svn: 57544
2008-10-15 03:47:17 +00:00
Dan Gohman 4459c4250d Adjust whitespace in debug messages to be more consistent
with other debug messages.

llvm-svn: 57543
2008-10-15 02:57:38 +00:00
Evan Cheng 3b0f5e4d61 - Add target lowering hooks that specify which setcc conditions are illegal,
i.e. conditions that cannot be checked with a single instruction. For example,
SETONE and SETUEQ on x86.
- Teach legalizer to implement *illegal* setcc as a and / or of a number of
legal setcc nodes. For now, only implement FP conditions. e.g. SETONE is
implemented as SETO & SETNE, SETUEQ is SETUO | SETEQ.
- Move x86 target over.

llvm-svn: 57542
2008-10-15 02:05:31 +00:00
Argyrios Kyrtzidis 88e1b97f16 Simplify handling of struct/union/class tags.
Instead of using two sets of Decl kinds (Struct/Union/Class and CXXStruct/CXXUnion/CXXClass), use one 'Record' and one 'CXXRecord' Decl kind and make tag kind a property of TagDecl.
Cleans up the code a bit and better reflects that Decl class structure.

llvm-svn: 57541
2008-10-15 00:42:39 +00:00
Daniel Dunbar 267c4fe1b5 Test commit.
llvm-svn: 57540
2008-10-15 00:26:06 +00:00
Dan Gohman e7ced74558 FastISel support for exception-handling constructs.
- Move the EH landing-pad code and adjust it so that it works
   with FastISel as well as with SDISel.
 - Add FastISel support for @llvm.eh.exception and
   @llvm.eh.selector.

llvm-svn: 57539
2008-10-14 23:54:11 +00:00