[PATCH] D45177: CStringChecker, check strlcpy/strlcat

2018-05-18 Thread David CARLIER via Phabricator via cfe-commits
devnexen added a comment. In https://reviews.llvm.org/D45177#1103781, @alexfh wrote: > In https://reviews.llvm.org/D45177#1103774, @devnexen wrote: > > > In https://reviews.llvm.org/D45177#1103162, @alexfh wrote: > > > > > See https://bugs.llvm.org/show_bug.cgi?id=37503 for a test case. > > > >

[PATCH] D47058: [ASTImporter] Fix ClassTemplateSpecialization in wrong DC

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a.sidorin, r.stahl, xazax.hun. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. ClassTemplateSpecialization is put in the wrong DeclContex if implicitly instantiated. This patch fixes it. Repository: rC Clang

[PATCH] D46871: [AMDGPU] Add interpolation builtins

2018-05-18 Thread Tim Corringham via Phabricator via cfe-commits
timcorringham updated this revision to Diff 147460. timcorringham added a comment. [AMDGPU] Add interpolation builtins Updated LIT test so that it only tests for the existence of the builtins by checking the IR. Repository: rC Clang https://reviews.llvm.org/D46871 Files:

r332699 - Do not try to remove invisible Decls from DeclContext

2018-05-18 Thread Gabor Marton via cfe-commits
Author: martong Date: Fri May 18 02:08:47 2018 New Revision: 332699 URL: http://llvm.org/viewvc/llvm-project?rev=332699=rev Log: Do not try to remove invisible Decls from DeclContext Modified: cfe/trunk/lib/AST/DeclBase.cpp cfe/trunk/unittests/AST/ASTImporterTest.cpp Modified:

[PATCH] D46998: [XRay][compiler-rt] Limit reliance on C++ ABI features

2018-05-18 Thread Dean Michael Berris via Phabricator via cfe-commits
dberris updated this revision to Diff 147451. dberris retitled this revision from "[XRay][clang+compiler-rt] Make XRay depend on a C++ standard lib" to "[XRay][compiler-rt] Limit reliance on C++ ABI features". dberris edited the summary of this revision. dberris added a comment. Retitle, and

[PATCH] D46998: [XRay][compiler-rt] Limit reliance on C++ ABI features

2018-05-18 Thread Dean Michael Berris via Phabricator via cfe-commits
dberris updated this revision to Diff 147453. dberris added a comment. - fixup: revert unnecessary change to clang https://reviews.llvm.org/D46998 Files: compiler-rt/lib/xray/xray_basic_logging.cc compiler-rt/test/xray/TestCases/Posix/c-test.cc Index:

[PATCH] D47057: [ASTImporter] Fix missing implict CXXRecordDecl in ClassTemplateSpecializationDecl

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a.sidorin, xazax.hun, r.stahl. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. Currently we do not import the implicit CXXRecordDecl of a ClassTemplateSpecializationDecl. This patch fixes it. Repository: rC Clang

[PATCH] D46871: [AMDGPU] Add interpolation builtins

2018-05-18 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: include/clang/Basic/BuiltinsAMDGPU.def:103-107 +BUILTIN(__builtin_amdgcn_interp_p1_f16, "ffUiUibUi", "nc") +BUILTIN(__builtin_amdgcn_interp_p2_f16, "hffUiUibUi", "nc") +BUILTIN(__builtin_amdgcn_interp_p1, "ffUiUiUi", "nc")

[PATCH] D46881: [X86][CET] Changing -fcf-protection behavior to comply with gcc (clang part)

2018-05-18 Thread Alexander Ivchenko via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC332704: This patch aims to match the changes introduced (authored by aivchenk, committed by ). Changed prior to commit: https://reviews.llvm.org/D46881?vs=147292=147476#toc Repository: rC Clang

[PATCH] D44954: [clangd] Add "member" symbols to the index

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D44954#1103664, @malaperle wrote: > It's probably better to consider this in a future patch. Maybe something like > the first suggestion: vector::push_back and match both. Otherwise, I would > think it might be a bit too verbose to

[PATCH] D46835: [ASTImporter] Do not try to remove invisible Decls from DeclContext

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong closed this revision. martong added a comment. Closed by commit: https://reviews.llvm.org/rL332699 Repository: rC Clang https://reviews.llvm.org/D46835 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r332704 - This patch aims to match the changes introduced

2018-05-18 Thread Alexander Ivchenko via cfe-commits
Author: aivchenk Date: Fri May 18 04:56:21 2018 New Revision: 332704 URL: http://llvm.org/viewvc/llvm-project?rev=332704=rev Log: This patch aims to match the changes introduced in gcc by https://gcc.gnu.org/ml/gcc-cvs/2018-04/msg00534.html. The -mibt feature flag is being removed, and the

[clang-tools-extra] r332701 - Re-enable a clang-move test on windows.

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 02:25:36 2018 New Revision: 332701 URL: http://llvm.org/viewvc/llvm-project?rev=332701=rev Log: Re-enable a clang-move test on windows. This was fixed by r332612. Modified: clang-tools-extra/trunk/test/clang-move/move-class.cpp Modified:

r332800 - Adjust and fix failing CXX tests after r332799

2018-05-18 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Fri May 18 20:33:56 2018 New Revision: 332800 URL: http://llvm.org/viewvc/llvm-project?rev=332800=rev Log: Adjust and fix failing CXX tests after r332799 Modified: cfe/trunk/test/CXX/class/class.union/p1.cpp cfe/trunk/test/CXX/drs/dr5xx.cpp Modified:

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In https://reviews.llvm.org/D47096#1105455, @rjmccall wrote: > `children()` is actually defined at the `Stmt` level, and if you look at how > it's implemented on e.g. `IfStmt`, you can see that it visits all of the > child `Stmt`s, including the if-condition. So it should

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 147648. jfb added a comment. - move test Repository: rC Clang https://reviews.llvm.org/D47096 Files: lib/CodeGen/CGDecl.cpp test/CodeGenCXX/block-capture.cpp Index: test/CodeGenCXX/block-capture.cpp

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 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: rC Clang https://reviews.llvm.org/D47096 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47099: Disable casting of alloca for ActiveFlag

2018-05-18 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Maybe there should just be a method that makes a primitive alloca without the casting, and then you can call that in CreateTempAlloca. https://reviews.llvm.org/D47099 ___ cfe-commits mailing list

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In https://reviews.llvm.org/D47096#1105492, @rjmccall wrote: > Test case should go in test/CodeGenCXX. Also, there already is a > `blocks.cpp` there. I moved it, but didn't merge with the existing block.cpp because it just checks for not crashing. I'd rather make sure

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Test case should go in test/CodeGenCXX. Also, there already is a `blocks.cpp` there. Repository: rC Clang https://reviews.llvm.org/D47096 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 147647. jfb added a comment. - Follow John's suggestion. Repository: rC Clang https://reviews.llvm.org/D47096 Files: lib/CodeGen/CGDecl.cpp test/CodeGen/block-capture.cpp Index: test/CodeGen/block-capture.cpp

[PATCH] D47096: CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via Phabricator via cfe-commits
jfb closed this revision. jfb added a comment. r332801 Repository: rC Clang https://reviews.llvm.org/D47096 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r332801 - CodeGen: block capture shouldn't ICE

2018-05-18 Thread JF Bastien via cfe-commits
Author: jfb Date: Fri May 18 21:21:26 2018 New Revision: 332801 URL: http://llvm.org/viewvc/llvm-project?rev=332801=rev Log: CodeGen: block capture shouldn't ICE When a lambda capture captures a __block in the same statement, the compiler asserts out because isCapturedBy assumes that an Expr

[PATCH] D47101: [Sema] Use %sub to cleanup overload diagnostics

2018-05-18 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF created this revision. EricWF added a reviewer: rsmith. This patch adds the newly added `%sub` diagnostic modifier to cleanup repetition in the overload candidate diagnostics. I think this should be good to go. @rsmith: Some of the notes now emit `function template` where they only said

[PATCH] D45532: [StaticAnalyzer] Checker to find uninitialized fields after a constructor call

2018-05-18 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus marked 28 inline comments as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObjectChecker.cpp:181-182 +/// Returns whether FD can be (transitively) dereferenced to a void pointer type +/// (void*, void**, ...). The type of

r332717 - [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 06:22:49 2018 New Revision: 332717 URL: http://llvm.org/viewvc/llvm-project?rev=332717=rev Log: [VFS] Implement getRealPath for OverlayFileSystem. Reviewers: bkramer Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D47060 Modified:

[PATCH] D45927: [clang-tidy] [modernize-use-auto] Correct way to calculate a type name length for multi-token types

2018-05-18 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added a comment. Alexander, can you please have a look at the latest patch? Thanks. https://reviews.llvm.org/D45927 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47067: Update NRVO logic to support early return

2018-05-18 Thread Taiju Tsuiki via Phabricator via cfe-commits
tzik created this revision. Herald added a subscriber: cfe-commits. The previous implementation misses an opportunity to apply NRVO (Named Return Value Optimization) below. That discourages user to write early return code. --

[PATCH] D47068: Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. ioeric marked an inline comment as done. Closed by commit rL332720: Move #include manipulation code to new lib/Tooling/Inclusions. (authored by ioeric, committed by ). Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D47069: [ASTImporter] Enable disabled but passing test

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a.sidorin, r.stahl, xazax.hun. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. There is a test which passes since https://reviews.llvm.org/D32947, but it was forgotten to be enabled. This patch enables that disabled test.

r332720 - Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 07:16:37 2018 New Revision: 332720 URL: http://llvm.org/viewvc/llvm-project?rev=332720=rev Log: Move #include manipulation code to new lib/Tooling/Inclusions. Summary: clangToolingCore is linked into almost everything (incl. clang), but not few tools need #include

[PATCH] D44954: [clangd] Add "member" symbols to the index

2018-05-18 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. In https://reviews.llvm.org/D44954#1104178, @ilya-biryukov wrote: > In https://reviews.llvm.org/D44954#1103664, @malaperle wrote: > > > It's probably better to consider this in a future patch. Maybe something > > like the first suggestion: vector::push_back and match

[clang-tools-extra] r332723 - Silence more truncation warnings; NFC.

2018-05-18 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri May 18 07:53:32 2018 New Revision: 332723 URL: http://llvm.org/viewvc/llvm-project?rev=332723=rev Log: Silence more truncation warnings; NFC. Modified: clang-tools-extra/trunk/unittests/clangd/QualityTests.cpp Modified:

[PATCH] D46940: [ASTImporter] make sure that ACtx::getParents still works

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong accepted this revision. martong added a comment. This revision is now accepted and ready to land. Herald added a subscriber: rnkovacs. Ok, thanks for the explanation. Now it looks good to me. https://reviews.llvm.org/D46940 ___ cfe-commits

[PATCH] D47069: [ASTImporter] Enable disabled but passing test

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC332728: [ASTImporter] Enable disabled but passing test (authored by martong, committed by ). Changed prior to commit: https://reviews.llvm.org/D47069?vs=147506=147524#toc Repository: rC Clang

[PATCH] D47074: [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: bkramer. Herald added subscribers: cfe-commits, klimek. ... to support purely VFS-based tools. Repository: rC Clang https://reviews.llvm.org/D47074 Files: include/clang/Tooling/Tooling.h lib/Tooling/Tooling.cpp Index:

r332734 - Fix unused variable warning in r332724

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 09:29:42 2018 New Revision: 332734 URL: http://llvm.org/viewvc/llvm-project?rev=332734=rev Log: Fix unused variable warning in r332724 Modified: cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp Modified: cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp URL:

r332727 - [clang-format/ObjC] Correctly annotate single-component ObjC method invocations

2018-05-18 Thread Ben Hamilton via cfe-commits
Author: benhamilton Date: Fri May 18 08:27:02 2018 New Revision: 332727 URL: http://llvm.org/viewvc/llvm-project?rev=332727=rev Log: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations Summary: Previously, clang-format's parser would fail to annotate the selector in a

r332728 - [ASTImporter] Enable disabled but passing test

2018-05-18 Thread Gabor Marton via cfe-commits
Author: martong Date: Fri May 18 08:46:18 2018 New Revision: 332728 URL: http://llvm.org/viewvc/llvm-project?rev=332728=rev Log: [ASTImporter] Enable disabled but passing test Summary: There is a test which passes since D32947, but it was forgotten to be enabled. This patch enables that disabled

[PATCH] D47058: [ASTImporter] Fix ClassTemplateSpecialization in wrong DC

2018-05-18 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin accepted this revision. a.sidorin added a comment. This revision is now accepted and ready to land. Hi Gabor! I have a question. Comment at: lib/AST/ASTImporter.cpp:4305 +// Add to the DC only if it was an explicit specialization/instantiation. +if

[PATCH] D47058: [ASTImporter] Fix ClassTemplateSpecialization in wrong DC

2018-05-18 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin requested changes to this revision. a.sidorin added a comment. This revision now requires changes to proceed. (Sorry, accepted accidentially). Repository: rC Clang https://reviews.llvm.org/D47058 ___ cfe-commits mailing list

Re: r332720 - Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Vedant Kumar via cfe-commits
Hi Eric, I think there might be a cyclic dependency issue here, possibly one that's only visible with LLVM_ENABLE_MODULES=On. I see: While building module 'Clang_Tooling' imported from /Users/vsk/src/llvm.org-master/llvm/tools/clang/lib/Tooling/Execution.cpp:10:

Re: r332720 - Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via cfe-commits
Hi Vedant, It seems that your build was not using cmake files in the source tree? lib/Tooling/Inclusions/ is a (new) standalone library (clangToolingInclusions, similar to clangToolingCore). You might need update your build to reflect this change. Let me know if you have any further question.

[PATCH] D47069: [ASTImporter] Enable disabled but passing test

2018-05-18 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin accepted this revision. a.sidorin added a comment. This revision is now accepted and ready to land. Nice! Repository: rC Clang https://reviews.llvm.org/D47069 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47074: [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS

2018-05-18 Thread Benjamin Kramer via Phabricator via cfe-commits
bkramer accepted this revision. bkramer added a comment. This revision is now accepted and ready to land. lg Repository: rC Clang https://reviews.llvm.org/D47074 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r332731 - [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 09:06:19 2018 New Revision: 332731 URL: http://llvm.org/viewvc/llvm-project?rev=332731=rev Log: [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS Summary: ... to support purely VFS-based tools. Reviewers: bkramer Subscribers: klimek, cfe-commits

[PATCH] D47074: [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC332731: [Tooling] Add an overload of runToolOnCodeWithArgs that takes VFS (authored by ioeric, committed by ). Changed prior to commit: https://reviews.llvm.org/D47074?vs=147526=147529#toc Repository:

[clang-tools-extra] r332732 - Trying to fix clang-move tests on windows build bot broken by r332717

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 09:08:18 2018 New Revision: 332732 URL: http://llvm.org/viewvc/llvm-project?rev=332732=rev Log: Trying to fix clang-move tests on windows build bot broken by r332717 http://lab.llvm.org:8011/builders/clang-x64-ninja-win7/builds/10702 Modified:

[PATCH] D47044: Ensure that we only visit a destructor for a reference if type information is available.

2018-05-18 Thread Matthew Voss via Phabricator via cfe-commits
ormris added a comment. That could work. Is the implementation similar? Repository: rC Clang https://reviews.llvm.org/D47044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D46911: [Fixed Point Arithmetic] Addition of the remaining fixed point types and their saturated equivalents

2018-05-18 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 147541. leonardchan added a comment. Updated formatting Repository: rC Clang https://reviews.llvm.org/D46911 Files: include/clang/AST/ASTContext.h include/clang/AST/BuiltinTypes.def include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D47028: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations

2018-05-18 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton added inline comments. Comment at: lib/Format/TokenAnnotator.cpp:510 +CurrentToken->Previous->Type = TT_SelectorName; + } // determineStarAmpUsage() thinks that '*' '[' is allocating an jolesiak wrote: > I'd remove

[PATCH] D47028: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations

2018-05-18 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton updated this revision to Diff 147516. benhamilton marked an inline comment as done. benhamilton added a comment. Style Repository: rC Clang https://reviews.llvm.org/D47028 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestObjC.cpp Index:

[PATCH] D47028: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations

2018-05-18 Thread Ben Hamilton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC332727: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations (authored by benhamilton, committed by ). Changed prior to commit:

[PATCH] D46940: [ASTImporter] make sure that ACtx::getParents still works

2018-05-18 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin accepted this revision. a.sidorin added a comment. LGTM. Aaron, could you please confirm that AST changes are fine? Comment at: include/clang/AST/ASTContext.h:638 +ReleaseParentMapEntries(); +PointerParents = nullptr; + } I'd prefer to call

[PATCH] D44539: [Sema][Objective-C] Add check to warn when property of objc type has assign attribute

2018-05-18 Thread Alfred Zien via Phabricator via cfe-commits
QF5690 added a comment. It's been a couple of months now, @rjmccall any ETA's? Repository: rC Clang https://reviews.llvm.org/D44539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47065: [clangd] Enable parsing of non-doxygen comments in global-symbol-builder

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. Should we also change the behavior in dynamic index? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D47065 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D45679: [clang-tidy] Add ExprMutationAnalyzer, that analyzes whether an expression is mutated within a statement.

2018-05-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/utils/ExprMutationAnalyzer.cpp:21-25 + for (const auto *Init : Node.capture_inits()) { +if (Init == E) + return true; + } + return false; This can be replaced with `return

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 147487. ioeric added a comment. Minor cleanup Repository: rC Clang https://reviews.llvm.org/D47060 Files: include/clang/Basic/VirtualFileSystem.h lib/Basic/VirtualFileSystem.cpp unittests/Basic/VirtualFileSystemTest.cpp Index:

[PATCH] D46472: [HIP] Support offloading by linker script

2018-05-18 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D46472#1103577, @t-tye wrote: > LGTM except for minor suggestions. Thanks. Will make changes when committing. https://reviews.llvm.org/D46472 ___ cfe-commits mailing list

[PATCH] D47063: [clangd] Keep only a limited number of idle ASTs in memory

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Another alternative that I've considered was evicting the ASTs from memory after a certain period of time, e.g. after 30 seconds of inactivity for some file. This might be simpler and also cover the use-case of speeding up multiple code navigation requests

[PATCH] D47066: [clangd] Remove ignored Preamble::CanReuse call from completion

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added reviewers: ioeric, sammccall. Herald added subscribers: jkorous, MaskRay, klimek. Now that the clients who relied on stats for files from preamble are gone. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D47066 Files:

[PATCH] D45212: [HIP] Let CUDA toolchain support HIP language mode and amdgpu

2018-05-18 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. Hi Artem, I've addressed your comments. Any further changes are needed? Thanks. https://reviews.llvm.org/D45212 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Clement Courbet via Phabricator via cfe-commits
courbet added inline comments. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:35 + hasSourceExpression(IsFloatExpr), + unless(hasParent(castExpr( +

r332724 - [HIP] Support offloading by linker script

2018-05-18 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Fri May 18 08:07:56 2018 New Revision: 332724 URL: http://llvm.org/viewvc/llvm-project?rev=332724=rev Log: [HIP] Support offloading by linker script To support linking device code in different source files, it is necessary to embed fat binary at host linking stage. This

[PATCH] D46472: [HIP] Support offloading by linker script

2018-05-18 Thread Yaxun Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL332724: [HIP] Support offloading by linker script (authored by yaxunl, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Benjamin Kramer via Phabricator via cfe-commits
bkramer accepted this revision. bkramer added a comment. This revision is now accepted and ready to land. lg Comment at: lib/Basic/VirtualFileSystem.cpp:387 + SmallVectorImpl ) const { + // Not using overlays_begin/end because this method is

[PATCH] D45532: [StaticAnalyzer] Checker to find uninitialized fields after a constructor call

2018-05-18 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus updated this revision to Diff 147485. Szelethus added a comment. In this diff, I preferred placing `TODO`s in places where the logic of the checker would have changed too much. While I didn't have a strict rule for this in mind, I tried changing as little as possible in order to

[PATCH] D47065: [clangd] Enable parsing of non-doxygen comments in global-symbol-builder

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added reviewers: ioeric, sammccall. Herald added subscribers: jkorous, MaskRay, klimek. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D47065 Files: clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp Index:

[clang-tools-extra] r332721 - [clangd] Adapt file migration in r332720

2018-05-18 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri May 18 07:17:36 2018 New Revision: 332721 URL: http://llvm.org/viewvc/llvm-project?rev=332721=rev Log: [clangd] Adapt file migration in r332720 Modified: clang-tools-extra/trunk/clangd/CMakeLists.txt clang-tools-extra/trunk/clangd/Headers.h Modified:

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Clement Courbet via Phabricator via cfe-commits
courbet added a comment. Thanks. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:35 + hasSourceExpression(IsFloatExpr), + unless(hasParent(castExpr( +

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Clement Courbet via Phabricator via cfe-commits
courbet updated this revision to Diff 147508. courbet marked 2 inline comments as done. courbet added a comment. - More explicit documentation. - Do not trigger in template and macro contexts. - More tests. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D38455 Files:

[PATCH] D47063: [clangd] Keep only a limited number of idle ASTs in memory

2018-05-18 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added subscribers: arphaman, malaperle. malaperle added a comment. In https://reviews.llvm.org/D47063#1104417, @ilya-biryukov wrote: > Maybe we can even store enough information to not need the AST for navigation > at all and build it only for features like refactorings. >

[PATCH] D47070: [CUDA] Upgrade linked bitcode to enable inlining

2018-05-18 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld created this revision. Hahnfeld added reviewers: tra, jlebar. Herald added a subscriber: cfe-commits. Revision https://reviews.llvm.org/rC329829 added the architecture to "target-features". This prevents inlining of previously generated bitcode because the feature sets don't match. Thus

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: bkramer. Herald added a subscriber: cfe-commits. Repository: rC Clang https://reviews.llvm.org/D47060 Files: include/clang/Basic/VirtualFileSystem.h lib/Basic/VirtualFileSystem.cpp unittests/Basic/VirtualFileSystemTest.cpp Index:

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:35 + hasSourceExpression(IsFloatExpr), + unless(hasParent(castExpr( +

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL332717: [VFS] Implement getRealPath for OverlayFileSystem. (authored by ioeric, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D47060 Files:

Re: r294879 - [Driver] Use stem() and not filename().

2018-05-18 Thread Nico Weber via cfe-commits
I think this code is probably dead since the stem is "ld.lld" for lld, not "lld". On Sat, Feb 11, 2017 at 7:22 PM, Davide Italiano via cfe-commits < cfe-commits@lists.llvm.org> wrote: > On Sat, Feb 11, 2017 at 4:19 PM, Rui Ueyama wrote: > > On Sat, Feb 11, 2017 at 3:44 PM,

[PATCH] D47068: Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, mgorny, klimek. clangToolingCore is linked into almost everything (incl. clang), but not few tools need #include manipulation at this point. So pull this into a separate library in

[PATCH] D47068: Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov added a comment. This revision is now accepted and ready to land. LGTM with a minor naming suggestion. Comment at: include/clang/Format/Format.h:20 #include "clang/Tooling/Core/Replacement.h" +#include

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. I think this generally LGTM. You should wait a bit to see if @alexfh has any other concerns. Comment at:

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Clement Courbet via Phabricator via cfe-commits
courbet added a comment. Great, thanks for the review ! Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D38455 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47028: [clang-format/ObjC] Correctly annotate single-component ObjC method invocations

2018-05-18 Thread Jacek Olesiak via Phabricator via cfe-commits
jolesiak accepted this revision. jolesiak added inline comments. This revision is now accepted and ready to land. Comment at: lib/Format/TokenAnnotator.cpp:510 +CurrentToken->Previous->Type = TT_SelectorName; + } // determineStarAmpUsage() thinks

[PATCH] D46940: [ASTImporter] make sure that ACtx::getParents still works

2018-05-18 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: lib/AST/ASTImporter.cpp:6776 + // been invalidated to avoid repeatedly calling this. + ToContext.invalidateParents(); + Can an `Expr` has a parent too? If yes, why not invalidate the parents in `Import(Expr*)` ? I am

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 147488. ioeric added a comment. Fix test... Repository: rC Clang https://reviews.llvm.org/D47060 Files: include/clang/Basic/VirtualFileSystem.h lib/Basic/VirtualFileSystem.cpp unittests/Basic/VirtualFileSystemTest.cpp Index:

[PATCH] D47060: [VFS] Implement getRealPath for OverlayFileSystem.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 147491. ioeric marked an inline comment as done. ioeric added a comment. - Add and use const_iterator. Repository: rC Clang https://reviews.llvm.org/D47060 Files: include/clang/Basic/VirtualFileSystem.h lib/Basic/VirtualFileSystem.cpp

[PATCH] D47063: [clangd] Keep only a limited number of idle ASTs in memory

2018-05-18 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added a reviewer: sammccall. Herald added subscribers: jkorous, MaskRay, ioeric, javed.absar, klimek. After this commit, clangd will only keep the last 3 accessed ASTs in memory. Preambles for each of the opened files are still kept in memory to

[PATCH] D47068: Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via Phabricator via cfe-commits
ioeric marked an inline comment as done. ioeric added inline comments. Comment at: include/clang/Format/Format.h:20 #include "clang/Tooling/Core/Replacement.h" +#include "clang/Tooling/Inclusions/IncludeStyle.h" #include "llvm/ADT/ArrayRef.h" ilya-biryukov

[PATCH] D46940: [ASTImporter] make sure that ACtx::getParents still works

2018-05-18 Thread Rafael Stahl via Phabricator via cfe-commits
r.stahl added inline comments. Comment at: lib/AST/ASTImporter.cpp:6776 + // been invalidated to avoid repeatedly calling this. + ToContext.invalidateParents(); + martong wrote: > Can an `Expr` has a parent too? If yes, why not invalidate the parents in >

[clang-tools-extra] r332716 - Silence a truncation warning; NFC.

2018-05-18 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri May 18 06:18:41 2018 New Revision: 332716 URL: http://llvm.org/viewvc/llvm-project?rev=332716=rev Log: Silence a truncation warning; NFC. Modified: clang-tools-extra/trunk/clangd/Quality.cpp Modified: clang-tools-extra/trunk/clangd/Quality.cpp URL:

[PATCH] D38455: [clang-tidy] new cppcoreguidelines-narrowing-conversions check.

2018-05-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:35 + hasSourceExpression(IsFloatExpr), + unless(hasParent(castExpr( +

Re: r332720 - Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread David Blaikie via cfe-commits
I haven't looked in detail here, but in general: Don't split an implementation and its headers into different notional libraries, as that breaks modular code generation (an implementation and its headers usually have circular dependencies - inline functions that call non-inline functions, and the

[PATCH] D46964: Implement class deduction guides for `std::array`

2018-05-18 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF accepted this revision. EricWF added inline comments. This revision is now accepted and ready to land. Comment at: include/array:75 + template +array(T, U...) -> array; Don't we normally comment `// C++17` or similar for new

[libcxxabi] r332764 - private_typeinfo: propagate static flags in vmi search_above_dst method

2018-05-18 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Fri May 18 13:42:53 2018 New Revision: 332764 URL: http://llvm.org/viewvc/llvm-project?rev=332764=rev Log: private_typeinfo: propagate static flags in vmi search_above_dst method This adds the test which was mistakenly not committed in r332763. Patch by Ryan Prichard

[PATCH] D46940: [ASTImporter] make sure that ACtx::getParents still works

2018-05-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: rsmith. aaron.ballman added a comment. Adding Richard as he has more background in this area. In general, I think it's okay - if we invalidate too often, we do lose some performance, but the correctness should still be there. I'll let Richard provide the final

[PATCH] D46740: [Clang Tablegen][RFC] Allow Early Textual Substitutions in `Diagnostic` messages.

2018-05-18 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF updated this revision to Diff 147581. EricWF marked an inline comment as done. EricWF added a comment. - Add error if a substitution and a diagnostic share the same name. Any final comments on this? https://reviews.llvm.org/D46740 Files: docs/InternalsManual.rst

[PATCH] D46740: [Clang Tablegen][RFC] Allow Early Textual Substitutions in `Diagnostic` messages.

2018-05-18 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF marked 2 inline comments as done. EricWF added inline comments. Comment at: utils/TableGen/ClangDiagnosticsEmitter.cpp:514 + std::vector Diags = Records.getAllDerivedDefinitions("Diagnostic"); + llvm::for_each(Diags, [&](Record *R) { substituteDiagText(R, SubsMap); });

[PATCH] D47070: [CUDA] Upgrade linked bitcode to enable inlining

2018-05-18 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. I think that's intended because the generated code might use instructions based on that feature. If we want to ignore that, we could override `TargetTransformInfo::areInlineCompatible` for NVPTX to only compare `target-cpu` Repository: rC Clang

Re: r332720 - Move #include manipulation code to new lib/Tooling/Inclusions.

2018-05-18 Thread Eric Liu via cfe-commits
Thanks a lot for looking into this Bruno! The fix looks promising; I'll give it a try next week :D On Fri, May 18, 2018 at 10:33 PM David Blaikie via cfe-commits < cfe-commits@lists.llvm.org> wrote: > I haven't looked in detail here, but in general: Don't split an > implementation and its

RE: r332470 - Add support for __declspec(code_seg("segname"))

2018-05-18 Thread Keane, Erich via cfe-commits
Hi Richard- Thanks for the feedback. I’m copying the author of this patch on this email for further discussion if you care to. We’ll have her take another look at it. Thanks for the revert. (https://github.com/llvm-mirror/clang/commit/746b78de7812bc785fbb5207b788348040b23fa7). -Erich From:

[libcxxabi] r332763 - private_typeinfo: propagate static flags in vmi search_above_dst method

2018-05-18 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Fri May 18 13:39:57 2018 New Revision: 332763 URL: http://llvm.org/viewvc/llvm-project?rev=332763=rev Log: private_typeinfo: propagate static flags in vmi search_above_dst method Patch by Ryan Prichard Propagate the found_our_static_ptr and found_any_static_type flags from

  1   2   >