Dan Gohman
55083d5dd3
Use MachineBasicBlock::transferSuccessors.
...
llvm-svn: 52594
2008-06-21 20:21:19 +00:00
Chris Lattner
5a92bab4f0
"This moves built-in Objective-C types up the scope chains to where they can be replaced by versions included from the runtime library's headers."
...
This makes it ok to use @"foo" without a declaration for NSConstantString.
Patch by David Chisnall!
llvm-svn: 52593
2008-06-21 20:20:39 +00:00
Dan Gohman
1cf5af9e42
Use static_cast instead of reinterpret_cast for casting void*.
...
llvm-svn: 52592
2008-06-21 20:17:03 +00:00
Chris Lattner
8459e0bc59
Fix warning when assertions disabled.
...
llvm-svn: 52590
2008-06-21 19:49:01 +00:00
Chris Lattner
e635acab67
fix warning when assertions disabled.
...
llvm-svn: 52589
2008-06-21 19:48:22 +00:00
Chris Lattner
18a3284a0a
fix warning when assertion disabled.
...
llvm-svn: 52588
2008-06-21 19:47:44 +00:00
Chris Lattner
106b046d83
fix some warnings when assertions are disabled.
...
llvm-svn: 52587
2008-06-21 19:47:03 +00:00
Chris Lattner
535b830449
add parser and sema support for the funny ObjC '@defs' thing.
...
Patch by David Chisnall!
llvm-svn: 52586
2008-06-21 19:39:06 +00:00
Dan Gohman
14b911d929
Remove a redundant return.
...
llvm-svn: 52585
2008-06-21 19:34:57 +00:00
Dan Gohman
b282cc6070
Reorder some fields in SDNode. This avoids padding,
...
reducings its size from 80 to 72 on 64-bit hosts.
llvm-svn: 52584
2008-06-21 19:26:15 +00:00
Dan Gohman
46520a25a4
Remove ScheduleDAG's SUnitMap altogether. Instead, use SDNode's NodeId
...
field, which is otherwise unused after instruction selection, as an index
into the SUnit array.
llvm-svn: 52583
2008-06-21 19:18:17 +00:00
Dan Gohman
a4db3352f9
Add a priority queue class, which is a wrapper around std::priority_queue
...
and provides fairly efficient removal of arbitrary elements. Switch
ScheduleDAGRRList from std::set to this new priority queue.
llvm-svn: 52582
2008-06-21 18:35:25 +00:00
Chris Lattner
5d20a70d01
remove dead enums.
...
llvm-svn: 52581
2008-06-21 18:06:44 +00:00
Chris Lattner
a9b3cae8fd
Switch 'super' from being a weird cast thing to being a predefined expr node.
...
Patch by David Chisnall with objc rewriter and stmtdumper updates from me.
llvm-svn: 52580
2008-06-21 18:04:54 +00:00
Chris Lattner
552b52f49d
"This maps the -pthread option to -lpthread - this isn't 100% correct,
...
since handling this correctly is quite complex, and on some platforms
requires additional -D options and on some implies linking against a
different libc, but this works better than just ignoring the option.
The other change passes the -x option across to clang, which allows
compiling .c files as Objective-C and so on. For some reason a lot of
configure scripts seem to be under the misguided impression that this
is a sensible thing to do."
Patch by David Chisnall!
llvm-svn: 52579
2008-06-21 17:46:11 +00:00
Ted Kremenek
68d2368064
Include stdint.h instead of stdio.h.
...
llvm-svn: 52578
2008-06-21 17:20:55 +00:00
Duncan Sands
3bb8999719
Support for load/store of expanded float types. I
...
don't know if a truncating store is possible here,
but added support for it anyway.
llvm-svn: 52577
2008-06-21 17:00:47 +00:00
Dan Gohman
e6e1348275
Change ScheduleDAG's SUnitMap from DenseMap<SDNode*, vector<SUnit*> >
...
to DenseMap<SDNode*, SUnit*>, and adjust the way cloned SUnit nodes are
handled so that only the original node needs to be in the map.
This speeds up llc on 447.dealII.llvm.bc by about 2%.
llvm-svn: 52576
2008-06-21 15:52:51 +00:00
Argyrios Kyrtzidis
e6aff3db25
K&R-style functions not allowed in C++.
...
llvm-svn: 52575
2008-06-21 10:00:56 +00:00
Evan Cheng
42bbca11cc
Enable PRE.
...
llvm-svn: 52574
2008-06-21 07:26:53 +00:00
Evan Cheng
f593a65497
Undo spill weight tweak. Need to investigate the performance regressions.
...
llvm-svn: 52572
2008-06-21 06:45:54 +00:00
Dan Gohman
4b49be1cbe
Simplify some template parameterization.
...
llvm-svn: 52571
2008-06-21 01:08:22 +00:00
Evan Cheng
33067210d1
Back out Matthijs' DAE patches. It's miscompiling gcc driver.
...
llvm-svn: 52570
2008-06-21 00:31:44 +00:00
Ted Kremenek
9f9aefdc89
Updated latest static analyzer builder to checker-43.
...
llvm-svn: 52569
2008-06-20 23:22:15 +00:00
Ted Kremenek
22cf89d9cd
Test the dead-store checker using both -warn-dead-stores and -checker-simple.
...
llvm-svn: 52568
2008-06-20 23:14:52 +00:00
Ted Kremenek
c9cea053ba
When using the dead-stores checker with the BugReporter class, properly capture the diagnostic associated with a specific warning and emit it.
...
llvm-svn: 52565
2008-06-20 23:13:39 +00:00
Ted Kremenek
4c32155a0f
Updated VS build system. Patch provided by Cedric Venet:
...
http://lists.cs.uiuc.edu/pipermail/llvmdev/2008-June/015446.html
llvm-svn: 52564
2008-06-20 22:19:12 +00:00
Ted Kremenek
ec93f25a9c
Updated latest checker build.
...
llvm-svn: 52563
2008-06-20 21:56:47 +00:00
Ted Kremenek
c64511152a
Updated call to dead stores to use proper arguments.
...
llvm-svn: 52560
2008-06-20 21:55:29 +00:00
Ted Kremenek
837d967fe8
Updated latest static analyzer build to checker-41.
...
llvm-svn: 52559
2008-06-20 21:54:57 +00:00
Ted Kremenek
b0ead8520c
Updated Xcode project.
...
llvm-svn: 52556
2008-06-20 21:46:17 +00:00
Ted Kremenek
34a691734e
Modified the dead stores checker to...
...
1) Check if a dead store appears as a subexpression. For such cases, we emit
a verbose diagnostic so that users aren't confused. This addresses:
<rdar://problem/5968508> checker gives misleading report for dead store in loop
2) Don't emit a dead store warning when assigning a null value to a pointer.
This is a common form of defensive programming. We may wish to make
this an option to the the checker one day.
This addresses the feature request in the following email:
http://lists.cs.uiuc.edu/pipermail/cfe-dev/2008-June/001978.html
llvm-svn: 52555
2008-06-20 21:45:25 +00:00
Evan Cheng
efc67e78d7
Enhanced heuristic to determine the *best* register to spill. Instead of picking the register with the lowest spill weight. Consider (up to) 2 additional registers with spill weights that are close to the lowest spill weight. The one with fewest defs and uses that conflicts with the current interval (weighted by loop depth) is the spill candidate.
...
This is not always a win, but there are much more wins than loses and wins tend to be more noticeable.
llvm-svn: 52554
2008-06-20 21:45:16 +00:00
Ted Kremenek
99ecdd175d
Added ParentMap, a class to represent a lazily constructed mapping from child to parents.
...
llvm-svn: 52553
2008-06-20 21:40:36 +00:00
Ted Kremenek
d50c7a4b0d
Added "Decl::getCodyBody()", a virtual method that returns the root AST node (Stmt*) that the Decl wraps (if any). Currently this only returns a non-null value for FunctionDecl and ObjCMethodDecl.
...
llvm-svn: 52552
2008-06-20 21:39:47 +00:00
Chris Lattner
e4645615d3
integer types are not primitive, they are derived.
...
llvm-svn: 52551
2008-06-20 20:50:48 +00:00
Owen Anderson
d1cb6e2466
llvmc doesn't exist anymore, and llvmc2 doesn't have a special license file.
...
llvm-svn: 52550
2008-06-20 20:05:57 +00:00
Owen Anderson
12c763f31c
Remove empty directory.
...
llvm-svn: 52549
2008-06-20 20:05:17 +00:00
Duncan Sands
f362183c24
Share some code that is common between integer and
...
float expansion (and sometimes vector splitting too).
llvm-svn: 52548
2008-06-20 18:40:50 +00:00
Duncan Sands
b6a90ccaee
Add some methods for querying the nature of a
...
store, like the methods for loads (and neaten
those up a bit while there).
llvm-svn: 52547
2008-06-20 18:34:30 +00:00
Duncan Sands
49295b48eb
Rename the operation of turning a float type into an
...
integer of the same type. Before it was "promotion",
but this is confusing because it is quite different
to promotion of integers. Call it "softening" instead,
inspired by "soft float".
llvm-svn: 52546
2008-06-20 17:49:55 +00:00
Dan Gohman
3792c470d5
Clean up some uses of std::distance, now that we have allnodes_size.
...
llvm-svn: 52545
2008-06-20 17:15:19 +00:00
Dan Gohman
3ada1e118b
Clean up a use of std::distance.
...
llvm-svn: 52544
2008-06-20 17:11:32 +00:00
Dan Gohman
a5dd67f002
Tidy up some commments and use the getAggregateOperand and
...
getInsertedValueOperand accessors. Thanks Matthijs!
llvm-svn: 52543
2008-06-20 16:41:17 +00:00
Dan Gohman
b5210efb31
Fix the conditions under which SCCP should examine insertvalue
...
instructions. Thanks to Matthijs Kooijman for pointing this out!
llvm-svn: 52542
2008-06-20 16:39:44 +00:00
Dan Gohman
795e2943a2
Add an allnodes_size method.
...
llvm-svn: 52541
2008-06-20 16:03:16 +00:00
Matthijs Kooijman
48b282f03b
Add testcase that checks that DeadArgElim doesn't touch stuff it shouldn't touch.
...
llvm-svn: 52540
2008-06-20 15:38:22 +00:00
Matthijs Kooijman
c456f9dfc6
80 column and trailing whitespace fixes.
...
llvm-svn: 52539
2008-06-20 15:34:07 +00:00
Matthijs Kooijman
0c50b953c5
Don't let DeadArgumentElimination attempt to update callers when the return
...
type wasn't changed.
llvm-svn: 52538
2008-06-20 15:25:43 +00:00
Matthijs Kooijman
9dc59b7666
Don't let DeadArgElimination change the return type ({} into void and {T}
...
into T) when no return values are actually dead.
llvm-svn: 52537
2008-06-20 15:16:45 +00:00