[PATCH] D35068: [analyzer] Detect usages of unsafe I/O functions

2017-10-05 Thread Daniel Kolozsvari via Phabricator via cfe-commits
koldaniel updated this revision to Diff 117782. Herald added a subscriber: szepet. https://reviews.llvm.org/D35068 Files: include/clang/StaticAnalyzer/Checkers/Checkers.td lib/Driver/ToolChains/Clang.cpp lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp test/Analysis/security-syntax

r314975 - [analyzer] Fix leak false positives on stuff put in C++/ObjC initializer lists.

2017-10-05 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Thu Oct 5 01:43:32 2017 New Revision: 314975 URL: http://llvm.org/viewvc/llvm-project?rev=314975&view=rev Log: [analyzer] Fix leak false positives on stuff put in C++/ObjC initializer lists. The analyzer now realizes that C++ std::initializer_list objects and Objective-C

[PATCH] D35216: [analyzer] Escape symbols when creating std::initializer_list.

2017-10-05 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314975: [analyzer] Fix leak false positives on stuff put in C++/ObjC initializer lists. (authored by dergachev). Changed prior to commit: https://reviews.llvm.org/D35216?vs=117699&id=117785#toc Reposit

[PATCH] D38048: [clangd] Add textDocument/signatureHelp

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. @francisco.lopes, thanks for sharing your experience, I definitely like the final UX you achieved, we should aim for something similar in clangd. It also looks like @rwols's idea of how things should look like is very close to your implementation. I do think that

[PATCH] D38503: [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314977: [CodeGen] Unify generation of scalar and struct-path TBAA tags (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38503?vs=117519&id=117791#toc Repository: rL LLVM htt

r314977 - [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-05 Thread Ivan A. Kosarev via cfe-commits
Author: kosarev Date: Thu Oct 5 03:47:51 2017 New Revision: 314977 URL: http://llvm.org/viewvc/llvm-project?rev=314977&view=rev Log: [CodeGen] Unify generation of scalar and struct-path TBAA tags This patch makes it possible to produce access tags in a uniform manner regardless whether the resul

[PATCH] D38578: [preamble] Also record the "skipping" state of the preprocessor

2017-10-05 Thread Erik Verbruggen via Phabricator via cfe-commits
erikjv created this revision. When a preamble ends in a conditional preprocessor block that is being skipped, the preprocessor needs to continue skipping that block when the preamble is used. This fixes PR34570. https://reviews.llvm.org/D38578 Files: include/clang/Lex/Preprocessor.h lib/Le

r314978 - Revert r314977 "[CodeGen] Unify generation of scalar and struct-path TBAA tags"

2017-10-05 Thread Ivan A. Kosarev via cfe-commits
Author: kosarev Date: Thu Oct 5 04:05:43 2017 New Revision: 314978 URL: http://llvm.org/viewvc/llvm-project?rev=314978&view=rev Log: Revert r314977 "[CodeGen] Unify generation of scalar and struct-path TBAA tags" D37826 has been mistakenly committed where it should be the patch from D38503. Dif

r314979 - [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-05 Thread Ivan A. Kosarev via cfe-commits
Author: kosarev Date: Thu Oct 5 04:08:17 2017 New Revision: 314979 URL: http://llvm.org/viewvc/llvm-project?rev=314979&view=rev Log: [CodeGen] Unify generation of scalar and struct-path TBAA tags This patch makes it possible to produce access tags in a uniform manner regardless whether the resul

[PATCH] D38464: [clangd] less boilerplate in RPC dispatch

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdLSPServer.h:47 // Implement ProtocolCallbacks. - void onInitialize(StringRef ID, InitializeParams IP, -JSONOutput &Out) override; - void onShutdown(JSONOutput &Out) override; - void onDocument

[PATCH] D37436: Initial implementation of C attributes (WG14 N2137)

2017-10-05 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D37436#881363, @aaron.ballman wrote: > In https://reviews.llvm.org/D37436#871117, @aaron.ballman wrote: > > > Updated based on review feedback. > > > > - Rename CAttributes to DoubleSquareBracketAttributes > > - Added Objective-C test cas

[PATCH] D38101: [Sema] Diagnose tautological comparison with type's min/max values

2017-10-05 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 117802. lebedev.ri marked 2 inline comments as done. lebedev.ri added a subscriber: rtrieu. lebedev.ri added a comment. - Address review notes - ~~Avoid re-evaluating ICE when called from `DiagnoseOutOfRangeComparison()` which already knows the evaluated v

[PATCH] D38101: [Sema] Diagnose tautological comparison with type's min/max values

2017-10-05 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: lib/Sema/SemaChecking.cpp:8719 + // Type limit values are handled later by CheckTautologicalComparison(). + if (IsTypeLimit(S, Other, Constant, ConstValue) && (!OtherIsBooleanType)) return; rsmith wrote: > Is t

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-05 Thread Michael Ferguson via Phabricator via cfe-commits
mppf updated this revision to Diff 117806. mppf added a comment. - Update comment for "complete object type" https://reviews.llvm.org/D38473 Files: include/clang/CodeGen/CodeGenABITypes.h lib/CodeGen/CodeGenABITypes.cpp unittests/CodeGen/CMakeLists.txt unittests/CodeGen/CodeGenExternalT

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ClangdServer now provides async code completion API. It is still used synchronously by ClangdLSPServer, more work is needed to allow processing other requests in parallel while completion (or any other request) is running. https://reviews.llvm.org/D38583 Fil

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-05 Thread Michael Ferguson via Phabricator via cfe-commits
mppf added a comment. @rjmccall , @rsmith - I added a comment about complete object type. I think I've addressed all the concerns at this point, but speak up if I'm misunderstanding. I don't have commit access so I'll need help committing it. Thanks for your help! https://reviews.llvm.org/D3

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added inline comments. Comment at: clangd/ClangdServer.cpp:222 + + std::shared_ptr Preamble = + Resources->getPossiblyStalePreamble(); I think we use "const type" everywhere. Comment at: clangd/ClangdServer.cpp:225 + // A task tha

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 117811. ilya-biryukov added a comment. - Moved 'const' to the left. https://reviews.llvm.org/D38583 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp clangd/ClangdServer.h unittests/clangd/ClangdTests.cpp Index: unittests/clangd/Clang

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.cpp:222 + + std::shared_ptr Preamble = + Resources->getPossiblyStalePreamble(); klimek wrote: > I think we use "const type" everywhere. Sorry, my previously preferred style keeps sneaking

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added inline comments. Comment at: clangd/ClangdServer.cpp:225 + // A task that will be run asynchronously. + PackagedTask Task([=]() mutable { // 'mutable' to reassign Preamble variable. +if (!Preamble) { ilya-biryukov wrote: > klimek wrote: > > It

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 117820. ilya-biryukov added a comment. - Added a comment about Preamble assignment. https://reviews.llvm.org/D38583 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp clangd/ClangdServer.h unittests/clangd/ClangdTests.cpp Index: unitte

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 117822. ilya-biryukov marked an inline comment as done. ilya-biryukov added a comment. - Fixed grammar in a comment. https://reviews.llvm.org/D38583 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp clangd/ClangdServer.h unittests/clan

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.h:236-237 + /// + /// Request is processed asynchronously, you can use returned future to wait + /// for results of async request. + /// klimek wrote: > Extra space before asynchronously. >

[PATCH] D36836: [clang-tidy] Implement readability-function-cognitive-complexity check

2017-10-05 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 117824. lebedev.ri added a comment. Ping. - Rebased - Added the legal status info into `LICENSE.txt`, referencing `clang-tidy/readability/FunctionCognitiveComplexityCheck.LICENSE.txt`, as suggested by @aaron.ballman Question: Is it expected that clang-t

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Manuel Klimek via Phabricator via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. LG Comment at: clangd/ClangdServer.h:236-237 + /// + /// Request is processed asynchronously, you can use returned future to wait + /// for results of async request. + /

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D35082#889053, @rjmccall wrote: > Are you sure it's a good idea to not print the address space when it's > implicit? Won't that often lead to really confusing diagnostics? > > Also, we do already have a way of expressing that an extended quali

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 117823. kosarev added a comment. - Rebased on top of https://reviews.llvm.org/D38503. - The tbaa-for-vptr.cpp test is changed to be more specific about the instructions to test. Otherwise, we fail on some triples, such as s390x-ibm-linux and x86_64-pc-mingw3

[PATCH] D38048: [clangd] Add textDocument/signatureHelp

2017-10-05 Thread Francisco Lopes da Silva via Phabricator via cfe-commits
francisco.lopes added a comment. In https://reviews.llvm.org/D38048#889176, @ilya-biryukov wrote: > @francisco.lopes, thanks for sharing your experience, I definitely like the > final UX you achieved, we should aim for something similar in clangd. > It also looks like @rwols's idea of how thin

[PATCH] D36836: [clang-tidy] Implement readability-function-cognitive-complexity check

2017-10-05 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: dberlin. aaron.ballman added a subscriber: dberlin. aaron.ballman added a comment. Adding @dberlin for licensing discussion questions. Comment at: LICENSE.TXT:64 clang-tidy clang-tidy/hicpp +clang-tidy clang-tidy/readability/F

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added inline comments. Comment at: lib/CodeGen/CodeGenTBAA.h:129 - /// getBaseTypeInfo - Get metadata node for a given base access type. - llvm::MDNode *getBaseTypeInfo(QualType QType); + /// getTBAABaseTypeMetadata - Get metadata that describes the given base + ///

[PATCH] D37891: Driver: hoist the `wchar_t` handling to the driver

2017-10-05 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd updated this revision to Diff 117832. compnerd added a comment. Moves the logic back into Basic. The flags are now optional, but controlled by the driver. The test adjustments are to map the old `-fshort-wchar` to `-fwchar-type=short -fno-signed-wchar` for the most part, there is one

[PATCH] D38464: [clangd] less boilerplate in RPC dispatch

2017-10-05 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 117835. sammccall marked 5 inline comments as done. sammccall added a comment. - ClangLSPServer.h should refer to ShutdownParams, not NoParams - Address review comments https://reviews.llvm.org/D38464 Files: clangd/ClangdLSPServer.cpp clangd/ClangdLSP

[PATCH] D38464: [clangd] less boilerplate in RPC dispatch

2017-10-05 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks! All addressed (except removing ShutdownParams, which I'm not sure is worthwhile). Comment at: clangd/ClangdLSPServer.h:47 // Implement ProtocolCallbacks. - void onInitialize(StringRef ID, InitializeParams IP, -JSONOutp

[PATCH] D31363: [libc++] Remove cmake glob for source files

2017-10-05 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. Building libcxx without LLVM's CMake modules is very important, not just to Apple. This is how several open source distributions work, and it would be a huge disservice to break this. Same is true for compiler-rt, libcxxabi, libunwind, etc. Historically we've been drawin

[PATCH] D38110: [libunwind][MIPS]: Add support for unwinding in O32 and N64 processes.

2017-10-05 Thread John Baldwin via Phabricator via cfe-commits
bsdjhb added a comment. FYI, I was able to do simple testing (C++ programs throwing exceptions) using GCC 6.3 to compile a FreeBSD userland for both O32 and N64. Still working on cross-compiling LLVM so I can run the tests under qemu. https://reviews.llvm.org/D38110 ___

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 117843. ilya-biryukov added a comment. - Added another missing 'the'. https://reviews.llvm.org/D38583 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp clangd/ClangdServer.h unittests/clangd/ClangdTests.cpp Index: unittests/clangd/Cla

[clang-tools-extra] r314989 - [clangd] Added async API to run code completion.

2017-10-05 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Thu Oct 5 10:04:13 2017 New Revision: 314989 URL: http://llvm.org/viewvc/llvm-project?rev=314989&view=rev Log: [clangd] Added async API to run code completion. Summary: ClangdServer now provides async code completion API. It is still used synchronously by ClangdLSPServer,

[PATCH] D38583: [clangd] Added async API to run code completion.

2017-10-05 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314989: [clangd] Added async API to run code completion. (authored by ibiryukov). Repository: rL LLVM https://reviews.llvm.org/D38583 Files: clang-tools-extra/trunk/clangd/ClangdLSPServer.cpp clan

[PATCH] D38589: [Analyzer] Run tests until the end, do not stop at the first failure

2017-10-05 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 117847. https://reviews.llvm.org/D38589 Files: utils/analyzer/SATestBuild.py Index: utils/analyzer/SATestBuild.py === --- utils/analyzer/SATestBuild.py +++ utils/analyzer/SATestBuild

[PATCH] D38589: [Analyzer] Run tests until the end, do not stop at the first failure

2017-10-05 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov created this revision. Herald added subscribers: szepet, xazax.hun. This is especially important for updating reference results. https://reviews.llvm.org/D38589 Files: utils/analyzer/SATestBuild.py Index: utils/analyzer/SATestBuild.py

[PATCH] D38589: [Analyzer] Run tests until the end, do not stop at the first failure

2017-10-05 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin requested changes to this revision. dcoughlin added a comment. This revision now requires changes to proceed. This looks good to me. https://reviews.llvm.org/D38589 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.

[PATCH] D38589: [Analyzer] Run tests until the end, do not stop at the first failure

2017-10-05 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added a comment. This revision is now accepted and ready to land. Oops, wrong button! LGTM! https://reviews.llvm.org/D38589 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi

r314992 - [Analyzer Tests] Run static analyzer integration tests until the end,

2017-10-05 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Thu Oct 5 10:32:06 2017 New Revision: 314992 URL: http://llvm.org/viewvc/llvm-project?rev=314992&view=rev Log: [Analyzer Tests] Run static analyzer integration tests until the end, Do not stop at the first failure. Differential Revision: https://reviews.llvm.org/D

[PATCH] D38589: [Analyzer] Run tests until the end, do not stop at the first failure

2017-10-05 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314992: [Analyzer Tests] Run static analyzer integration tests until the end, (authored by george.karpenkov). Changed prior to commit: https://reviews.llvm.org/D38589?vs=117847&id=117848#toc Repository

r314995 - [OPENMP] Fix mapping|privatization of implicitly captured variables.

2017-10-05 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Thu Oct 5 10:51:39 2017 New Revision: 314995 URL: http://llvm.org/viewvc/llvm-project?rev=314995&view=rev Log: [OPENMP] Fix mapping|privatization of implicitly captured variables. If the `defaultmap(tofrom:scalar)` clause is specified, the scalars must be mapped with 'tofro

[PATCH] D38113: OpenCL: Assume functions are convergent

2017-10-05 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm updated this revision to Diff 117855. arsenm added a comment. Check noduplicate https://reviews.llvm.org/D38113 Files: include/clang/Basic/LangOptions.h lib/CodeGen/CGCall.cpp test/CodeGenOpenCL/amdgpu-attrs.cl test/CodeGenOpenCL/convergent.cl Index: test/CodeGenOpenCL/convergen

[libclc] r314998 - Add vload_half helpers for ptx

2017-10-05 Thread Jeroen Ketema via cfe-commits
Author: jketema Date: Thu Oct 5 11:17:40 2017 New Revision: 314998 URL: http://llvm.org/viewvc/llvm-project?rev=314998&view=rev Log: Add vload_half helpers for ptx The removes the vload_half unresolved calls from the nvptx libraries. Reviewed-by: Jan Vesely Added: libclc/trunk/ptx/lib/sha

[PATCH] D37891: Driver: hoist the `wchar_t` handling to the driver

2017-10-05 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: lib/Basic/TargetInfo.cpp:29 +namespace { +TargetInfo::IntType GetDefaultWCharType(const llvm::Triple &T) { + const llvm::Triple::ArchType Arch = T.getArch(); How is this better than what we had before? It's totally inconsis

[PATCH] D37891: Driver: hoist the `wchar_t` handling to the driver

2017-10-05 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: lib/Basic/TargetInfo.cpp:29 +namespace { +TargetInfo::IntType GetDefaultWCharType(const llvm::Triple &T) { + const llvm::Triple::ArchType Arch = T.getArch(); rnk wrote: > How is this better than what we had before? It'

[PATCH] D38048: [clangd] Add textDocument/signatureHelp

2017-10-05 Thread Raoul Wols via Phabricator via cfe-commits
rwols added a comment. In https://reviews.llvm.org/D38048#887960, @ilya-biryukov wrote: > LGTM. Do you need my help in landing this? Yes, I don't have commit access, go ahead and merge. If you find any merge conflicts let me know I can probably fix that. Since we're throwing around gifs for fu

r315005 - Fix two-phase name lookup for non-dependent overloaded operators.

2017-10-05 Thread Richard Smith via cfe-commits
Author: rsmith Date: Thu Oct 5 12:35:51 2017 New Revision: 315005 URL: http://llvm.org/viewvc/llvm-project?rev=315005&view=rev Log: Fix two-phase name lookup for non-dependent overloaded operators. If we resolve an overloaded operator call to a specific function during template definition, don't

[PATCH] D38525: Cleanup and generalize -shared-libasan.

2017-10-05 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka accepted this revision. vitalybuka added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Driver/SanitizerArgs.cpp:614 + if (Arg *A = Args.getLastArg(options::OPT_shared_libsan, + options::OPT_static

[PATCH] D38596: Implement attribute target multiversioning

2017-10-05 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. GCC's attribute 'target', in addition to being an optimization hint, also allows function multiversioning. We currently have the former implemented, this is the latter's implementation. Note that it ends up having to permit redefinition of functions so that they

[PATCH] D38525: Cleanup and generalize -shared-libasan.

2017-10-05 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis added inline comments. Comment at: clang/lib/Driver/ToolChains/CommonArgs.cpp:563 +if (SanArgs.needsUbsanRt()) { + if (SanArgs.requiresMinimalRuntime()) { +SharedRuntimes.push_back("ubsan_minimal"); vitalybuka wrote: > Shouldn't ubsan cha

[PATCH] D38525: Cleanup and generalize -shared-libasan.

2017-10-05 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis updated this revision to Diff 117875. eugenis added a comment. address comment https://reviews.llvm.org/D38525 Files: clang/include/clang/Driver/Options.td clang/include/clang/Driver/SanitizerArgs.h clang/lib/Driver/SanitizerArgs.cpp clang/lib/Driver/ToolChains/CommonArgs.cpp

[PATCH] D38525: Cleanup and generalize -shared-libasan.

2017-10-05 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis added inline comments. Comment at: clang/lib/Driver/SanitizerArgs.cpp:614 + if (Arg *A = Args.getLastArg(options::OPT_shared_libsan, + options::OPT_static_libsan)) +SharedRuntime = A->getOption().matches(options::OPT_shared_libsan);

r315015 - Cleanup and generalize -shared-libasan.

2017-10-05 Thread Evgeniy Stepanov via cfe-commits
Author: eugenis Date: Thu Oct 5 13:14:00 2017 New Revision: 315015 URL: http://llvm.org/viewvc/llvm-project?rev=315015&view=rev Log: Cleanup and generalize -shared-libasan. Summary: * Rename -shared-libasan to -shared-libsan, keeping the old name as alias. * Add -static-libsan for targets that d

[PATCH] D38525: Cleanup and generalize -shared-libasan.

2017-10-05 Thread Evgenii Stepanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL315015: Cleanup and generalize -shared-libasan. (authored by eugenis). Changed prior to commit: https://reviews.llvm.org/D38525?vs=117875&id=117878#toc Repository: rL LLVM https://reviews.llvm.org/D

[libclc] r315018 - configure: Fix handling of directories with compats only source lists

2017-10-05 Thread Jan Vesely via cfe-commits
Author: jvesely Date: Thu Oct 5 13:16:28 2017 New Revision: 315018 URL: http://llvm.org/viewvc/llvm-project?rev=315018&view=rev Log: configure: Fix handling of directories with compats only source lists Reviewer: Jeroen Ketema Signed-off-by: Jan Vesely Modified: libclc/trunk/configure.py

[PATCH] D38596: Implement attribute target multiversioning

2017-10-05 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added a comment. Can you explain briefly what is required of the system in order to support this (is it just ifunc support in the dynamic linker / loader)? In general, there are a number of places in this patch, at the Sema layer (including in the error messages), that talk about how th

[PATCH] D38596: Implement attribute target multiversioning

2017-10-05 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In https://reviews.llvm.org/D38596#889682, @hfinkel wrote: > Can you explain briefly what is required of the system in order to support > this (is it just ifunc support in the dynamic linker / loader)? Yep, this feature depends entirely on ifuncs. > In general, the

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-05 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Looks good to me. https://reviews.llvm.org/D38473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38596: Implement attribute target multiversioning

2017-10-05 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added a comment. In https://reviews.llvm.org/D38596#889697, @erichkeane wrote: > In https://reviews.llvm.org/D38596#889682, @hfinkel wrote: > > > Can you explain briefly what is required of the system in order to support > > this (is it just ifunc support in the dynamic linker / loader)?

[PATCH] D38048: [clangd] Add textDocument/signatureHelp

2017-10-05 Thread Francisco Lopes da Silva via Phabricator via cfe-commits
francisco.lopes added a comment. In https://reviews.llvm.org/D38048#889568, @rwols wrote: > Since we're throwing around gifs for fun here's how signatureHelp looks in > practice for Sublime Text Very cool! https://reviews.llvm.org/D38048 ___ cfe

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-05 Thread Dan Albert via Phabricator via cfe-commits
danalbert created this revision. This doesn't only happen for incorrectly built apps, it also happens for libraries loaded with dlopen. Repository: rL LLVM https://reviews.llvm.org/D38599 Files: src/private_typeinfo.cpp Index: src/private_typeinfo.cpp

[PATCH] D38601: Enable amdfam15,amdfam15h, and amdfam10h support

2017-10-05 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. buildin_cpu_is already supports amdfam10h and amdfam15h, the 'sans-h' version to the check and enable it. Addtionally, add amdfam15 as an alias for bdver1, like amdfam10 is for barcelona. https://reviews.llvm.org/D38601 Files: lib/Basic/Targets/X86.cpp tes

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-05 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. Does dlopen cause issues even with `RTLD_GLOBAL`? Repository: rL LLVM https://reviews.llvm.org/D38599 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r315025 - For dllexport class templates, export specializations of member functions (PR34849)

2017-10-05 Thread Hans Wennborg via cfe-commits
Author: hans Date: Thu Oct 5 14:45:27 2017 New Revision: 315025 URL: http://llvm.org/viewvc/llvm-project?rev=315025&view=rev Log: For dllexport class templates, export specializations of member functions (PR34849) Modified: cfe/trunk/lib/Sema/SemaDecl.cpp cfe/trunk/test/CodeGenCXX/dllex

RE: [clang-tools-extra] r314989 - [clangd] Added async API to run code completion.

2017-10-05 Thread Yung, Douglas via cfe-commits
Hi Ilya, Your change has broken the build on the PS4 Windows bot. http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/12525 Can you take a look and fix it? Douglas Yung > -Original Message- > From: cfe-commits [mailto:cfe-commits-boun...@lists.llvm

[PATCH] D38601: Enable amdfam15,amdfam15h, and amdfam10h support

2017-10-05 Thread Erich Keane via Phabricator via cfe-commits
erichkeane abandoned this revision. erichkeane added a comment. Talking to Craig, this is just wrong for these features. Attribute-target does some funky things in order to make this work, so I'll just bring those 'hacks' into my other patch. https://reviews.llvm.org/D38601 ___

[clang-tools-extra] r315028 - [clangd] Attempt to fix compilation with MSVC.

2017-10-05 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Thu Oct 5 15:15:15 2017 New Revision: 315028 URL: http://llvm.org/viewvc/llvm-project?rev=315028&view=rev Log: [clangd] Attempt to fix compilation with MSVC. Modified: clang-tools-extra/trunk/clangd/ClangdServer.h Modified: clang-tools-extra/trunk/clangd/ClangdServer

[PATCH] D37891: Driver: hoist the `wchar_t` handling to the driver

2017-10-05 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: lib/Basic/TargetInfo.cpp:29 +namespace { +TargetInfo::IntType GetDefaultWCharType(const llvm::Triple &T) { + const llvm::Triple::ArchType Arch = T.getArch(); compnerd wrote: > rnk wrote: > > How is this better than what we

[PATCH] D36562: [Bitfield] Make the bitfield a separate location if it has width of legal integer type and its bit offset is naturally aligned for the type

2017-10-05 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added inline comments. Comment at: lib/CodeGen/CGRecordLayoutBuilder.cpp:411 + // component so as it can be accessed directly with lower cost. + auto betterBeSingleFieldRun = [&](RecordDecl::field_iterator Field) { +if (!Types.getCodeGenOpts().FineGrainedBitfieldAcc

r315030 - [CMake] Add install-distribution-toolchain to stage2 target list

2017-10-05 Thread Chris Bieneman via cfe-commits
Author: cbieneman Date: Thu Oct 5 15:48:34 2017 New Revision: 315030 URL: http://llvm.org/viewvc/llvm-project?rev=315030&view=rev Log: [CMake] Add install-distribution-toolchain to stage2 target list This allows generating toolchains with just the distribution components instead of toolchains w

[PATCH] D38606: [CodeGen] Emit a helper function for __builtin_os_log_format to reduce code size

2017-10-05 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak created this revision. We found that the IR IRGen emits when expanding __builtin_os_log_format is quite big and has a lot of redundancy. For example, when clang compiles the following code: void foo1(void *buf) { __builtin_os_log_format(buf, "%d %d", 11, 22); } The IR looks li

[PATCH] D37436: Initial implementation of C attributes (WG14 N2137)

2017-10-05 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith requested changes to this revision. rsmith added a comment. This revision now requires changes to proceed. Mostly looks good, other than the regression in enum parsing. Comment at: clang/include/clang/Basic/LangOptions.def:140 +LANGOPT(DoubleSquareBracketsAttributes, 1

[PATCH] D32981: [ASTImporter] Improve handling of incomplete types

2017-10-05 Thread Peter Szecsi via Phabricator via cfe-commits
szepet closed this revision. szepet added a comment. This patch was commited in r302975. (https://reviews.llvm.org/rL302975) https://reviews.llvm.org/D32981 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailma

[PATCH] D38549: [clang-tidy] Link targets and Asm parsers

2017-10-05 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. The first attempt to fix this (https://reviews.llvm.org/D17981) was stuck on figuring out whether we care about the binary size. It seems to me that the binary size is secondary to maintaining

[PATCH] D36562: [Bitfield] Make the bitfield a separate location if it has width of legal integer type and its bit offset is naturally aligned for the type

2017-10-05 Thread Wei Mi via Phabricator via cfe-commits
wmi marked an inline comment as done. wmi added inline comments. Comment at: lib/CodeGen/CGRecordLayoutBuilder.cpp:444 // Add bitfields to the run as long as they qualify. -if (Field != FieldEnd && Field->getBitWidthValue(Context) != 0 && -Tail == getFieldBitOffs

[PATCH] D36562: [Bitfield] Make the bitfield a separate location if it has width of legal integer type and its bit offset is naturally aligned for the type

2017-10-05 Thread Wei Mi via Phabricator via cfe-commits
wmi updated this revision to Diff 117947. wmi added a comment. Address Hal's comment. Repository: rL LLVM https://reviews.llvm.org/D36562 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/Driver/Options.td include/clang/Frontend/CodeGenOptions.def lib/CodeGen/CGRecord

Re: [PATCH] D31363: [libc++] Remove cmake glob for source files

2017-10-05 Thread Eric Fiselier via cfe-commits
On Thu, Oct 5, 2017 at 10:20 AM, Chris Bieneman via Phabricator < revi...@reviews.llvm.org> wrote: > beanz added a comment. > > Building libcxx without LLVM's CMake modules is very important, not just > to Apple. *Why* is it important? The reason isn't obvious to me. The only additional cost is

[PATCH] D38596: Implement attribute target multiversioning

2017-10-05 Thread Eric Christopher via Phabricator via cfe-commits
echristo added a comment. This generally works for me modulo the things that Hal has mentioned. You'll probably want to add Richard to the review list for the Sema bits as well. Thanks! Comment at: lib/Sema/SemaDecl.cpp:3214 if (!isFriend && NewMethod->getLexicalDeclCo

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. LGTM. Repository: rL LLVM https://reviews.llvm.org/D37826 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cg

[PATCH] D38606: [CodeGen] Emit a helper function for __builtin_os_log_format to reduce code size

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. I don't see any reason not to use linkonce_odr + hidden even outside of -Oz. Otherwise LGTM. https://reviews.llvm.org/D38606 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. You have an important backend change relying on being able to preserve type sugar better in diagnostics? The only apparent semantic change in this patch is that you're changing the mangling, which frankly seems incorrect. https://reviews.llvm.org/D35082 __

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D35082#890143, @rjmccall wrote: > You have an important backend change relying on being able to preserve type > sugar better in diagnostics? The only apparent semantic change in this patch > is that you're changing the mangling, which frankly

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Non-canonical information is not supposed to be mangled. It's not clear to me what the language rule you're really trying to implement is. Maybe you really do need a canonical __private address space, in which case you are going to have to change a lot of code in Sema

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D35082#890150, @rjmccall wrote: > Non-canonical information is not supposed to be mangled. > > It's not clear to me what the language rule you're really trying to implement > is. Maybe you really do need a canonical __private address space, in

[PATCH] D38606: [CodeGen] Emit a helper function for __builtin_os_log_format to reduce code size

2017-10-05 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 117955. ahatanak added a comment. Always mark the helper function as linkonce_odr and hidden. https://reviews.llvm.org/D38606 Files: lib/CodeGen/CGBuiltin.cpp lib/CodeGen/CodeGenFunction.h test/CodeGen/builtins.c test/CodeGenObjC/os_log.m Index: t

[PATCH] D38606: [CodeGen] Emit a helper function for __builtin_os_log_format to reduce code size

2017-10-05 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. I think you are right. The linkage should be linkonce_odr even when not compiling with -Oz. I've fixed it in the latest patch. https://reviews.llvm.org/D38606 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://

[PATCH] D35082: [OpenCL] Add LangAS::opencl_private to represent private address space in AST

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Okay. I think I see your point about why it would be better to have a canonical __private address space that is different from the implicit address space 0. I assume this means that there should basically never be pointers, references, or l-values in address space 0

[PATCH] D38606: [CodeGen] Emit a helper function for __builtin_os_log_format to reduce code size

2017-10-05 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. Thanks. LGTM. https://reviews.llvm.org/D38606 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/