]>
granicus.if.org Git - clang/log
Ted Kremenek [Tue, 22 Jul 2008 16:56:21 +0000 (16:56 +0000)]
Use llvm::utostr_32 instead of ostringstream.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53914
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 22 Jul 2008 16:47:06 +0000 (16:47 +0000)]
Update VS project.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53913
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 22 Jul 2008 16:22:19 +0000 (16:22 +0000)]
Update Xcode project.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53910
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 22 Jul 2008 16:21:24 +0000 (16:21 +0000)]
Moved registration of basic path-sensitive checks from GRSimpleVals.cpp to GRExprEngineInternalChecks.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53909
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 22 Jul 2008 14:41:47 +0000 (14:41 +0000)]
Rename file.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53906
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 22 Jul 2008 01:35:47 +0000 (01:35 +0000)]
Prevent codegen crash on sizeof(<function type>), a gcc extension.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53899
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 22 Jul 2008 01:03:06 +0000 (01:03 +0000)]
Add svn:ignore for cscope.{out,files} in top level clang dir
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53897
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 22 Jul 2008 00:46:16 +0000 (00:46 +0000)]
Added path-sensitive checking for null pointer values passed to function arguments marked nonnull.
This implements <rdar://problem/
6069935 >
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53891
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 22 Jul 2008 00:26:45 +0000 (00:26 +0000)]
Implement bzero, memset, memmove builtins.
This subsumes Nico Weber's patch and implements bzero in terms
of llvm.memset to match llvm-gcc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53888
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 22:59:13 +0000 (22:59 +0000)]
Implement nans, prefetch, and trap builtins.
This closes <rdar://problem/
6080720 >, support for __builtin_constant_p
has been filed separately.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53885
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 22:17:28 +0000 (22:17 +0000)]
minor cleanup to the actions interface to pass around SmallVectorImpl instead
of a specific smallvector size.
Fix protocol lists to pass down proper location info, so we get diagnostics
like this:
t.m:3:35: error: cannot find protocol definition for 'NSCopying', referenced by 'NSWhatever'
@interface NSWhatever : NSObject <NSCopying>
^
instead of this:
t.m:3:44: error: cannot find protocol definition for 'NSCopying', referenced by 'NSWhatever'
@interface NSWhatever : NSObject <NSCopying>
^
Add a new IdentifierLocPair typedef which is just a pair<IdentifierInfo*, SourceLocation>
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53883
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Mon, 21 Jul 2008 22:09:15 +0000 (22:09 +0000)]
Add test case for nonnull attribute.
Fix indexing bug.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53882
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Mon, 21 Jul 2008 21:53:04 +0000 (21:53 +0000)]
Added sema support for the nonnull attribute. Will add test cases soon.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53881
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 21:43:28 +0000 (21:43 +0000)]
Kill an unused variable warning
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53878
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 21:33:21 +0000 (21:33 +0000)]
unindent this function by using an early exit, not functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53877
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 21:32:27 +0000 (21:32 +0000)]
move two more lists of protocols over to use ObjCList<ObjCProtocolDecl>,
simplifying code along the way and fixing a problem and memory leak or two.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53876
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 18:45:49 +0000 (18:45 +0000)]
Add svn:ignore property for test Output directories
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53867
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 18:44:41 +0000 (18:44 +0000)]
Add __builtin_powi[fl] support
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53866
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 18:42:27 +0000 (18:42 +0000)]
Fix a test RUN line to not generate '=-' in test directory
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53865
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 18:35:17 +0000 (18:35 +0000)]
add forward definition protocols to the protocol list for a class.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53864
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 18:34:02 +0000 (18:34 +0000)]
references to completely undeclared protocols should be errors.
References to forward definitions should be warnings.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53863
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Mon, 21 Jul 2008 18:26:02 +0000 (18:26 +0000)]
RewriteObjC::RewriteObjCForCollectionStmt() needs to handle bodies with a single statement.
Fixes <rdar://problem/
6084870 > clang ObjC rewriter: for-in enumeration in 1 line produces output with error.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53858
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 18:19:38 +0000 (18:19 +0000)]
introduce a new ObjCList templated class and start moving
various objc lists over to it. First up, the protocol list
on ObjCInterfaceDecl.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53856
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Mon, 21 Jul 2008 17:53:09 +0000 (17:53 +0000)]
Update checker build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53855
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 17:23:15 +0000 (17:23 +0000)]
rename setReferencedProtocolList -> addReferencedProtocols to
be consistent with ObjCInterfaceDecl.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53852
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 21 Jul 2008 17:19:41 +0000 (17:19 +0000)]
Implement ffs, parity, and popcount builtins.
+ test case
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53851
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Mon, 21 Jul 2008 09:18:38 +0000 (09:18 +0000)]
Change 'MDecl' to 'MD' to fix redefinition compiler error in MSVC++.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53849
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 07:13:18 +0000 (07:13 +0000)]
fix typo
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53848
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 07:06:49 +0000 (07:06 +0000)]
Switch initialization of the protocol list for an interface decl to use
the standard "set these as the list of protocols" interface instead of a
strange "set this as the size and then set each one to the value" interface.
The problem with the later is that it a) is completely different from
everything else, b) is awkward, and c) doesn't handle the case when a
referenced protocol is invalid: it set it to null.
This meant that all clients downstream would have to handle null protocols
in the protocol list, and empirically they didn't. Fix this by not setting
invalid protocols in the referenced protocol list, fixing the crash on
test/Sema/objc-interface-1.m
While I'm at it, clean up some locations so that we produce:
t.m:1:25: error: cannot find interface declaration for 'NSObject', superclass of 'NSWhatever'
@interface NSWhatever : NSObject <NSCopying>
~~~~~~~~~~~~~~~~~~~~~ ^
instead of:
t.m:1:1: error: cannot find interface declaration for 'NSObject', superclass of 'NSWhatever'
@interface NSWhatever : NSObject <NSCopying>
^
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53846
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 06:44:27 +0000 (06:44 +0000)]
when in the context of an @implementation, look for private methods in the
@implementation to resolve nullary selector references.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53845
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 06:31:05 +0000 (06:31 +0000)]
don't pass in null as the Name for GenerateClassStructure,
it goes and makes std::strings out of them, which is not
defined.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53843
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 06:16:07 +0000 (06:16 +0000)]
improve diagnostics about problems with receivers to highlight the receiver.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53842
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 06:12:56 +0000 (06:12 +0000)]
continue cleaning up code, and disable sending a message directly to an
interface. This fixes a bug where we used to accept:
void test2(NSNumber x) {
[x METH];
}
which doesn't make sense and GCC rejects.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53841
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:57:44 +0000 (05:57 +0000)]
simplify control flow a bit, reducing indentation. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53837
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:54:02 +0000 (05:54 +0000)]
tighten up some checks, don't allow sending a message to NSString****
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53836
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:38:58 +0000 (05:38 +0000)]
update diagnostic to include string
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53835
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:35:34 +0000 (05:35 +0000)]
improve invalid member reference diagnostics to print the type and
have better source ranges. Before:
t.m:11:53: error: member reference is not to a structure or union
CGFloat maxOffsetY = [_outlineLayer contentSize].height - [_outlineLayer frame].size.height;
^~~~~~~
after:
t.m:11:54: error: member reference base type ('id') is not a structure or union
CGFloat maxOffsetY = [_outlineLayer contentSize].height - [_outlineLayer frame].size.height;
~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53834
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:27:51 +0000 (05:27 +0000)]
merge a bunch of code that is now common between qual interfaces and interfaces.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53833
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:20:01 +0000 (05:20 +0000)]
rename getProtocols -> getProtocol, as it only returns a single
protocol. Simplify some code to use unconditional form of the
protocol access list.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53832
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:19:23 +0000 (05:19 +0000)]
use iterators instead of direct access to protocol list.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53831
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 05:13:51 +0000 (05:13 +0000)]
improve documentation of ObjCInterfaceType significantly. Also,
make the qual_* iterators and getNumProtocols() lists be accessible through
ObjCInterfaceType (returning an empty range if not a
ObjCQualifiedInterfaceType). This eliminates special checks in clients.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53830
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:59:05 +0000 (04:59 +0000)]
Fix a bunch of crashes that occur in (attempted) handling of objc properties.
This code would previously crash on x.y where x is 'id'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53827
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:54:33 +0000 (04:54 +0000)]
right, the error is when the itf *doesn't* have the member.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53826
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:44:44 +0000 (04:44 +0000)]
use the simplified form of lookupInstanceVariable for callers who
don't care which class actually defines it.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53825
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:42:08 +0000 (04:42 +0000)]
improve the diagnostic for an erroneous objc ivar reference
from:
t.m:8:7: error: member reference is not to a structure or union
pool->farm = 0;
^ ~~~~
to:
t.m:8:7: error: 'NSAutoreleasePool' has member named 'farm'
pool->farm = 0;
~~~~^ ~~~~
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53824
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:36:39 +0000 (04:36 +0000)]
simplify a bunch of code, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53823
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:28:12 +0000 (04:28 +0000)]
rearrange some code, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53822
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:16:33 +0000 (04:16 +0000)]
improve comments yet again, now I know what this does :)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53821
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:13:58 +0000 (04:13 +0000)]
minor rename, also, reject pointer to qualified id.
id<NSCopyable>* is not an "objc pointer type", id<NSCopyable> is.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53820
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:09:54 +0000 (04:09 +0000)]
Fix a crash that can happen when you have typedefs for pointers to
interfaces. Just because they x->isPointerType() doesn't mean it is
valid to just cast to a pointertype. We have to handle typedefs etc
as well.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53819
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:07:11 +0000 (04:07 +0000)]
improve comments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53818
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 21 Jul 2008 04:03:34 +0000 (04:03 +0000)]
simplify this predicate, only checking isObjCQualifiedIdType once.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53817
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 20 Jul 2008 04:22:06 +0000 (04:22 +0000)]
Add a space, ted apparently has philosophical problems with spaces ;-)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53808
91177308 -0d34-0410-b5e6-
96231b3b80d8
Nuno Lopes [Sat, 19 Jul 2008 22:11:43 +0000 (22:11 +0000)]
fix test
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53802
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Sat, 19 Jul 2008 19:50:00 +0000 (19:50 +0000)]
Updated latest checker build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53800
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Sat, 19 Jul 2008 19:10:40 +0000 (19:10 +0000)]
Patch by Kovarththanan Rajaratnam:
"When dumping the tokens (-dumptokens output type), the column numbers are not
correctly shown. This patch fixes that issue."
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53797
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Sat, 19 Jul 2008 19:10:04 +0000 (19:10 +0000)]
Patch by
"When dumping the tokens (-dumptokens output type), the column numbers are not
correctly shown. This patch fixes that issue."
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53796
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Sat, 19 Jul 2008 06:11:04 +0000 (06:11 +0000)]
Reimplement ccc-analyzer in a language I actually know, and implement some obvious optimizations when processing command line arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53783
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 23:13:03 +0000 (23:13 +0000)]
Remove typo.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53776
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 23:11:33 +0000 (23:11 +0000)]
Quote invocation of clang in pipe to handle paths with spaces.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53775
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 20:48:10 +0000 (20:48 +0000)]
Added test case.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53770
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 20:22:22 +0000 (20:22 +0000)]
Update checker build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53769
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 18:14:26 +0000 (18:14 +0000)]
"currentHandler" is a nullary selector
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53763
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 17:39:56 +0000 (17:39 +0000)]
Fix caching bug.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53759
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 17:24:20 +0000 (17:24 +0000)]
Add panic support for NSAssertionHandler.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53758
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jul 2008 16:38:05 +0000 (16:38 +0000)]
Prevent clang from emitting output when input has errors
+ test case
<rdar://problem/
6080040 >
http://llvm.org/bugs/show_bug.cgi?id=2280
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53756
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 16:28:33 +0000 (16:28 +0000)]
Add panic function.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53755
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 15:59:33 +0000 (15:59 +0000)]
Fix 80 col violation
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53754
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 15:54:51 +0000 (15:54 +0000)]
Fix regression by explicitly checking if we are negating a SymIntConstantVal.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53753
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 15:46:06 +0000 (15:46 +0000)]
Improve path-sensitivity when using the logical not operator.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53752
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 15:27:58 +0000 (15:27 +0000)]
Renamed deterministic EvalBinOp to DetermEvalBinOpNN. This name mangling is unfortunately needed because virtual methods with the same name can be hidden by subclasses.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53751
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 05:53:58 +0000 (05:53 +0000)]
Created ValueStateSet class to manage the creation of multiple states by a method.
Modified the new EvalBinOpNN to generate states instead of nodes. This is a much simpler interface and is what clients will want to do.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53750
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 18 Jul 2008 04:55:41 +0000 (04:55 +0000)]
Remove dead method.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53748
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mon P Wang [Fri, 18 Jul 2008 00:14:09 +0000 (00:14 +0000)]
Add support shufpd
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53747
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 23:33:10 +0000 (23:33 +0000)]
Update signature of EvalAssume.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53745
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 23:24:36 +0000 (23:24 +0000)]
Provide static methods in BinaryOperator to determine if an opcode is an equality opcode, a relational opcode, or a logical opcode.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53744
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 23:15:45 +0000 (23:15 +0000)]
Move GRTransferFunc* into ValueStateManager, and move the assumption logic there as well.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53743
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 22:41:39 +0000 (22:41 +0000)]
Added headers
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53742
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 21:36:43 +0000 (21:36 +0000)]
Remove redundant logic.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53740
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 21:27:31 +0000 (21:27 +0000)]
Begin major changes to EvalXXX methods in GRTransferFuncs. Currently some of the methods only return an RVal; we want them to be able to create an arbitrary number of states.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53739
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jul 2008 21:07:48 +0000 (21:07 +0000)]
Fix for codegen crash on multibit bool bitfield initialization
<rdar://problem/
6078606 >
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53737
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 18:38:48 +0000 (18:38 +0000)]
Moved RemoveDeadBindings logic for the contents of 'Store' to a virtual RemoveDeadBindings method in StoreManager.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53726
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 17 Jul 2008 18:35:12 +0000 (18:35 +0000)]
We now build universal binaries of the checker.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53725
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Thu, 17 Jul 2008 17:49:50 +0000 (17:49 +0000)]
Unify ctx_iterator/ctx_begin()/ctx_end() and iterator/begin()/end() so that a single iterator type is used for both traversing decls of the same declaration context *and* of the parent declaration contexts, depending on the value of the bool parameter 'LookInParentCtx' that is passed to IdentifierResolver::begin().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53724
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 22:35:27 +0000 (22:35 +0000)]
RewriteObjC::SynthMessageExpr(): Fix super rewrite (a fairly recent regression).
Fixes <rdar://problem/
6046663 > clang ObjC rewriter: Regression in handling of 'super' in latest build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53703
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Wed, 16 Jul 2008 21:01:53 +0000 (21:01 +0000)]
When in C++, make EnumConstant names hide tag names in the same scope, instead of colliding with them.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53702
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 19:47:39 +0000 (19:47 +0000)]
Remove a FIXME from RewriteObjC::RewriteObjCSynchronizedStmt().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53696
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 18:58:11 +0000 (18:58 +0000)]
RewriteObjC::Initialize(): add function decls used by @synchronized.
This fixes <rdar://problem/
6040143 > clang ObjC rewriter: @synchronized keyword inserts undeclared objc functions.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53695
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 18:22:22 +0000 (18:22 +0000)]
Two fixes:
- Make sure ObjCIvarDecl propagates the bitfield width.
- RewriteObjC::SynthesizeIvarOffsetComputation(): Avoid using the __OFFSETOF__ mumbo jumbo for bitfields (since it isn't legal C). This fixes <rdar://problem/
5986079 > clang ObjC rewriter: bitfields and ivar access don't mix.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53694
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 15:31:30 +0000 (15:31 +0000)]
RewriteObjC::RewriteObjCTryStmt():Don't synthesize a catch begin if there are 0 catch clauses.
This fixes <rdar://problem/
5987211 > clang ObjC rewriter: @try / @finally block produces unbalanced output.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53679
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Wed, 16 Jul 2008 14:40:40 +0000 (14:40 +0000)]
Teach RewriteObjC::RewriteObjCMethodDecl() to deal with pointer to function return types.
This fixes <rdar://problem/
6034961 > clang ObjC rewriter: rewriting methods with function pointer return values does not work
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53678
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Wed, 16 Jul 2008 07:45:46 +0000 (07:45 +0000)]
When checking for name collision between a tag and a previously defined namespace, the collision occured even when the tag was in a different nested scope.
Fix it by taking into account the scope when checking for namespace-tag name collisions.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53667
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Wed, 16 Jul 2008 07:23:27 +0000 (07:23 +0000)]
Add 'this' in the comments of Parser::ParseCastExpression to indicate that it is handled.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53665
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Wed, 16 Jul 2008 02:39:15 +0000 (02:39 +0000)]
Updated latest checker build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53664
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Wed, 16 Jul 2008 00:23:49 +0000 (00:23 +0000)]
Fix regression introduced by http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-
20080714 /006514.html.
The regression was the casts from integers to pointers where not being handled: they would just return UnknownVal. This would greatly decrease path-sensitivity.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53659
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 15 Jul 2008 23:41:32 +0000 (23:41 +0000)]
Have scan-build control default analyses.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53654
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 15 Jul 2008 23:17:54 +0000 (23:17 +0000)]
Fix transfer function logic in GRSimpleVals for integer casts: only support casts from integers to integers.
This fixes a crash reported by Anders Carlsson!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53649
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 15 Jul 2008 23:09:14 +0000 (23:09 +0000)]
Add -DIBOutlet=__attribute__((iboutlet)) to analyzer arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53648
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 15 Jul 2008 23:04:27 +0000 (23:04 +0000)]
For the MissingDealloc check, don't treat IBOutlet ivars as being needed to be released
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53647
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 15 Jul 2008 22:39:36 +0000 (22:39 +0000)]
Make iboutlet diagnostic lowercase
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53646
91177308 -0d34-0410-b5e6-
96231b3b80d8