Sebastian Redl
6ebb51a41d
Add two options for playing with modules.
...
llvm-svn: 111166
2010-08-16 18:17:11 +00:00
Douglas Gregor
b61c07aca0
When caching code completions for global declarations, keep track of
...
the usage type of each declaration result, then compare those types to
the preferred type of the completion. This provides parity in the
priority calculation between the code-completion results produced
directly from Sema and those cached by ASTUnit.
For the standard Cocoa.h (+ others) example, there's a penalty of 3-4
hundredeths of a second when caching the global results (for ~31,000
results), because we need an ASTContext-agnostic representation of
types for the comparison, and therefore we use... strings. Eventually,
we'd like to implement a more efficient ASTContext-agnostic encoding
of types.
llvm-svn: 111165
2010-08-16 18:08:11 +00:00
Jim Grosbach
8be0196afe
track local frame size in MFI, not local to the pass, since PEI needs it.
...
llvm-svn: 111164
2010-08-16 18:06:15 +00:00
Fariborz Jahanian
055068df4a
Fix a crash when parsing malformed out-of-line member function
...
definition. radar 8307865.
llvm-svn: 111163
2010-08-16 17:58:53 +00:00
Dan Gohman
a573c41435
Revert r111031. The way LLVM defines loop invariance, the property of an
...
expression being loop invariant is not equivalent to the property of
properly dominating the loop header.
Other optimizations have also made this optimization less important.
llvm-svn: 111160
2010-08-16 17:34:25 +00:00
Argyrios Kyrtzidis
a3ae3eb690
Fix initialization for members of anonymous struct in a union.
...
llvm-svn: 111159
2010-08-16 17:27:13 +00:00
Argyrios Kyrtzidis
33aee3934a
Emit diagnostic error when the field of an anonymous struct is non trivial.
...
llvm-svn: 111158
2010-08-16 17:27:08 +00:00
Jakob Stoklund Olesen
5f72a04ba7
Remove unused functions.
...
llvm-svn: 111156
2010-08-16 17:18:20 +00:00
Jakob Stoklund Olesen
b7f872197a
Remove unused functions.
...
llvm-svn: 111155
2010-08-16 17:18:18 +00:00
Bob Wilson
8303fbbcf9
Remove unused code.
...
llvm-svn: 111154
2010-08-16 17:06:03 +00:00
Bob Wilson
8f553757c4
Convert a test to use FileCheck.
...
llvm-svn: 111153
2010-08-16 17:05:27 +00:00
Dan Gohman
d0ceccd9fd
Placate overzealous compiler warnings.
...
llvm-svn: 111152
2010-08-16 17:01:55 +00:00
Dan Gohman
797a1dbb1c
To create a copy of a SmallVector with an element removed from the
...
middle, copy the elements in two groups, rather than copying all the
elements and then doing an erase on the middle of the result. These
are SmallVectors, so we shouldn't expect to hit dynamic allocation
in the common case.
llvm-svn: 111151
2010-08-16 16:57:24 +00:00
Douglas Gregor
247474085e
Dereferencing NULL pointers is such poor form.
...
llvm-svn: 111150
2010-08-16 16:46:30 +00:00
Bob Wilson
57825eea36
Install Embedded builds into usr/local. Radar 8313723.
...
llvm-svn: 111149
2010-08-16 16:39:59 +00:00
Chris Lattner
1218ed824d
silence a vc2010 warning: " result of 32-bit shift implicitly converted to
...
64 bits (was 64-bit shift intended?)", pointed out by 'nobled' on llvmdev
llvm-svn: 111148
2010-08-16 16:35:20 +00:00
Dan Gohman
0d0cc18af5
Tidy whitespace.
...
llvm-svn: 111147
2010-08-16 16:34:09 +00:00
Dan Gohman
c29eeaecec
Add a comment.
...
llvm-svn: 111145
2010-08-16 16:31:39 +00:00
Dan Gohman
7eac4961d7
Use const_iterator in a few places.
...
llvm-svn: 111144
2010-08-16 16:30:01 +00:00
Dan Gohman
74c61503b1
Use iterators instead of indices in a few more places.
...
llvm-svn: 111143
2010-08-16 16:27:53 +00:00
Dan Gohman
f29618236e
Micro-optimize SCEVConstant comparison.
...
llvm-svn: 111142
2010-08-16 16:25:35 +00:00
Anton Yartsev
2cc136d4e3
support for vec_add, vec_adds, vec_and, vec_andc with bool arguments
...
llvm-svn: 111141
2010-08-16 16:22:12 +00:00
Dan Gohman
3688ea5c7d
Move SCEVNAryExpr's virtual member functions out of line, and convert
...
them to iterators.
llvm-svn: 111140
2010-08-16 16:21:27 +00:00
Douglas Gregor
6e24033bd2
When caching global completion results, keep track of the simplified
...
type class, so that we can adjust priorities appropriately when the
preferred type for the context and the actual type of the completion
are similar.
This gets us one step closer to parity of the cached completion
results with the non-cached completion results.
llvm-svn: 111139
2010-08-16 16:18:59 +00:00
Dan Gohman
d6925bbe0d
Use iterators instead of indices in simple cases.
...
llvm-svn: 111138
2010-08-16 16:16:11 +00:00
Dan Gohman
b6c773ec2e
Avoid gratuitous inefficiency in ifndef NDEBUG code.
...
llvm-svn: 111137
2010-08-16 16:13:54 +00:00
Dan Gohman
e5fb1036e6
Make one getAddExpr call when analyzing a+b+c+d+e+... instead of one
...
for each add instruction. Ditto for Mul.
llvm-svn: 111136
2010-08-16 16:03:49 +00:00
Dan Gohman
b094b39111
Delete an unused function.
...
llvm-svn: 111135
2010-08-16 15:57:14 +00:00
Abramo Bagnara
217e902b1d
Fixed typo in conj, conjf, conjl signature.
...
llvm-svn: 111134
2010-08-16 15:57:05 +00:00
Dan Gohman
89fdbaf99a
Instead of having CollectSubexpr's categorize operands as interesting or
...
uninteresting, just put all the operands on one list and make
GenerateReassociations make the decision about what's interesting.
This is simpler, and it avoids an extra ScalarEvolution::getAddExpr call.
llvm-svn: 111133
2010-08-16 15:50:00 +00:00
Dan Gohman
9b7632df26
Put add operands in ScalarEvolution-canonical order, when convenient.
...
This isn't necessary, because ScalarEvolution sorts them anyway,
but it's tidier this way.
llvm-svn: 111132
2010-08-16 15:39:27 +00:00
Dan Gohman
f99ba9671e
Specialize FoldingSetTrait<SCEV>, providing implementations of node
...
comparison and hash computation which don't require constructing
temporary ID values.
llvm-svn: 111131
2010-08-16 15:31:45 +00:00
Dan Gohman
9c9ce53b29
Add hooks to FoldingSetTrait to allow specializations to provide
...
implementations of equality comparison and hash computation. This
can be used to optimize node lookup by avoiding creating lots of
temporary ID values just for hashing and comparison purposes.
llvm-svn: 111130
2010-08-16 15:30:39 +00:00
Dan Gohman
b8640b6d73
Tidy up whitespace in comments.
...
llvm-svn: 111129
2010-08-16 15:04:39 +00:00
Dan Gohman
02341b2023
Constify FoldingSetNodeIDRef's Data.
...
llvm-svn: 111128
2010-08-16 15:03:24 +00:00
Dan Gohman
27c98e6303
Reverse the order of GetNodeProfile's arguments, for consistency
...
with FoldingSetTrait::Profile.
llvm-svn: 111127
2010-08-16 14:53:42 +00:00
Dan Gohman
1cab72a44f
Fix indentation in example code in a comment.
...
llvm-svn: 111125
2010-08-16 14:45:36 +00:00
Dan Gohman
6e964c7fb4
Avoid #include <ScalarEvolution.h> in LoopSimplify.cpp, which doesn't
...
actually use ScalarEvolution.
llvm-svn: 111124
2010-08-16 14:44:03 +00:00
Dan Gohman
250b754428
Instead, teach SimplifyCFG to trim non-address-taken blocks from
...
indirectbr destination lists.
llvm-svn: 111122
2010-08-16 14:41:14 +00:00
Dan Gohman
fb83b043eb
Revert r111058, the lint check for indirectbr successors that aren't
...
address-taken. This can occur normally, if the code which took the
address got DCEd.
llvm-svn: 111121
2010-08-16 14:39:19 +00:00
Jordy Rose
722f558f07
Model the effects of strcpy() and stpcpy() in CStringChecker. Other changes:
...
- Fix memcpy() and friends to actually invalidate the destination buffer.
- Emit a different message for out-of-bounds buffer accesses if the buffer is being written to.
- When conjuring symbols, let ValueManager figure out the type.
llvm-svn: 111120
2010-08-16 07:51:42 +00:00
Charles Davis
ebab1ed5d3
Error out if reinterpret_casting between member pointers of two different
...
sizes.
llvm-svn: 111119
2010-08-16 05:30:44 +00:00
Charles Davis
2d3694297d
Err on incomplete class types in member pointers when compiling for the
...
Microsoft C++ ABI, for now.
llvm-svn: 111118
2010-08-16 04:01:50 +00:00
Charles Davis
53c59df2f7
Implement support for member pointers under the Microsoft C++ ABI in the
...
AST library.
This also adds infrastructure for supporting multiple C++ ABIs in the AST.
llvm-svn: 111117
2010-08-16 03:33:14 +00:00
Jordy Rose
df28e8ec41
- Allow making ElementRegions with complex offsets (expressions or symbols) for the purpose of bounds-checking.
...
- Rewrite GRState::AssumeInBound to actually do that checking, and to use the normal constraint path.
- Remove ConstraintManager::AssumeInBound.
- Teach RegionStore and FlatStore to ignore those regions for now.
llvm-svn: 111116
2010-08-16 01:15:17 +00:00
Benjamin Kramer
cbc55d9dc0
Test expects SSE, give him SSE.
...
llvm-svn: 111115
2010-08-15 23:32:03 +00:00
David Chisnall
589a494352
Pass some things to the linker that gcc passes. -r is the only one of these that I'm sure about, but the others seem to be listed on FreeBSD by gcc -dumpspecs, so I hope they're right. Apparently -r is also not passed on GNU/Linux (and should be), but I can't see where the toolchain definition for this platform live.
...
llvm-svn: 111114
2010-08-15 22:58:12 +00:00
Jordy Rose
d2b777a409
Move GRState's bind* methods out of its header file -- they're too big for inlining now.
...
llvm-svn: 111113
2010-08-15 22:19:33 +00:00
Oscar Fuentes
53339a737f
Updated LLVMLibDeps.cmake
...
llvm-svn: 111112
2010-08-15 22:14:42 +00:00
Oscar Fuentes
5b823e0821
CMake: Improved COMMENT on a custom command
...
llvm-svn: 111111
2010-08-15 22:14:36 +00:00