Re: [cfe-commits] [PATCH] [CMake] Move libxml2 stuff from clang to llvm/cmake.

2012-12-14 Thread Michael Spencer
Comment at: llvm/cmake/config-ix.cmake:297 @@ -296,1 +296,3 @@ +find_package(LibXml2) +if (LIBXML2_FOUND) I wonder about this being in config-ix.cmake. It's not how it's generally done in CMake. http://llvm-reviews.chandlerc.com/D170

Re: [cfe-commits] [PATCH] Warn is -isysroot is given an invalid path

2012-12-14 Thread Joerg Sonnenberger
On Thu, Dec 13, 2012 at 04:54:33PM -0800, Chad Rosier wrote: The attached patch emits a warning in the frontend if the -isysroot flag is given an invalid directory. I can imagine use cases for --sysroot at the very least where the path doesn't exist during early bootstrap. I would imagine

Re: [cfe-commits] [PATCH] [CMake] Move libxml2 stuff from clang to llvm/cmake.

2012-12-14 Thread Michael Spencer
After looking at config-ix.cmake in full, I retract my other comment. LGTM. http://llvm-reviews.chandlerc.com/D170 ___ cfe-commits mailing list cfe-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

[cfe-commits] r170188 - /cfe/trunk/lib/Basic/Targets.cpp

2012-12-14 Thread NAKAMURA Takumi
Author: chapuni Date: Fri Dec 14 04:17:26 2012 New Revision: 170188 URL: http://llvm.org/viewvc/llvm-project?rev=170188view=rev Log: Targets.cpp: [cygwin] Add the predefined macro _X86_, according to newer version of cygwin/w32api. Modified: cfe/trunk/lib/Basic/Targets.cpp Modified:

[cfe-commits] [PATCH] [Valgrind] Don't read beyond SourceLineCache

2012-12-14 Thread NAKAMURA Takumi
Hi doug.gregor, It fixes dozen of failures with --vg. I have no idea whether it would be right thing. Or, in ComputeLineNumbers(), should LineOffsets have a sentinel in its tail? http://llvm-reviews.chandlerc.com/D217 Files: clang/lib/Basic/SourceManager.cpp Index:

Re: [cfe-commits] [patch] Allow vectoridprotocol in objc++11

2012-12-14 Thread jahanian
On Dec 13, 2012, at 7:45 PM, Richard Smith rich...@metafoo.co.uk wrote: On Thu, Dec 13, 2012 at 7:26 PM, Nico Weber tha...@chromium.org wrote: Hi, C++11 allowed writing vectorvectorint without a space between and . Objective-C++11 doesn't seem to allow vectoridprotocol though, and the

[cfe-commits] [PATCH] [Valgrind][check-clang] Optional.h: Appease Valgrind

2012-12-14 Thread NAKAMURA Takumi
It seems small bitfield confuses valgrind. This patch makes a bitfiled to (valgrind-recognizable) i8 size. I am using; valgrind-3.6.0 x86-64 It caused bunch of failures in clang/test/Modules with --vg. http://llvm-reviews.chandlerc.com/D218 Files: llvm/include/llvm/ADT/Optional.h Index:

Re: [cfe-commits] [PATCH] Warn is -isysroot is given an invalid path

2012-12-14 Thread Chad Rosier
On Dec 13, 2012, at 10:30 PM, Eric Christopher echri...@gmail.com wrote: On Thu, Dec 13, 2012 at 4:54 PM, Chad Rosier mcros...@apple.com wrote: All, The attached patch emits a warning in the frontend if the -isysroot flag is given an invalid directory. I've implemented this using

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Chad Rosier
On Dec 14, 2012, at 9:14 AM, Eric Christopher echri...@gmail.com wrote: On Fri, Dec 14, 2012 at 9:08 AM, Chad Rosier mcros...@apple.com wrote: On Dec 13, 2012, at 10:30 PM, Eric Christopher echri...@gmail.com wrote: On Thu, Dec 13, 2012 at 4:54 PM, Chad Rosier mcros...@apple.com

Re: [cfe-commits] [PATCH] Warn is -isysroot is given an invalid path

2012-12-14 Thread Eric Christopher
On Fri, Dec 14, 2012 at 9:08 AM, Chad Rosier mcros...@apple.com wrote: On Dec 13, 2012, at 10:30 PM, Eric Christopher echri...@gmail.com wrote: On Thu, Dec 13, 2012 at 4:54 PM, Chad Rosier mcros...@apple.com wrote: All, The attached patch emits a warning in the frontend if the -isysroot

Re: [cfe-commits] [patch] Allow vectoridprotocol in objc++11

2012-12-14 Thread Jordan Rose
A better way to write the test cases is to only put the expectations in the #if (using @OFFSET), and use the same set of test cases for C++11 and C++98. Other than that, seems like a good improvement. Thanks, Nico! Jordan On Dec 13, 2012, at 19:26 , Nico Weber tha...@chromium.org wrote: Hi,

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Jordan Rose
I can see bootstrapping scenarios such that you wouldn't want it. Possible to only put this warning into -Weverything and not into any other warning level? (TBH I didn't look at the patch so you may have done this…) I didn't put it under -Weverything, but that's a good suggestion. Thanks,

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Chad Rosier
On Dec 14, 2012, at 9:29 AM, Jordan Rose jordan_r...@apple.com wrote: I can see bootstrapping scenarios such that you wouldn't want it. Possible to only put this warning into -Weverything and not into any other warning level? (TBH I didn't look at the patch so you may have done this…) I

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Jordan Rose
On Dec 14, 2012, at 9:31 , Chad Rosier mcros...@apple.com wrote: On Dec 14, 2012, at 9:29 AM, Jordan Rose jordan_r...@apple.com wrote: I can see bootstrapping scenarios such that you wouldn't want it. Possible to only put this warning into -Weverything and not into any other warning

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Eric Christopher
On Fri, Dec 14, 2012 at 9:29 AM, Jordan Rose jordan_r...@apple.com wrote: I can see bootstrapping scenarios such that you wouldn't want it. Possible to only put this warning into -Weverything and not into any other warning level? (TBH I didn't look at the patch so you may have done this…) I

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Bob Wilson
On Dec 14, 2012, at 9:34 AM, Eric Christopher echri...@gmail.com wrote: On Fri, Dec 14, 2012 at 9:29 AM, Jordan Rose jordan_r...@apple.com wrote: I can see bootstrapping scenarios such that you wouldn't want it. Possible to only put this warning into -Weverything and not into any other

Re: [cfe-commits] [patch] Allow vectoridprotocol in objc++11

2012-12-14 Thread Nico Weber
r170223, thanks! On Fri, Dec 14, 2012 at 9:26 AM, Jordan Rose jordan_r...@apple.com wrote: A better way to write the test cases is to only put the expectations in the #if (using @OFFSET), and use the same set of test cases for C++11 and C++98. Done. Other than that, seems like a good

[cfe-commits] r170223 - in /cfe/trunk: include/clang/Parse/Parser.h lib/Parse/ParseObjc.cpp lib/Parse/ParseTemplate.cpp test/Parser/objcxx11-protocol-in-template.mm

2012-12-14 Thread Nico Weber
Author: nico Date: Fri Dec 14 12:22:38 2012 New Revision: 170223 URL: http://llvm.org/viewvc/llvm-project?rev=170223view=rev Log: Don't require a space between the two in vectoridprotocol in objc++11. C++11 allowed writing vectorvectorint without a space between the two . This change allows

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Argyrios Kyrtzidis
On Dec 14, 2012, at 9:55 AM, Bob Wilson bob.wil...@apple.com wrote: On Dec 14, 2012, at 9:34 AM, Eric Christopher echri...@gmail.com wrote: On Fri, Dec 14, 2012 at 9:29 AM, Jordan Rose jordan_r...@apple.com wrote: I can see bootstrapping scenarios such that you wouldn't want it.

Re: [cfe-commits] [PATCH] Implement AST dumper for Decls

2012-12-14 Thread Alexander Kornienko
I have no concerns except for a couple minor things in inline comments. But this patch needs Doug's review as well. Comment at: lib/AST/ASTDumper.cpp:73 @@ -68,2 +72,3 @@ void dumpType(QualType T); -void dumpDeclRef(Decl *node); +void dumpBareDeclRef(Decl

[cfe-commits] r170225 - in /cfe/trunk: CMakeLists.txt tools/c-index-test/CMakeLists.txt

2012-12-14 Thread NAKAMURA Takumi
Author: chapuni Date: Fri Dec 14 12:30:20 2012 New Revision: 170225 URL: http://llvm.org/viewvc/llvm-project?rev=170225view=rev Log: [CMake] Move libxml2 stuff from clang to llvm/cmake. Modified: cfe/trunk/CMakeLists.txt cfe/trunk/tools/c-index-test/CMakeLists.txt Modified:

Re: [cfe-commits] [PATCH] [CMake] Move libxml2 stuff from clang to llvm/cmake.

2012-12-14 Thread NAKAMURA Takumi
Committed in r170225 (clang, lllvm), thank you! http://llvm-reviews.chandlerc.com/D170 ___ cfe-commits mailing list cfe-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Bob Wilson
On Dec 14, 2012, at 10:28 AM, Argyrios Kyrtzidis akyr...@gmail.com wrote: On Dec 14, 2012, at 9:55 AM, Bob Wilson bob.wil...@apple.com wrote: On Dec 14, 2012, at 9:34 AM, Eric Christopher echri...@gmail.com wrote: On Fri, Dec 14, 2012 at 9:29 AM, Jordan Rose jordan_r...@apple.com

Re: [cfe-commits] [PATCH] [Valgrind][check-clang] Optional.h: Appease Valgrind

2012-12-14 Thread Argyrios Kyrtzidis
This looks like 'hasVal' can be bool, and OptionalT specialized to contain a PointerIntPair if T is pointer; any objections ? On Dec 14, 2012, at 9:02 AM, NAKAMURA Takumi geek4ci...@gmail.com wrote: It seems small bitfield confuses valgrind. This patch makes a bitfiled to

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Eric Christopher
Sure, but I just don't see that providing much value. The point of adding a warning was to help catch things like typos in the sysroot path. What are the chances that someone is going to mis-type the sysroot and also specify -Wmissing-sysroot? I'm assuming that typos are most likely to come

Re: [cfe-commits] [llvm-commits] [PATCH] [Valgrind][check-clang] Optional.h: Appease Valgrind

2012-12-14 Thread David Blaikie
On Fri, Dec 14, 2012 at 10:38 AM, Argyrios Kyrtzidis akyr...@gmail.com wrote: This looks like 'hasVal' can be bool, and OptionalT specialized to contain a PointerIntPair if T is pointer; any objections ? Benjamin I have tossed around similar ideas on IRC last week - doesn't seem like an

[cfe-commits] r170228 - in /cfe/trunk: lib/Lex/PPMacroExpansion.cpp test/Preprocessor/macro_fn.c

2012-12-14 Thread Argyrios Kyrtzidis
Author: akirtzidis Date: Fri Dec 14 12:53:47 2012 New Revision: 170228 URL: http://llvm.org/viewvc/llvm-project?rev=170228view=rev Log: [preprocessor] For errors at a function macro invocation, also include a note about where the macro is defined. Modified:

[cfe-commits] r170229 - in /cfe/trunk: docs/LibASTMatchersTutorial.rst docs/LibTooling.rst include/clang/Tooling/CommonOptionsParser.h lib/Tooling/CommonOptionsParser.cpp tools/clang-check/ClangCheck.

2012-12-14 Thread Edwin Vane
Author: revane Date: Fri Dec 14 12:58:25 2012 New Revision: 170229 URL: http://llvm.org/viewvc/llvm-project?rev=170229view=rev Log: Style and Doc fix for CommonOptionsParser - Renaming GetCompilations() and GetSourcePathList() to follow LLVM style. - Updating docs to reflect name change. -

[cfe-commits] [clang-tools-extra] r170230 - /clang-tools-extra/trunk/cpp11-migrate/Cpp11Migrate.cpp

2012-12-14 Thread Edwin Vane
Author: revane Date: Fri Dec 14 12:59:24 2012 New Revision: 170230 URL: http://llvm.org/viewvc/llvm-project?rev=170230view=rev Log: Use renamed CommonOptionsParser member functions GetCompilations() and GetSourcePathLists() were renamed to match LLVM style. Reviewed By: Alexander Kornienko

Re: [cfe-commits] [PATCH] Use renamed CommonOptionsParser member functions

2012-12-14 Thread Edwin Vane
Committed as r170230. http://llvm-reviews.chandlerc.com/D212 ___ cfe-commits mailing list cfe-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Re: [cfe-commits] [PATCH] Style and Doc fix for CommonOptionsParser

2012-12-14 Thread Edwin Vane
Committed as r170229. http://llvm-reviews.chandlerc.com/D211 ___ cfe-commits mailing list cfe-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

[cfe-commits] r170231 - /cfe/trunk/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp

2012-12-14 Thread Anna Zaks
Author: zaks Date: Fri Dec 14 13:08:17 2012 New Revision: 170231 URL: http://llvm.org/viewvc/llvm-project?rev=170231view=rev Log: [analyzer] Refactor: Store visited Decls instead of CallGraphNodes. Modified: cfe/trunk/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp Modified:

[cfe-commits] r170232 - /cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp

2012-12-14 Thread Anna Zaks
Author: zaks Date: Fri Dec 14 13:08:20 2012 New Revision: 170232 URL: http://llvm.org/viewvc/llvm-project?rev=170232view=rev Log: [analyzer] Propagate the checker's state from checkBranchCondition Fixes a bug, where we were dropping the state modifications from the checkBranchCondition checker

Re: [cfe-commits] [PATCH] Warn if -isysroot is given an invalid path

2012-12-14 Thread Matthieu Monrocq
On Fri, Dec 14, 2012 at 7:41 PM, Eric Christopher echri...@gmail.comwrote: Sure, but I just don't see that providing much value. The point of adding a warning was to help catch things like typos in the sysroot path. What are the chances that someone is going to mis-type the sysroot and

[cfe-commits] r170233 - in /cfe/trunk: lib/AST/Expr.cpp test/CodeGenCXX/predefined-expr.cpp

2012-12-14 Thread Argyrios Kyrtzidis
Author: akirtzidis Date: Fri Dec 14 13:44:11 2012 New Revision: 170233 URL: http://llvm.org/viewvc/llvm-project?rev=170233view=rev Log: Don't hit an assertion failure when calculating the __PRETTY_FUNCTION__ of a member function with parenthesized declarator. Like this test case: class Foo {

[cfe-commits] r170234 - /cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp

2012-12-14 Thread Anton Yartsev
Author: ayartsev Date: Fri Dec 14 13:48:34 2012 New Revision: 170234 URL: http://llvm.org/viewvc/llvm-project?rev=170234view=rev Log: added post-statement callback to CXXNewExpr and pre-statement callback to CXXDeleteExpr Modified: cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp Modified:

Re: [cfe-commits] [PATCH][Review request] move Pre/Post checks to the common Visit() method

2012-12-14 Thread Anton Yartsev
Hi, Jordan Thanks for the review, added a post-statement callback to CXXNewExpr and a pre-statement callback to CXXDeleteExpr as r170234 I intend to finish the refactoring. The scratch below illustrates how the code will approximately look like after the refactoring. Have I got the idea?

[cfe-commits] r170238 - /cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp

2012-12-14 Thread Anton Yartsev
Author: ayartsev Date: Fri Dec 14 14:28:48 2012 New Revision: 170238 URL: http://llvm.org/viewvc/llvm-project?rev=170238view=rev Log: fixed line endings Modified: cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp Modified: cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp URL:

Re: [cfe-commits] [PATCH][Review request] move Pre/Post checks to the common Visit() method

2012-12-14 Thread Jordan Rose
Yes, that's the general idea, although you should just use isaCXXNewExpr(S) for the exceptions instead of checking the statement class directly. I'm sure you were already planning this, but please don't commit any major refactoring work without review from Ted, Anna, or me. Also, one of the

Re: [cfe-commits] r166265 - /cfe/trunk/lib/Basic/SourceManager.cpp

2012-12-14 Thread Matt Beaumont-Gay
Hi Craig, Looks like this caused PR14570. On Thu, Oct 18, 2012 at 9:40 PM, Craig Topper craig.top...@gmail.com wrote: Author: ctopper Date: Thu Oct 18 23:40:38 2012 New Revision: 166265 URL: http://llvm.org/viewvc/llvm-project?rev=166265view=rev Log: Teach getColumnNumber to use the line

[cfe-commits] r170260 - in /cfe/trunk/docs: AnalyzerRegions.rst analyzer/AnalyzerRegions.rst index.rst

2012-12-14 Thread Jordan Rose
Author: jrose Date: Fri Dec 14 18:36:53 2012 New Revision: 170260 URL: http://llvm.org/viewvc/llvm-project?rev=170260view=rev Log: Remove old description of analyzer internals from public docs. The file still exists in docs/analyzer/, but it won't be linked to from clang.llvm.org or processed as

[cfe-commits] r170261 - /cfe/trunk/docs/LanguageExtensions.rst

2012-12-14 Thread Jordan Rose
Author: jrose Date: Fri Dec 14 18:37:01 2012 New Revision: 170261 URL: http://llvm.org/viewvc/llvm-project?rev=170261view=rev Log: Docs: redirect static analysis extensions section to the analyzer site. The notes on the objc_method_family and ns_returns_retained-type attributes have been moved

[cfe-commits] r170263 - in /cfe/trunk: lib/CodeGen/CGExpr.cpp test/CodeGen/catch-undef-behavior.c

2012-12-14 Thread Will Dietz
Author: wdietz2 Date: Fri Dec 14 19:39:14 2012 New Revision: 170263 URL: http://llvm.org/viewvc/llvm-project?rev=170263view=rev Log: [ubsan] Emit branch weight metadata to hint towards common case. Results in better block placement that helps close the performance gap when making ubsan checks