Commit Graph

50988 Commits

Author SHA1 Message Date
Sebastian Redl 9c33e96813 Fix typo in index operator overloading.
llvm-svn: 60483
2008-12-03 16:32:40 +00:00
Duncan Sands f52e518d05 Only check that the result of the mapping was not
a new node if the node was actually remapped.

llvm-svn: 60482
2008-12-03 12:36:16 +00:00
Rafael Espindola cda011b5ad Fix bug 3140.
Print a single parameter .file directive if we have an ELF target.

llvm-svn: 60480
2008-12-03 11:01:37 +00:00
Richard Osborne feece7edab Add support for ISD::TRAP to the XCore backend
llvm-svn: 60479
2008-12-03 10:59:16 +00:00
Evan Cheng 501089f6f4 Refactor code. No functionality change.
llvm-svn: 60478
2008-12-03 08:38:43 +00:00
Bill Wendling f8d1ef9842 CC should only be a ConstantSDNode at this point. Just use 'cast' instead of 'dyn_cast'.
llvm-svn: 60477
2008-12-03 08:32:02 +00:00
Evan Cheng b5a97ff651 Fix test.
llvm-svn: 60476
2008-12-03 08:20:45 +00:00
Chris Lattner 350fc5721d testcase for br undef folding.
llvm-svn: 60471
2008-12-03 07:48:27 +00:00
Chris Lattner 595c7279bd Teach jump threading some more simple tricks:
1) have it fold "br undef", which does occur with
   surprising frequency as jump threading iterates.
2) teach j-t to delete dead blocks.  This removes the successor
   edges, reducing the in-edges of other blocks, allowing 
   recursive simplification.
3) Fold things like:
     br COND, BBX, BBY
  BBX:
     br COND, BBZ, BBW

   which also happens because jump threading iterates.

llvm-svn: 60470
2008-12-03 07:48:08 +00:00
Chris Lattner 37e0136fef third time is the charm.
llvm-svn: 60469
2008-12-03 07:45:15 +00:00
Chris Lattner c04a1ffa9a fix assertion.
llvm-svn: 60468
2008-12-03 07:43:05 +00:00
Chris Lattner 50532410d1 don't spew tons of stuff to the output. This testcase is *not* for
loop deletion (it is for a ton of passes), which is very bad.

llvm-svn: 60465
2008-12-03 06:41:50 +00:00
Chris Lattner 7eb270ed03 Rename DeleteBlockIfDead to DeleteDeadBlock and make it
unconditionally delete the block.  All likely clients will
do the checking anyway.

llvm-svn: 60464
2008-12-03 06:40:52 +00:00
Chris Lattner bcc904a67c Factor some code out of SimplifyCFG, forming a new
DeleteBlockIfDead method.

llvm-svn: 60463
2008-12-03 06:37:44 +00:00
Anders Carlsson 6a113d9ddb If a global var decl has an initializer, make sure to always set its linkage to external.
llvm-svn: 60462
2008-12-03 05:51:23 +00:00
Dan Gohman cc78cdf275 Mark x86's V_SET0 and V_SETALLONES with isSimpleLoad, and teach X86's
foldMemoryOperand how to "fold" them, by converting them into constant-pool
loads. When they aren't folded, they use xorps/cmpeqd, but for example when
register pressure is high, they may now be folded as memory operands, which
reduces register pressure.

Also, mark V_SET0 isAsCheapAsAMove so that two-address-elimination will
remat it instead of copying zeros around (V_SETALLONES was already marked).

llvm-svn: 60461
2008-12-03 05:21:24 +00:00
Bill Wendling e3402692d8 Change label to 'carry' for unsigned adds.
llvm-svn: 60460
2008-12-03 02:43:12 +00:00
Dan Gohman ae3ba45eb2 Add a sanity-check to tablegen to catch the case where isSimpleLoad
is set but mayLoad is not set. Fix all the problems this turned up.

Change code to not use isSimpleLoad instead of mayLoad unless it
really wants isSimpleLoad.

llvm-svn: 60459
2008-12-03 02:30:17 +00:00
Dan Gohman ac5392c596 Fix a missing #include.
llvm-svn: 60458
2008-12-03 02:10:00 +00:00
Dan Gohman a3d9eb0131 Add an explicit keyword.
llvm-svn: 60457
2008-12-03 01:55:47 +00:00
Dan Gohman 9810e76b30 Replace a #include with a forward-declaration.
llvm-svn: 60456
2008-12-03 01:53:18 +00:00
Dan Gohman 0c8df671ac Fix this comment to reflect that it applies to types other
than just i32.

llvm-svn: 60455
2008-12-03 01:39:44 +00:00
Dan Gohman 5d3d1f69e1 Fix byval arguments in the fastcc calling convention. The fastcc convention
delegates to the regular x86-32 convention which handles byval, but only
after it handles a few cases, and it's necessary to handle byval before
handling those cases. This fixes PR3122 (and rdar://6400815), llvm-gcc
miscompiling LLVM.

llvm-svn: 60453
2008-12-03 01:28:04 +00:00
Ted Kremenek 73a4d28758 PTH:
Use an array instead of a DenseMap to cache persistent IDs -> IdentifierInfo*.  This leads to a 4% speedup at -fsyntax-only using PTH.

llvm-svn: 60452
2008-12-03 01:16:39 +00:00
Dan Gohman 971c88f3b2 Add nounwind attributes to this test.
llvm-svn: 60451
2008-12-03 01:10:18 +00:00
Steve Naroff f326f4056e More support for rewriting property getter/setters.
llvm-svn: 60450
2008-12-03 00:56:33 +00:00
Dale Johannesen b43a689520 testcases for recent dag combiner changes
llvm-svn: 60449
2008-12-03 00:52:41 +00:00
Ted Kremenek e1fc020e65 Update Xcode project.
llvm-svn: 60448
2008-12-03 00:38:43 +00:00
Ted Kremenek 33eeabda61 - Remove PTHManager.cpp. Move all of its functions to PTHLexer.cpp since some of the internal methods are used by PTHLexer (their implementations are intertwined.) This enables some important inlining opportunities at -O3.
- Don't construct an std::vector<Token> prior to feeding PTH tokens to the Preprocessor.  Stream them off the PTH file directly.

llvm-svn: 60447
2008-12-03 00:38:03 +00:00
Chris Lattner 0a12e95362 Fix isIntN to work with APInts > 64 bits. This method is only
used by clang apparently.

llvm-svn: 60446
2008-12-02 23:33:29 +00:00
Sebastian Redl d6d55eeef5 Correct pretty printing of array new expressions.
llvm-svn: 60444
2008-12-02 22:08:59 +00:00
Evan Cheng e62150cae4 Remove a (what appears to be) overly strict assertion. Here is what happened:
1. ppcf128 select is expanded to f64 select's.
2. f64 select operand 0 is an i1 truncate, it's promoted to i32 zero_extend.
3. f64 select is updated. It's changed back to a "NewNode" and being re-analyzed.
4. f64 select operands are being processed. Operand 0 is a "NewNode". It's being expunged out of ReplacedValues map.
5. ExpungeNode tries to remap f64 select and notice it's a "NewNode" and assert.
Duncan, please take a look. Thanks.

llvm-svn: 60443
2008-12-02 21:57:09 +00:00
Dale Johannesen 4d2ecb8f68 Minor rewrite per review feedback.
llvm-svn: 60442
2008-12-02 21:17:11 +00:00
Ted Kremenek d328da1b65 Update Xcode project.
llvm-svn: 60441
2008-12-02 20:16:22 +00:00
Ted Kremenek da4d9dfbca Add "-token-cache" option for using pretokenized cache files.
llvm-svn: 60440
2008-12-02 19:57:31 +00:00
Scott Michel 9b0b28e021 Non-functional change: make custom lowering for truncate stylistically
consistent with the way it's generally done in other places.

llvm-svn: 60439
2008-12-02 19:55:08 +00:00
Scott Michel 7364025ff8 CellSPU:
- Incorporate Tilmann Scheller's ISD::TRUNCATE custom lowering patch
- Update SPU calling convention info, even if it's not used yet (but can be
  at some point or another)
- Ensure that any-extended f32 loads are custom lowered, especially when
  they're promoted for use in printf.

llvm-svn: 60438
2008-12-02 19:53:53 +00:00
Ted Kremenek af058b5696 Preprocessor:
- Added method "setPTHManager" that will be called by the driver to install
  a PTHManager for the Preprocessor.
- Fixed some comments.
- Added EnterSourceFileWithPTH to mirror EnterSourceFileWithLexer.

llvm-svn: 60437
2008-12-02 19:46:31 +00:00
Ted Kremenek 498b6210fc Added PTHManager, a utility class that will be used by Preprocessor to lazily create PTHLexer objects for pre-tokenized files.
llvm-svn: 60436
2008-12-02 19:45:05 +00:00
Ted Kremenek ccaab17e2c PTH emission:
- Output 32 bit integers using bit-shifting + write of individual bytes.
  This is motivated because we aren't guaranteed to load 32-bit ints of the mmaped PTH file at 4-byte offsets.
- Don't emit flags for IdentifierInfos.  These are lazily populated by the Preprocessor/Parser.
- Only write out tokens for files with absolute paths.  This is potentially temporary, but simplifies things for now.

llvm-svn: 60435
2008-12-02 19:44:08 +00:00
Dan Gohman 7e9daef644 Fix a typo in a comment.
llvm-svn: 60434
2008-12-02 19:27:20 +00:00
Owen Anderson ecd5b5f2b2 Add support for folding spills into preceding defs when doing pre-alloc splitting.
llvm-svn: 60433
2008-12-02 18:53:47 +00:00
Dale Johannesen 54bdec238a One more transformation.
llvm-svn: 60432
2008-12-02 18:40:40 +00:00
Dale Johannesen 70060013d2 Make the code do what the comment says it does.
llvm-svn: 60431
2008-12-02 18:40:09 +00:00
Fariborz Jahanian eae373ea32 More type-checking of setter/getter methods. This is still
work in prgress.

llvm-svn: 60430
2008-12-02 18:39:49 +00:00
Chris Lattner 027d726f10 Comment typeo fix, thanks Duncan!
llvm-svn: 60429
2008-12-02 18:33:11 +00:00
Nuno Lopes 48b5a33826 llvm-ld doesnt support '-g', so aovid passing that opt to it
llvm-svn: 60428
2008-12-02 18:19:03 +00:00
Steve Naroff 0629704e78 Add a couple FIXME's.
llvm-svn: 60427
2008-12-02 17:54:50 +00:00
Steve Naroff c038b3af03 Make sure synthesized properties get inserted into the classes/categories meta data.
llvm-svn: 60426
2008-12-02 17:36:43 +00:00
Sebastian Redl 5c6ebcc198 Parsing new and delete is now complete.
llvm-svn: 60425
2008-12-02 17:22:40 +00:00