]> granicus.if.org Git - clang/log
clang
15 years agoMove more of blocks codegen out of CodeGenModule and into the
Mike Stump [Wed, 4 Mar 2009 18:17:45 +0000 (18:17 +0000)]
Move more of blocks codegen out of CodeGenModule and into the
BlockModule.  No functionality change.  This should help people that
don't want to know anything about blocks not be confused by the
overloaded use of the term block or nor want to see all the blocks
goop.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66042 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoSome refactoring of recent code. No functionality change.
Fariborz Jahanian [Wed, 4 Mar 2009 18:15:57 +0000 (18:15 +0000)]
Some refactoring of recent code. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66041 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix a corner case of message lookup looking for class methods.
Fariborz Jahanian [Wed, 4 Mar 2009 17:50:39 +0000 (17:50 +0000)]
Fix a corner case of message lookup looking for class methods.
If all else failed, find the message in class's root's
list of instacne methods!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66040 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoSupport "asm" renaming of external symbols.
Daniel Dunbar [Wed, 4 Mar 2009 17:31:19 +0000 (17:31 +0000)]
Support "asm" renaming of external symbols.
 - PR3698.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66038 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoDriver: Add ArgList implementation.
Daniel Dunbar [Wed, 4 Mar 2009 17:10:42 +0000 (17:10 +0000)]
Driver: Add ArgList implementation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66037 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoGRExprEngine::VisitCast: Just pass through function and block pointers.
Ted Kremenek [Wed, 4 Mar 2009 16:52:57 +0000 (16:52 +0000)]
GRExprEngine::VisitCast: Just pass through function and block pointers.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66036 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoStart the migration of more of the blocks code out of sight for most
Mike Stump [Wed, 4 Mar 2009 15:35:22 +0000 (15:35 +0000)]
Start the migration of more of the blocks code out of sight for most
people.  De-duplicates BLOCK_NEEDS_FREE and friends.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66035 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoStart the migration of more of the blocks code out of sight for most
Mike Stump [Wed, 4 Mar 2009 15:32:52 +0000 (15:32 +0000)]
Start the migration of more of the blocks code out of sight for most
people.  De-duplicates BLOCK_NEEDS_FREE and friends.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66034 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFinish up some fixes related to <rdar://problem/6497631> Message lookup is sometimes...
Steve Naroff [Wed, 4 Mar 2009 15:11:40 +0000 (15:11 +0000)]
Finish up some fixes related to <rdar://problem/6497631> Message lookup is sometimes different than gcc's.

- Disallow casting 'super'. GCC allows this, however it doesn't make sense (super isn't an expression and the cast won't alter lookup/dispatch).
- Tighten up lookup when messaging 'self'.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66033 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd __block codegen testcase. We introduce a temporary flag to enable
Mike Stump [Wed, 4 Mar 2009 13:17:22 +0000 (13:17 +0000)]
Add __block codegen testcase.  We introduce a temporary flag to enable
codegen, until such time as codegen is complete enough to turn on with
-fblocks.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66031 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoDriver: More Option implementation.
Daniel Dunbar [Wed, 4 Mar 2009 08:33:23 +0000 (08:33 +0000)]
Driver: More Option implementation.
 - Add Options.def file, collects option information.

 - Actual option instantiation is handled lazily by OptTable to allow
   the driver to not need to instantiate all options.

 - cast<> support for Option, other minor tweaks.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66028 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoCheck that the return type for function definitions is complete.
Eli Friedman [Wed, 4 Mar 2009 07:30:59 +0000 (07:30 +0000)]
Check that the return type for function definitions is complete.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66027 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agomake the token lexer allocate its temporary token buffers for
Chris Lattner [Wed, 4 Mar 2009 06:50:57 +0000 (06:50 +0000)]
make the token lexer allocate its temporary token buffers for
preexpanded macro arguments from the preprocessor's bump pointer.
This reduces # mallocs from 12444 to 11792.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66025 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoSwitch attributes to be allocated from the declcontext bump pointer just like
Chris Lattner [Wed, 4 Mar 2009 06:34:08 +0000 (06:34 +0000)]
Switch attributes to be allocated from the declcontext bump pointer just like
decls.  This reduces the number of calls to malloc on cocoa.h with pth and
-disable-free from 15958 to 12444 times (down ~3500).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66023 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdjust indentation.
Zhongxing Xu [Wed, 4 Mar 2009 06:33:38 +0000 (06:33 +0000)]
Adjust indentation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66022 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoadd an a Attr::Destroy method and force clients to go through it. As part of
Chris Lattner [Wed, 4 Mar 2009 06:05:19 +0000 (06:05 +0000)]
add an a Attr::Destroy method and force clients to go through it.  As part of
this, make DeclBase::Destroy destroy attributes instead of the DeclBase dtor.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66020 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoMake this test a bit more specific about the target so that it passes on
Eli Friedman [Wed, 4 Mar 2009 06:00:10 +0000 (06:00 +0000)]
Make this test a bit more specific about the target so that it passes on
Linux.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66019 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoMinor cleanup for choose expressions: add a helper that returns the
Eli Friedman [Wed, 4 Mar 2009 05:52:32 +0000 (05:52 +0000)]
Minor cleanup for choose expressions: add a helper that returns the
chosen sub-expression, rather than just evaluating the condition.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66018 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoallocate MultiKeywordSelector's out of a bump pointer allocator instead of malloc.
Chris Lattner [Wed, 4 Mar 2009 05:35:38 +0000 (05:35 +0000)]
allocate MultiKeywordSelector's out of a bump pointer allocator instead of malloc.
This has two advantages 1) no more leaking them, 2) fewer calls to malloc.

This changes us from calling malloc 3685/1390/883/2974/1185 times respectively on
16/20/24/28/32 byte objects when parsing cocoa.h with pth and -disable-free to
calling it 2816/1020/702/2903/1168 times each respectively.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66017 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agosimplify Sema::AddInstanceMethodToGlobalPool, no functionality change.
Chris Lattner [Wed, 4 Mar 2009 05:16:45 +0000 (05:16 +0000)]
simplify Sema::AddInstanceMethodToGlobalPool, no functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66016 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoadd a special case for codegen that improves the case where we have
Chris Lattner [Wed, 4 Mar 2009 04:46:18 +0000 (04:46 +0000)]
add a special case for codegen that improves the case where we have
multiple sequential cases to a) not create tons of fall-through basic blocks
and b) not recurse deeply.  This fixes codegen on 100K deep cases, and improves
codegen on moderate cases from this:

        switch i32 %tmp, label %sw.epilog [
                i32 1000, label %sw.bb
                i32 1001, label %sw.bb1
                i32 1002, label %sw.bb2
                i32 1003, label %sw.bb3
                i32 1004, label %sw.bb4
...
sw.bb:          ; preds = %entry
        br label %sw.bb1

sw.bb1:         ; preds = %entry, %sw.bb
        br label %sw.bb2

sw.bb2:         ; preds = %entry, %sw.bb1
        br label %sw.bb3

sw.bb3:         ; preds = %entry, %sw.bb2
        br label %sw.bb4

to:

        switch i32 %tmp, label %sw.epilog [
                i32 1000, label %sw.bb
                i32 1001, label %sw.bb
                i32 1002, label %sw.bb
                i32 1003, label %sw.bb
                i32 1004, label %sw.bb
sw.bb:  ;; many preds

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66015 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agofix infinite recursion
Chris Lattner [Wed, 4 Mar 2009 04:30:02 +0000 (04:30 +0000)]
fix infinite recursion

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66014 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agomake CaseStmt::getSourceRange() iterative for deeply
Chris Lattner [Wed, 4 Mar 2009 04:26:45 +0000 (04:26 +0000)]
make CaseStmt::getSourceRange() iterative for deeply
nested cases instead of recursive.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66013 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoContinuation of PR3687: fix more places to use the right type for
Eli Friedman [Wed, 4 Mar 2009 04:25:14 +0000 (04:25 +0000)]
Continuation of PR3687: fix more places to use the right type for
booleans.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66012 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoChange Parser::ParseCaseStatement to use an iterative approach to parsing
Chris Lattner [Wed, 4 Mar 2009 04:23:07 +0000 (04:23 +0000)]
Change Parser::ParseCaseStatement to use an iterative approach to parsing
multiple sequential case statements instead of doing it with recursion.  This
fixes a problem where we run out of stack space parsing 100K directly nested
cases.

There are a couple other problems that prevent this from being useful in
practice (right now the example only parses correctly with -disable-free and
doesn't work with -emit-llvm), but this is a start.

I'm not including a testcase because it is large and uninteresting for
regtesting.

Sebastian, I would appreciate it if you could scrutinize the smart pointer
gymnastics I do.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66011 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoComment fix: change a question to an answer.
Eli Friedman [Wed, 4 Mar 2009 04:22:58 +0000 (04:22 +0000)]
Comment fix: change a question to an answer.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66010 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAttempt to fix PR3709: when converting from an integer to a pointer,
Eli Friedman [Wed, 4 Mar 2009 04:02:35 +0000 (04:02 +0000)]
Attempt to fix PR3709: when converting from an integer to a pointer,
first extend the integer to the correct width.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66009 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoImproved ABI compliance for __block variables. No testcases yet as we
Mike Stump [Wed, 4 Mar 2009 03:23:46 +0000 (03:23 +0000)]
Improved ABI compliance for __block variables.  No testcases yet as we
still give an unsupported error for them due to the fact this is a
work in progress.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66007 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdded the notion of a "boundable region", which is a region that can have a direct...
Ted Kremenek [Wed, 4 Mar 2009 02:43:08 +0000 (02:43 +0000)]
Added the notion of a "boundable region", which is a region that can have a direct binding in the StoreManager.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66005 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd some more FIXME's about bits we could pack better.
Daniel Dunbar [Wed, 4 Mar 2009 02:27:50 +0000 (02:27 +0000)]
Add some more FIXME's about bits we could pack better.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66003 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoWoot, save 8 bytes in Decl on 64-bit by reordering fields. This
Daniel Dunbar [Wed, 4 Mar 2009 02:26:41 +0000 (02:26 +0000)]
Woot, save 8 bytes in Decl on 64-bit by reordering fields. This
reduces allocated Decl size by ~8% on Cocoa.h (~700k).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66002 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoThis test now passes using RegionStore.
Ted Kremenek [Wed, 4 Mar 2009 00:23:28 +0000 (00:23 +0000)]
This test now passes using RegionStore.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65988 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoRegionStore: Handle implicit parameters.
Ted Kremenek [Wed, 4 Mar 2009 00:23:05 +0000 (00:23 +0000)]
RegionStore: Handle implicit parameters.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65987 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoCreate "TypedViewRegions" that layer on top of SymbolicRegions when handling
Ted Kremenek [Wed, 4 Mar 2009 00:14:35 +0000 (00:14 +0000)]
Create "TypedViewRegions" that layer on top of SymbolicRegions when handling
pointer-to-pointer casts involving symbolic locations.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65984 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoUse GetSValAsScalarOrLoc instead of GetSVal to prevent unintended structure or array...
Ted Kremenek [Wed, 4 Mar 2009 00:13:50 +0000 (00:13 +0000)]
Use GetSValAsScalarOrLoc instead of GetSVal to prevent unintended structure or array "loads".

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65983 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd "GetSValAsScalarOrLoc" methods to GRState/GRStateRef that only perform a
Ted Kremenek [Wed, 4 Mar 2009 00:13:10 +0000 (00:13 +0000)]
Add "GetSValAsScalarOrLoc" methods to GRState/GRStateRef that only perform a
retrieval from the store/environment for locations or scalar types.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65982 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoRegionStore::RemoveDeadBindings needs to check all the symbols of the super region...
Ted Kremenek [Wed, 4 Mar 2009 00:11:38 +0000 (00:11 +0000)]
RegionStore::RemoveDeadBindings needs to check all the symbols of the super region of a scanned region as well.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65981 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd new performance numbers; no discussion yet. Obvious two
Daniel Dunbar [Wed, 4 Mar 2009 00:04:28 +0000 (00:04 +0000)]
Add new performance numbers; no discussion yet. Obvious two
conclusions are our PCH generation is way faster than gcc, and the
Python based driver kills compile times.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65980 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoChange a warning to an error...
Steve Naroff [Tue, 3 Mar 2009 23:13:51 +0000 (23:13 +0000)]
Change a warning to an error...

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65978 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoImplement an important missing warning when a selector
Fariborz Jahanian [Tue, 3 Mar 2009 22:19:15 +0000 (22:19 +0000)]
Implement an important missing warning when a selector
is searched for in the global pool. It already uncovered
a clang bug in message selection.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65974 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/5982579> [clang on xcode] (using arch=x86_64): synthesized proper...
Steve Naroff [Tue, 3 Mar 2009 22:09:41 +0000 (22:09 +0000)]
Fix <rdar://problem/5982579> [clang on xcode] (using arch=x86_64): synthesized property 'sdkPath' must either be named the same as a compatible ivar or must explicitly name an ivar.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65973 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoRework use of loc::SymbolVal in the retain/release checker to use the new method
Ted Kremenek [Tue, 3 Mar 2009 22:06:47 +0000 (22:06 +0000)]
Rework use of loc::SymbolVal in the retain/release checker to use the new method
SVal::getAsLocSymbol(). This simplifies the code and allows the retain/release
checker to (I believe) also correctly reason about location symbols wrapped in
SymbolicRegions.

Along the way I cleaned up SymbolRef a little, disallowing implicit casts to
'unsigned'.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65972 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6252237> [sema] qualified id should be disallowed in @catch state...
Steve Naroff [Tue, 3 Mar 2009 21:16:54 +0000 (21:16 +0000)]
Fix <rdar://problem/6252237> [sema] qualified id should be disallowed in @catch statements.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65969 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6632061> [sema] non object types should not be allowed in @catch...
Steve Naroff [Tue, 3 Mar 2009 20:59:06 +0000 (20:59 +0000)]
Fix <rdar://problem/6632061> [sema] non object types should not be allowed in @catch statements.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65968 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoimplement support for propagating *features* down to the code generator
Chris Lattner [Tue, 3 Mar 2009 19:56:18 +0000 (19:56 +0000)]
implement support for propagating *features* down to the code generator
and defining target-specific macros based on them (like __SSE3__ and
friends).  After extensive discussion with Daniel, this work will need
driver support, which will translate things like -msse3 into a -mattr
feature.  Until this work is done, the code in clang.cpp is disabled and
the X86TargetInfo ctor still defaults to SSE2.  With these two things
changed, this code will work.  PR3634

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65966 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6640991> Exception handling executes wrong clause (Daniel, please...
Steve Naroff [Tue, 3 Mar 2009 19:52:17 +0000 (19:52 +0000)]
Fix <rdar://problem/6640991> Exception handling executes wrong clause (Daniel, please verify).

Also necessary to fix:

<rdar://problem/6632061> [sema] non object types should not be allowed in @catch statements
<rdar://problem/6252237> [sema] qualified id should be disallowed in @catch statements

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65964 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoDon't use std::auto_ptr with getSubRegionMap().
Ted Kremenek [Tue, 3 Mar 2009 19:02:42 +0000 (19:02 +0000)]
Don't use std::auto_ptr with getSubRegionMap().

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65957 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix case where we should use dyn_cast instead of cast.
Ted Kremenek [Tue, 3 Mar 2009 19:01:37 +0000 (19:01 +0000)]
Fix case where we should use dyn_cast instead of cast.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65956 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFixed an ir-gen bug in syntheszing a getter function
Fariborz Jahanian [Tue, 3 Mar 2009 18:49:40 +0000 (18:49 +0000)]
Fixed an ir-gen bug in syntheszing a getter function
with property type which does not match its ivar and
in -fobjc-gc-only mode!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65955 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix extra ';' bug noticed by Mike Stump.
Ted Kremenek [Tue, 3 Mar 2009 18:15:30 +0000 (18:15 +0000)]
Fix extra ';' bug noticed by Mike Stump.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65954 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoHush gcc.
Daniel Dunbar [Tue, 3 Mar 2009 16:54:38 +0000 (16:54 +0000)]
Hush gcc.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65952 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoReturn 0 if the ConstExprEmitter can't handle an expression.
Anders Carlsson [Tue, 3 Mar 2009 16:43:34 +0000 (16:43 +0000)]
Return 0 if the ConstExprEmitter can't handle an expression.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65951 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoRemove old/incorrect warnings.
Steve Naroff [Tue, 3 Mar 2009 15:49:23 +0000 (15:49 +0000)]
Remove old/incorrect warnings.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65950 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6497242> Inherited overridden protocol declared objects don't...
Steve Naroff [Tue, 3 Mar 2009 15:43:24 +0000 (15:43 +0000)]
Fix <rdar://problem/6497242> Inherited overridden protocol declared objects don't work.

Change Sema::DiagnosePropertyMismatch() to check for type compatibility (rather than type equivalence, which is too strict).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65949 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6497608> clang does not catch ivar type mismatches in @implementa...
Steve Naroff [Tue, 3 Mar 2009 14:49:36 +0000 (14:49 +0000)]
Fix <rdar://problem/6497608> clang does not catch ivar type mismatches in @implementation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65948 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoDriver: Sketch Arg & ArgList classes.
Daniel Dunbar [Tue, 3 Mar 2009 07:34:45 +0000 (07:34 +0000)]
Driver: Sketch Arg & ArgList classes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65937 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoPR3691: Add support for complex modes. I also tossed in support for XF
Eli Friedman [Tue, 3 Mar 2009 06:41:03 +0000 (06:41 +0000)]
PR3691: Add support for complex modes.  I also tossed in support for XF
while I was at it.  There are still a lot of diagnostics missing from
this code, and it isn't completely correct for anything other than x86, but
it should work correctly on x86 for valid cases.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65935 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoSketch Driver Option classes.
Daniel Dunbar [Tue, 3 Mar 2009 05:55:11 +0000 (05:55 +0000)]
Sketch Driver Option classes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65933 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoSet svn:ignore on Output dir
Daniel Dunbar [Tue, 3 Mar 2009 05:53:50 +0000 (05:53 +0000)]
Set svn:ignore on Output dir

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65932 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix for PR3687: use the memory representation for booleans when a
Eli Friedman [Tue, 3 Mar 2009 04:48:01 +0000 (04:48 +0000)]
Fix for PR3687: use the memory representation for booleans when a
sub-type describes a memory location, like the pointee type of a pointer
or the element type of an array.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65925 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoImplement the basics of implicit instantiation of class templates, in
Douglas Gregor [Tue, 3 Mar 2009 04:44:36 +0000 (04:44 +0000)]
Implement the basics of implicit instantiation of class templates, in
response to attempts to diagnose an "incomplete" type. This will force
us to use DiagnoseIncompleteType more regularly (rather than looking at
isIncompleteType), but that's also a good thing.

Implicit instantiation is still very simplistic, and will create a new
definition for the class template specialization (as it should) but it
only actually instantiates the base classes and attaches
those. Actually instantiating class members will follow.

Also, instantiate the types of non-type template parameters before
checking them,  allowing, e.g.,

  template<typename T, T Value> struct Constant;

to work properly.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65924 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoTighten message bubble height.
Ted Kremenek [Tue, 3 Mar 2009 03:00:21 +0000 (03:00 +0000)]
Tighten message bubble height.
Make bubble number decoration look more like circles than ovals.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65921 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoImplement FIXME: GRStateManager::scanReachableSymbols now supports scanning MemRegions.
Ted Kremenek [Tue, 3 Mar 2009 02:51:43 +0000 (02:51 +0000)]
Implement FIXME: GRStateManager::scanReachableSymbols now supports scanning MemRegions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65919 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoUpdate checker build.
Ted Kremenek [Tue, 3 Mar 2009 01:44:57 +0000 (01:44 +0000)]
Update checker build.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65916 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd StoreManager::getSubRegionMap(). This method returns an opaque mapping for clien...
Ted Kremenek [Tue, 3 Mar 2009 01:35:36 +0000 (01:35 +0000)]
Add StoreManager::getSubRegionMap().  This method returns an opaque mapping for clients of StoreManagers from MemRegions to their subregions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65914 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoCheck of ivar access access control.
Fariborz Jahanian [Tue, 3 Mar 2009 01:21:12 +0000 (01:21 +0000)]
Check of ivar access access control.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65912 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6635908> crash on invalid
Steve Naroff [Tue, 3 Mar 2009 00:45:38 +0000 (00:45 +0000)]
Fix <rdar://problem/6635908> crash on invalid

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65909 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd test case for pointer arithmetic.
Zhongxing Xu [Tue, 3 Mar 2009 00:28:42 +0000 (00:28 +0000)]
Add test case for pointer arithmetic.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65907 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agofix PR#
Chris Lattner [Tue, 3 Mar 2009 00:00:26 +0000 (00:00 +0000)]
fix PR#

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65906 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdjust CSS to make message bubble numbers less gaudy.
Ted Kremenek [Mon, 2 Mar 2009 23:39:27 +0000 (23:39 +0000)]
Adjust CSS to make message bubble numbers less gaudy.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65903 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoResize message bubble back to original size.
Ted Kremenek [Mon, 2 Mar 2009 23:06:15 +0000 (23:06 +0000)]
Resize message bubble back to original size.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65892 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdjust HTML message bubbles to utilize information from PathDiagnosticPiece::Kind.
Ted Kremenek [Mon, 2 Mar 2009 23:05:40 +0000 (23:05 +0000)]
Adjust HTML message bubbles to utilize information from PathDiagnosticPiece::Kind.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65891 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd plumbing to support programatically defining __SSE2__ and friends,
Chris Lattner [Mon, 2 Mar 2009 22:40:39 +0000 (22:40 +0000)]
Add plumbing to support programatically defining __SSE2__ and friends,
even though we still hard code sse2 for now.  No support for 3dnow or sse4a,
but someone could add that if they desired.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65886 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agominor cleanups to target-specific #defines, no functionality change.
Chris Lattner [Mon, 2 Mar 2009 22:27:17 +0000 (22:27 +0000)]
minor cleanups to target-specific #defines, no functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65885 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoimprove compatibility with GCC 4.4, patch by Michel Salim (PR3697)
Chris Lattner [Mon, 2 Mar 2009 22:20:04 +0000 (22:20 +0000)]
improve compatibility with GCC 4.4, patch by Michel Salim (PR3697)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65884 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agostart wiring up support for target-specific -mfoo options like -msse
Chris Lattner [Mon, 2 Mar 2009 22:11:07 +0000 (22:11 +0000)]
start wiring up support for target-specific -mfoo options like -msse

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65881 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix <rdar://problem/6636803> [sema] crash on InterfaceBuilder.
Steve Naroff [Mon, 2 Mar 2009 22:00:56 +0000 (22:00 +0000)]
Fix <rdar://problem/6636803> [sema] crash on InterfaceBuilder.

Parser::ParseObjCMethodDefinition(): Make sure we don't exit the BodyScope until ActOnFinishFunctionBody() is complete.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65880 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoDiagnose a variety of access of ivars when they conflict with
Fariborz Jahanian [Mon, 2 Mar 2009 21:55:29 +0000 (21:55 +0000)]
Diagnose a variety of access of ivars when they conflict with
local or global variables in instance/class methods.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65879 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoPlist diagnostics now include PathDiagnostPiece::Kind.
Ted Kremenek [Mon, 2 Mar 2009 21:44:02 +0000 (21:44 +0000)]
Plist diagnostics now include PathDiagnostPiece::Kind.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65878 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoUpdate HTML diagnostics to honor the different between 'event' and 'control-flow...
Ted Kremenek [Mon, 2 Mar 2009 21:42:01 +0000 (21:42 +0000)]
Update HTML diagnostics to honor the different between 'event' and 'control-flow' diagnostics.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65877 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoBugReporter: Construct path-related PathDiagnosticPieces with kind "ControlFlow".
Ted Kremenek [Mon, 2 Mar 2009 21:41:18 +0000 (21:41 +0000)]
BugReporter: Construct path-related PathDiagnosticPieces with kind "ControlFlow".

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65876 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoUpdate Xcode project.
Ted Kremenek [Mon, 2 Mar 2009 21:00:12 +0000 (21:00 +0000)]
Update Xcode project.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65870 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agofix PR2639
Chris Lattner [Mon, 2 Mar 2009 20:58:48 +0000 (20:58 +0000)]
fix PR2639

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65869 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoStub out some structure for C++ driver.
Daniel Dunbar [Mon, 2 Mar 2009 19:59:07 +0000 (19:59 +0000)]
Stub out some structure for C++ driver.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65867 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoinline asm calls should be nounwind. Chris, please review.
Anders Carlsson [Mon, 2 Mar 2009 19:58:15 +0000 (19:58 +0000)]
inline asm calls should be nounwind. Chris, please review.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65866 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix name.
Daniel Dunbar [Mon, 2 Mar 2009 19:50:00 +0000 (19:50 +0000)]
Fix name.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65865 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoUpdate Xcode project.
Ted Kremenek [Mon, 2 Mar 2009 19:41:07 +0000 (19:41 +0000)]
Update Xcode project.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65863 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAdd a 'kind' field to PathDiagnosticPieces.
Ted Kremenek [Mon, 2 Mar 2009 19:40:38 +0000 (19:40 +0000)]
Add a 'kind' field to PathDiagnosticPieces.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65862 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFor now, do not output the 'DisplayHint' in plist files.
Ted Kremenek [Mon, 2 Mar 2009 19:40:15 +0000 (19:40 +0000)]
For now, do not output the 'DisplayHint' in plist files.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65861 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFor now, do not output the 'DisplayHint' in plist files.
Ted Kremenek [Mon, 2 Mar 2009 19:39:50 +0000 (19:39 +0000)]
For now, do not output the 'DisplayHint' in plist files.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65860 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFixed a typo.
Fariborz Jahanian [Mon, 2 Mar 2009 19:06:08 +0000 (19:06 +0000)]
Fixed a typo.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65855 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoCheck for duplicate declaration of method of a class
Fariborz Jahanian [Mon, 2 Mar 2009 19:05:07 +0000 (19:05 +0000)]
Check for duplicate declaration of method of a class
in its extension.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65854 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoNormalize .h guards.
Daniel Dunbar [Mon, 2 Mar 2009 18:59:45 +0000 (18:59 +0000)]
Normalize .h guards.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65853 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAttempt to make test more robust (fails for users who put LLVM in
Daniel Dunbar [Mon, 2 Mar 2009 18:50:36 +0000 (18:50 +0000)]
Attempt to make test more robust (fails for users who put LLVM in
/path/with/store/in/it").

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65852 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoEnable Objective-C interface debug info.
Devang Patel [Mon, 2 Mar 2009 17:58:28 +0000 (17:58 +0000)]
Enable Objective-C interface debug info.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65850 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoFix cmake builds.
Mike Stump [Mon, 2 Mar 2009 17:05:26 +0000 (17:05 +0000)]
Fix cmake builds.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65847 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoremove an implemented fixme.
Zhongxing Xu [Mon, 2 Mar 2009 08:25:09 +0000 (08:25 +0000)]
remove an implemented fixme.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65817 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoInitial support for pointer arithmetic. Only support concrete indexes and
Zhongxing Xu [Mon, 2 Mar 2009 07:52:23 +0000 (07:52 +0000)]
Initial support for pointer arithmetic. Only support concrete indexes and
offsets for now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65814 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoAvoid crash when child iterator gives null result.
Daniel Dunbar [Mon, 2 Mar 2009 07:00:57 +0000 (07:00 +0000)]
Avoid crash when child iterator gives null result.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65812 91177308-0d34-0410-b5e6-96231b3b80d8

15 years agoRename lib/Driver (etc) to lib/Frontend in prep for the *actual*
Daniel Dunbar [Mon, 2 Mar 2009 06:16:29 +0000 (06:16 +0000)]
Rename lib/Driver (etc) to lib/Frontend in prep for the *actual*
driver taking lib/Driver.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65811 91177308-0d34-0410-b5e6-96231b3b80d8