[PATCH] D61931: [Driver] Use --android-tls for Android ARM/AArch64 when lld is used

2019-05-15 Thread Ryan Prichard via Phabricator via cfe-commits
rprichard added inline comments. Comment at: lib/Driver/ToolChains/Gnu.cpp:404 + const Arg *A = Args.getLastArg(options::OPT_fuse_ld_EQ); + if (A && StringRef(A->getValue()).contains("lld")) +CmdArgs.push_back("--android-tls"); The logic used fo

[PATCH] D61845: [builtin] Fixed definitions of builtins that rely on the int/long long type is 32/64 bits

2019-05-15 Thread Karl-Johan Karlsson via Phabricator via cfe-commits
Ka-Ka updated this revision to Diff 199559. Ka-Ka marked 2 inline comments as done. Ka-Ka added a comment. Updated according to review comments Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61845/new/ https://reviews.llvm.org/D61845 Files: include/clang/Basic/

Re: r360637 - PR41817: Fix regression in r359260 that caused the MS compatibility

2019-05-15 Thread Hans Wennborg via cfe-commits
On Tue, May 14, 2019 at 6:35 PM Richard Smith wrote: > > On Tue, 14 May 2019, 03:09 Hans Wennborg via cfe-commits, > wrote: >> >> Actually, we didn't notice r359260 in Chromium, however this one >> (r360637) caused Clang to start asserting during our builds >> (https://bugs.chromium.org/p/chromi

[PATCH] D61850: Removed superfluous and slightly annoying newlines in run-clang-tidy's output.

2019-05-15 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In D61850#1500330 , @svenpanne wrote: > In D61850#1500298 , @JonasToth wrote: > > > [...] please ensure that e.g. clang-analyzer-* output looks proper as well > > and `-quiet` does, too.

[PATCH] D61281: [clang-format] Fixed self assignment

2019-05-15 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61281/new/ https://reviews.llvm.org/D61281 ___ cfe-commits mailing li

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Will do. Also think reporting annotation tokens is ok, one can easily tell them apart and filter them by looking at the corresponding flags in `clang::Token`, will put it into the docs, though Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION htt

[PATCH] D36357: Added a better diagnostic when using the delete operator with lambdas

2019-05-15 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 199566. Rakete added a comment. - Use TryConsumeToken Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D36357/new/ https://reviews.llvm.org/D36357 Files: clang/include/clang/Basic/DiagnosticParseKinds.td

[PATCH] D60953: [clangd] Respect clang-tidy suppression comments

2019-05-15 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Thanks, this looks good. I think we should avoid the subclassing, but any of {generalize in the next patch, different approach for the next patch, subclass for now and clean up later} se

[PATCH] D36357: Added a better diagnostic when using the delete operator with lambdas

2019-05-15 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 199565. Rakete added a comment. - Fix crash with invalid postfix expr - Don't emit FixIt when using < Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D36357/new/ https://reviews.llvm.org/D36357 Files: cl

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-05-15 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D57858#1502052 , @NoQ wrote: > In D57858#1501065 , @dkrupp wrote: > > > These are the alpha checkers that we are testing in Ericsson: > > > Hmm, if you don't mind i'll take this to cfe-

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-15 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 199569. martong added a comment. - Rebase to master Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61438/new/ https://reviews.llvm.org/D61438 Files: clang/include/clang/AST/ASTImporter.h clang/lib/AST/ASTIm

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-15 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. In D61634#1502201 , @tejohnson wrote: > Using function level attributes instead of module flags does provide finer > grained control and avoids the conservativeness when merging IR for LTO. The > downsides I see, mostly just in

r360760 - [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-15 Thread Gabor Marton via cfe-commits
Author: martong Date: Wed May 15 03:29:48 2019 New Revision: 360760 URL: http://llvm.org/viewvc/llvm-project?rev=360760&view=rev Log: [ASTImporter] Use llvm::Expected and Error in the importer API Summary: This is the final phase of the refactoring towards using llvm::Expected and llvm::Error in

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-15 Thread Gabor Marton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL360760: [ASTImporter] Use llvm::Expected and Error in the importer API (authored by martong, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D61931: [Driver] Use --android-tls for Android ARM/AArch64 when lld is used

2019-05-15 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 199574. MaskRay added a comment. Use Args.MakeArgString(ToolChain.GetLinkerPath()); Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61931/new/ https://reviews.llvm.org/D61931 Files: lib/Driver/ToolChains/Gnu.cpp test/Drive

[PATCH] D61487: [clang-tidy] Make the plugin honor NOLINT

2019-05-15 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik added a comment. Ping. alexfh? Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61487/new/ https://reviews.llvm.org/D61487 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

[PATCH] D61939: AArch64: add support for arm64_23 (ILP32) IR generation

2019-05-15 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover created this revision. Herald added subscribers: jfb, kristof.beyls, javed.absar, mcrosier. Herald added a project: clang. This patch implements the arm64_32 ABI used in watchOS from the Clang side. It's mostly pretty straightforward since it's so close to normal AArch64: handle th

[PATCH] D59413: Fix isInSystemMacro in presence of macro and pasted token

2019-05-15 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 199585. serge-sans-paille added a comment. Updated with clang-formated diff CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59413/new/ https://reviews.llvm.org/D59413 Files: clang/include/clang/Basic/SourceManager.h clang/test/Misc/no-w

[PATCH] D61816: [CFG] [analyzer] pr41300: Add a branch to skip virtual base initializers when they are handled by the superclass.

2019-05-15 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Exquisite detective work as always! I read a bit of the standard, your summary, the bugreport and the new test cases, and I feel confident that I have a good understanding of the problem and your solution, though I didn't dig through the details just yet. At a first g

[PATCH] D60283: [DebugInfo] Don't emit checksums when compiling a preprocessed CPP

2019-05-15 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea updated this revision to Diff 199599. aganea marked an inline comment as done. aganea added a comment. Updated again with a different solution. We can't just act on `Entry.getFile().hasLineDirectives()` because a directive such as `#line 100` simply overrides the `__LINE__`, not `__FILE__

[PATCH] D61945: ftime-trace as a CoreOption

2019-05-15 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea created this revision. aganea added reviewers: thakis, anton-afanasyev. aganea added a project: clang. As suggested here by @thakis , make so that `-ftime-trace` can be used directly in clang-cl without `-Xclang` Repository: rC Clang https://r

[PATCH] D61945: ftime-trace as a CoreOption

2019-05-15 Thread Anton Afanasyev via Phabricator via cfe-commits
anton-afanasyev accepted this revision. anton-afanasyev added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61945/new/ https://reviews.llvm.org/D61945 ___

[PATCH] D61923: [GWP-ASan] Mutex implementation [2].

2019-05-15 Thread Kostya Kortchinsky via Phabricator via cfe-commits
cryptoad added a comment. In D61923#1502337 , @eugenis wrote: > I think the idea is that implementing our own spinlock is not much harder > than having 3 platform-specific implementations (posix, window, fuchsia). > Also, scudo_standalone is doing the sa

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-15 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. In D61634#1502685 , @gchatelet wrote: > In D61634#1502201 , @tejohnson wrote: > > > Using function level attributes instead of module flags does provide finer > > grained control and avoi

[PATCH] D60162: [ThinLTO] Add module flags for TargetLibraryInfoImpl and use in LTO backends

2019-05-15 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. There is discussion of using function attributes to control this instead, see https://reviews.llvm.org/D61634. I'll hold off on making the planned changes here until the overall approach is decided. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[clang-tools-extra] r360779 - [clang-tidy] new check: bugprone-branch-clone

2019-05-15 Thread Kristof Umann via cfe-commits
Author: szelethus Date: Wed May 15 08:06:25 2019 New Revision: 360779 URL: http://llvm.org/viewvc/llvm-project?rev=360779&view=rev Log: [clang-tidy] new check: bugprone-branch-clone Implement a check for detecting if/else if/else chains where two or more branches are Type I clones of each other (

[PATCH] D54757: [clang-tidy] new check: bugprone-branch-clone

2019-05-15 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE360779: [clang-tidy] new check: bugprone-branch-clone (authored by Szelethus, committed by ). Changed prior to commit: https://reviews.llvm.org/D54757?vs=198025&id=199611#toc Repository: rCTE Clang

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea created this revision. gtbercea added reviewers: ABataev, tra, jdoerfert, hfinkel, caomhin. Herald added subscribers: cfe-commits, guansong. Herald added a project: clang. In OpenMP device offloading we must ensure that unde C++ 17, the inclusion of cstdlib will works correctly. Reposi

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-15 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added a subscriber: chandlerc. hfinkel added a comment. In D61634#1502201 , @tejohnson wrote: > In D61634#1502138 , @hfinkel wrote: > > > In D61634#1502043 , @efriedm

[PATCH] D61950: [PowerPC64] recognize target triplet with ABI info (i.e. powerpc64-unknown-freebsd13-elfv2)

2019-05-15 Thread Alfredo Dal'Ava Júnior via Phabricator via cfe-commits
adalava created this revision. Herald added subscribers: llvm-commits, cfe-commits, jsji, dexonsmith, kbarton, hiraditya, nemanjai. Herald added projects: clang, LLVM. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D61950 Files: clang/lib/Basic/Targets/PPC.h llvm/include/llv

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added inline comments. Comment at: lib/Headers/__clang_cuda_device_functions.h:1477 #endif // CUDA_VERSION >= 9020 +#if __cplusplus >= 201703L +__DEVICE__ int abs(int __a) noexcept { return __nv_abs(__a); } If I recall correctly, `__cplusplus` is not de

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/Basic/Targets/PPC.h:382 resetDataLayout("e-m:e-i64:64-n32:64"); - ABI = "elfv2"; } else { Have you researched how GNU as chooses the default ABI? I think the change may break some Linux ppc64l

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay accepted this revision. MaskRay added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Basic/Targets/PPC.h:382 resetDataLayout("e-m:e-i64:64-n32:64"); - ABI = "elfv2"; } else { MaskRay wrote: > Have

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: llvm/lib/Target/PowerPC/PPCTargetMachine.cpp:217 case Triple::ppc64: -return PPCTargetMachine::PPC_ABI_ELFv1; +// if ELFv2 on target triple i.e. powerpc64-unknown-freebsd12.0-elfv2 +if (TT.getEnvironment() == llvm::Triple:

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. Missing `defined(__cplusplus)` to avoid warnings and we have to resolve the two new includes. Otherwise, this looks good. So, if you "fix" both go ahead and commit, if not, lets discuss. Comment at: lib/Headers/__clang_cuda_device_functions.h:1477

Re: r360308 - [c++20] Implement P0846R0: allow (ADL-only) calls to template-ids whose

2019-05-15 Thread Stephan Bergmann via cfe-commits
The below commit started to cause the following failure: $ cat test.cc template struct S1 { static int const n = 0; }; template struct S2 { typedef int t; }; template struct S3 { typename S2::n < 0, int>::t n; }; $ clang++ -fsyntax-only test.cc test.cc:3:53: error: use 'template' keyword to tre

[PATCH] D44100: [ASTImporter] Reorder fields after structure import is finished

2019-05-15 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 199629. martong marked 13 inline comments as done. martong added a comment. - Address Shafik's comments and update assertions Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D44100/new/ https://reviews.llvm.org/D4

r360783 - Test commit

2019-05-15 Thread Kevin Petit via cfe-commits
Author: kpet Date: Wed May 15 09:39:28 2019 New Revision: 360783 URL: http://llvm.org/viewvc/llvm-project?rev=360783&view=rev Log: Test commit Remove stray space. Signed-off-by: Kevin Petit Modified: cfe/trunk/lib/Sema/SemaType.cpp Modified: cfe/trunk/lib/Sema/SemaType.cpp URL: http://ll

[PATCH] D44100: [ASTImporter] Reorder fields after structure import is finished

2019-05-15 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: lib/AST/ASTImporter.cpp:1643 +if (!ImportedOrErr) { + // For RecordDecls, failed import of a field will break the layout of the + // structure. Handle it as an error. shafik wrote: > What cases are failed i

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: lib/Headers/__clang_cuda_device_functions.h:1477 #endif // CUDA_VERSION >= 9020 +#if __cplusplus >= 201703L +__DEVICE__ int abs(int __a) noexcept { return __nv_abs(__a); } jdoerfert wrote: > Hahnfeld wrote: > > If I recall

[PATCH] D60283: [DebugInfo] Don't emit checksums when compiling a preprocessed CPP

2019-05-15 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. Minor stuff. This solution is surprisingly simple, the main question being (and I don't have an answer) whether increasing the size of PresumedLoc is okay. Comment at: lib/Basic/SourceManager.cpp:1460 +FID = FileID::get(0); // contents of fi

[clang-tools-extra] r360785 - [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-15 Thread Don Hinton via cfe-commits
Author: dhinton Date: Wed May 15 09:58:58 2019 New Revision: 360785 URL: http://llvm.org/viewvc/llvm-project?rev=360785&view=rev Log: [clang-tidy] modernize-loop-convert: impl const cast iter Summary: modernize-loop-convert was not detecting implicit casts to const_iterator as convertible to rang

[PATCH] D61827: [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-15 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE360785: [clang-tidy] modernize-loop-convert: impl const cast iter (authored by dhinton, committed by ). Changed prior to commit: https://reviews.llvm.org/D61827?vs=199496&id=199631#toc Repository:

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-15 Thread Wink Saville via Phabricator via cfe-commits
winksaville abandoned this revision. winksaville added a comment. Abandoning, @beanz has proposed a better solution, D61909 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61804/new/ https://reviews.llvm.org/D61804

[PATCH] D61923: [GWP-ASan] Mutex implementation [2].

2019-05-15 Thread Mitch Phillips via Phabricator via cfe-commits
hctim updated this revision to Diff 199632. hctim marked 2 inline comments as done. hctim added a comment. In D61923#1502988 , @cryptoad wrote: > Is the question why do Scudo has its own as opposed to rely on platform > specific ones? Yes, I have assump

Re: [clang-tools-extra] r360785 - [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-15 Thread Don Hinton via cfe-commits
Just wanted to note that this patch was contributed by Torbjörn Klatt, and I failed to add the following line to the commit message: Patch by Torbjörn Klatt! Sorry about that Torbjörn. On Wed, May 15, 2019 at 9:56 AM Don Hinton via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: dhin

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Alfredo Dal'Ava Júnior via Phabricator via cfe-commits
adalava marked an inline comment as done. adalava added inline comments. Comment at: clang/lib/Basic/Targets/PPC.h:382 resetDataLayout("e-m:e-i64:64-n32:64"); - ABI = "elfv2"; } else { MaskRay wrote: > MaskRay wrote: > > Have you researched how G

[PATCH] D61923: [GWP-ASan] Mutex implementation [2].

2019-05-15 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. > In D61923#1502404 , @jfb wrote: > >> > We can't use `std::mutex` as we must be C-compatible >> >> Can you clarify what you mean by this? I don't understand. >> Have you asked on libcxx-dev? Is there interest in the libc++ community

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Alfredo Dal'Ava Júnior via Phabricator via cfe-commits
adalava updated this revision to Diff 199633. adalava added a comment. - remove redundant comment Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61950/new/ https://reviews.llvm.org/D61950 Files: clang/lib/Basic/Targets/PPC.h llvm/include/llvm/A

[PATCH] D61950: [PowerPC64] adds ABI parsing when specified on target triple

2019-05-15 Thread Alfredo Dal'Ava Júnior via Phabricator via cfe-commits
adalava marked 3 inline comments as done. adalava added inline comments. Comment at: llvm/lib/Target/PowerPC/PPCTargetMachine.cpp:217 case Triple::ppc64: -return PPCTargetMachine::PPC_ABI_ELFv1; +// if ELFv2 on target triple i.e. powerpc64-unknown-freebsd12.0-elfv2 +

[PATCH] D61747: [clang-tidy] remove default header-filter for run-clang-tidy

2019-05-15 Thread Don Hinton via Phabricator via cfe-commits
hintonda added a comment. I've also had issues with this behavior. It's a bad default, as the PR notes, but is there a way to provide a better one and still respect the config file? Also, could you add a test for this? Perhaps in `clang-tools-extra/test//clang-tidy/run-clang-tidy.cpp`. Repo

[clang-tools-extra] r360787 - Revert [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-15 Thread Don Hinton via cfe-commits
Author: dhinton Date: Wed May 15 10:36:54 2019 New Revision: 360787 URL: http://llvm.org/viewvc/llvm-project?rev=360787&view=rev Log: Revert [clang-tidy] modernize-loop-convert: impl const cast iter This reverts r360785 (git commit 42d28be802fe5beab18bc1a27f89894c0a290d44) Modified: clang-to

[PATCH] D61923: [GWP-ASan] Mutex implementation [2].

2019-05-15 Thread Mitch Phillips via Phabricator via cfe-commits
hctim added a comment. In D61923#1503272 , @jfb wrote: > Have you asked on libcxx-dev whether a stand-alone base is something of > interest to them? No, but I will follow up on that. > Kinda... but your answer really sounds like this is a Google-only p

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. I've added a new parameter to `EnterToken` and `EnterTokenStream`. There are a bunch of interesting cases. `Preprocessor::AnnotateCachedTokens` is one. It consumes some `CachedTokens` (which are always considered re-injected) and replaces them with a single annot

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 199637. ilya-biryukov added a comment. Herald added a subscriber: eraman. - Properly mark tokens as reinjected where necessary. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59885/new/ https://reviews.llv

[clang-tools-extra] r360788 - [clang-tidy] Recommit r360785 "modernize-loop-convert: impl const cast iter" with correct attribution

2019-05-15 Thread Don Hinton via cfe-commits
Author: dhinton Date: Wed May 15 10:47:51 2019 New Revision: 360788 URL: http://llvm.org/viewvc/llvm-project?rev=360788&view=rev Log: [clang-tidy] Recommit r360785 "modernize-loop-convert: impl const cast iter" with correct attribution Summary: modernize-loop-convert was not detecting implicit c

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 199639. ilya-biryukov marked an inline comment as done. ilya-biryukov added a comment. - Improve comment, remove redundant braces Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59885/new/ https://reviews.l

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang/lib/Lex/Preprocessor.cpp:955 --LexLevel; + if (OnToken && LexLevel == 0 && !Result.getFlag(Token::IsReinjected)) +OnToken(Result); Could probably remove the `IsReinjected` check from here. It's fine t

[PATCH] D61909: Add Clang shared library with C++ exports

2019-05-15 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. In D61909#1502446 , @winksaville wrote: > Questions: > > - Should we only build `libclang_shared.so` if `LLVM_BUILD_LLVM_DYLIB` is ON? `LLVM_BUILD_LLVM_DYLIB` is actually not the important option to think about because it has no i

[PATCH] D61957: [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary

2019-05-15 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added reviewers: ahatanak, rjmccall. Herald added subscribers: dexonsmith, jkorous. Herald added a project: clang. Any of these methods can be overridden, so we always need to conservatively `invoke` these calls. Repository: rC Clang htt

[PATCH] D61958: [analyzer] RetainCount: Fix a crash when os_returns_retained_on_zero (_nonzero) is applied to functions that return weird stuff.

2019-05-15 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added a reviewer: dcoughlin. Herald added subscribers: cfe-commits, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a project: clang. The checker crashes when it tries to assume a structure to

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-15 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:1521 Tok[0].setAnnotationValue(AnnotationVal); - EnterTokenStream(std::move(Tok), 1, true); + EnterTokenStream(std::move(Tok), 1, true, /*IsReinject*/ true); } I think it'd be more use

[PATCH] D61958: [analyzer] RetainCount: Fix a crash when os_returns_retained_on_zero (_nonzero) is applied to functions that return weird stuff.

2019-05-15 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. Looks good do me. Thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61958/new/ https://reviews.llvm.org/D61958 ___

r360790 - [analyzer] RetainCount: Fix os_returns_retained_on_zero with weird return types.

2019-05-15 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed May 15 11:41:32 2019 New Revision: 360790 URL: http://llvm.org/viewvc/llvm-project?rev=360790&view=rev Log: [analyzer] RetainCount: Fix os_returns_retained_on_zero with weird return types. The checker was crashing when it was trying to assume a structure to be null or

[PATCH] D61958: [analyzer] RetainCount: Fix a crash when os_returns_retained_on_zero (_nonzero) is applied to functions that return weird stuff.

2019-05-15 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360790: [analyzer] RetainCount: Fix os_returns_retained_on_zero with weird return types. (authored by dergachev, committed by ). Changed prior to commit: https://reviews.llvm.org/D61958?vs=199647&id=19

[PATCH] D61845: [builtin] Fixed definitions of builtins that rely on the int/long long type is 32/64 bits

2019-05-15 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61845/new/ https://reviews.llvm.org/D61845 ___ cfe-commit

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199651. gtbercea added a comment. - Refactor. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61949/new/ https://reviews.llvm.org/D61949 Files: lib/Headers/__clang_cuda_cmath.h lib/Headers/__clang_cuda_device_functions.h

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Headers/__clang_cuda_device_functions.h:1477 #endif // CUDA_VERSION >= 9020 +#if __cplusplus >= 201703L +__DEVICE__ int abs(int __a) noexcept { return __nv_abs(__a); } tra

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-15 Thread Kit Barton via Phabricator via cfe-commits
kbarton added a comment. I think this looks straightforward, as long as people agree to have a separate CreateConstrained* version of these functions. I'm not qualified to weigh in on that as I don't know Clang at all and can't comment about the tradeoffs (although I think they have been well a

[PATCH] D60956: [Sema] Fix the lookup for a declaration conflicting with an enumerator

2019-05-15 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno added a comment. Ping :) Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60956/new/ https://reviews.llvm.org/D60956 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[PATCH] D61909: Add Clang shared library with C++ exports

2019-05-15 Thread Wink Saville via Phabricator via cfe-commits
winksaville added a comment. IMHO "`BUILD_CLANG_DYLIB`" is needed. As you have it now libclang_shared.so is always builds on UNIX systems, which I believe means that all linux distros would have both increasing their sizes. I think the default should be "always" `build libclang*.a` as it is now

[PATCH] D61957: [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary

2019-05-15 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak accepted this revision. ahatanak added a comment. This revision is now accepted and ready to land. LGTM Comment at: clang/test/CodeGenObjC/convert-messages-to-runtime-calls.m:208 + } +} Can you add tests for `objc_alloc`, `objc_allocWithZone` and `obj

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. LGTM. Comment at: lib/Headers/__clang_cuda_cmath.h:42 +// variant is supported. +#if defined(_OPENMP) && defined(__cplusplus) && __cplusplus >= 201703L +#define __NOEXCEPT noexcept I think the change is useful for CUDA, too, but I'm OK keep

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert requested changes to this revision. jdoerfert added inline comments. This revision now requires changes to proceed. Comment at: lib/Headers/openmp_wrappers/__clang_openmp_math_declares.h:24 + #include + #include #endif jdoerfert wrote: > I ask this

[PATCH] D60283: [DebugInfo] Don't emit checksums when compiling a preprocessed CPP

2019-05-15 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea updated this revision to Diff 199659. aganea marked 3 inline comments as done. aganea added a comment. In D60283#1503256 , @probinson wrote: > Minor stuff. This solution is surprisingly simple, the main question being > (and I don't have an answer

[PATCH] D61909: Add Clang shared library with C++ exports

2019-05-15 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. In D61909#1503433 , @winksaville wrote: > IMHO "`BUILD_CLANG_DYLIB`" is needed. As you have it now libclang_shared.so > is always builds on UNIX systems, which I believe means that all linux > distros would have both increasing the

r360799 - [analyzer] Add a test for plugins using checker dependencies

2019-05-15 Thread Kristof Umann via cfe-commits
Author: szelethus Date: Wed May 15 12:47:26 2019 New Revision: 360799 URL: http://llvm.org/viewvc/llvm-project?rev=360799&view=rev Log: [analyzer] Add a test for plugins using checker dependencies Also, I moved the existing analyzer plugin to test/ as well, in order not to give the illusion that

[PATCH] D59464: [analyzer] Add an example plugin for checker dependency handling

2019-05-15 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL360799: [analyzer] Add a test for plugins using checker dependencies (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199662. gtbercea marked an inline comment as done. gtbercea added a comment. - Remove included headers. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61949/new/ https://reviews.llvm.org/D61949 Files: lib/Headers/__clang_c

[PATCH] D60907: [OpenMP] Add math functions support in OpenMP offloading

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea abandoned this revision. gtbercea marked an inline comment as done. gtbercea added a comment. Replaced by: D61399 Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60907/new/ https://reviews.llvm.org/D60907 __

[PATCH] D61959: [OpenMP][Bugfix] Move double and float versions of abs under c++ macro

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea created this revision. gtbercea added reviewers: tra, jdoerfert, hfinkel, ABataev, caomhin. Herald added subscribers: cfe-commits, guansong. Herald added a project: clang. This is a fix for the reported bug: 41861 abs functions need to be mo

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2019-05-15 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea abandoned this revision. gtbercea added a comment. Replaced by: D61399 Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D47849/new/ https://reviews.llvm.org/D47849 ___ cfe-commi

r360802 - [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary

2019-05-15 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Wed May 15 13:15:01 2019 New Revision: 360802 URL: http://llvm.org/viewvc/llvm-project?rev=360802&view=rev Log: [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary Any of these methods can be overridden, so we need to invoke these functions. Differential revisio

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-15 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added a comment. I'm waiting for a signoff from at least one front-end guy. I hope the mode setting that allows us to keep front ends from having to touch every use of the IRBuilder is something that works for clang. But I haven't heard anything from @r

[PATCH] D61957: [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary

2019-05-15 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360802: [CodeGenObjC] invoke objc_autorelease, objc_retain when necessary (authored by epilk, committed by ). Changed prior to commit: https://reviews.llvm.org/D61957?vs=199640&id=199666#toc Repository

r360804 - [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Gheorghe-Teodor Bercea via cfe-commits
Author: gbercea Date: Wed May 15 13:18:21 2019 New Revision: 360804 URL: http://llvm.org/viewvc/llvm-project?rev=360804&view=rev Log: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions Summary: In OpenMP device offloading we must ensure that unde C++ 17, the inclusi

r360805 - Revert "[analyzer] Add a test for plugins using checker dependencies"

2019-05-15 Thread Kristof Umann via cfe-commits
Author: szelethus Date: Wed May 15 13:19:51 2019 New Revision: 360805 URL: http://llvm.org/viewvc/llvm-project?rev=360805&view=rev Log: Revert "[analyzer] Add a test for plugins using checker dependencies" Buildbots don't seem to find the new plugin. Added: cfe/trunk/examples/analyzer-plugin

[PATCH] D61949: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions

2019-05-15 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360804: [OpenMP][bugfix] Fix issues with C++ 17 compilation when handling math functions (authored by gbercea, committed by ). Changed prior to commit: https://reviews.llvm.org/D61949?vs=199662&id=19966

r360806 - [c++20] For P1327R1: support dynamic_cast in constant expression

2019-05-15 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed May 15 13:22:21 2019 New Revision: 360806 URL: http://llvm.org/viewvc/llvm-project?rev=360806&view=rev Log: [c++20] For P1327R1: support dynamic_cast in constant expression evaluation. Modified: cfe/trunk/include/clang/Basic/DiagnosticASTKinds.td cfe/trunk/lib/AST

[PATCH] D59464: [analyzer] Add an example plugin for checker dependency handling

2019-05-15 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus reopened this revision. Szelethus added a comment. This revision is now accepted and ready to land. Ugh. Reverted in rC360805 . Buildbots don't seem to be able to find the new plugins. Repository: rL LLVM CHANGES SINCE LAST ACTION https://review

r360809 - [OpenMP][Bugfix] Move double and float versions of abs under c++ macro

2019-05-15 Thread Gheorghe-Teodor Bercea via cfe-commits
Author: gbercea Date: Wed May 15 13:28:23 2019 New Revision: 360809 URL: http://llvm.org/viewvc/llvm-project?rev=360809&view=rev Log: [OpenMP][Bugfix] Move double and float versions of abs under c++ macro Summary: This is a fix for the reported bug: [[ https://bugs.llvm.org/show_bug.cgi?id=41861

[PATCH] D61959: [OpenMP][Bugfix] Move double and float versions of abs under c++ macro

2019-05-15 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360809: [OpenMP][Bugfix] Move double and float versions of abs under c++ macro (authored by gbercea, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61959/new

r360810 - [clang-format] Fixed self assignment

2019-05-15 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed May 15 13:29:33 2019 New Revision: 360810 URL: http://llvm.org/viewvc/llvm-project?rev=360810&view=rev Log: [clang-format] Fixed self assignment Reviewers: MyDeveloperDay, RKSimon Reviewed By: MyDeveloperDay Subscribers: RKSimon, cfe-commits Tags: #clang Differentia

[PATCH] D61281: [clang-format] Fixed self assignment

2019-05-15 Thread Dávid Bolvanský via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360810: [clang-format] Fixed self assignment (authored by xbolva00, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61281/new/ https://reviews.llvm.org/D6128

[PATCH] D61333: [ASTImporter] Fix LLDB lookup in transparent ctx and with ext src

2019-05-15 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. I ran `check-lldb` and I hit one regression in `TestFormatters.py`, part of what I am seeing is as follows: AssertionError: False is not True : FileCheck'ing result of `expression --show-types -- *(new foo(47))` Error output: error: no matching constructor for init

[PATCH] D61963: [clang][Darwin] Refactor header search path logic into the driver

2019-05-15 Thread Louis Dionne via Phabricator via cfe-commits
ldionne created this revision. ldionne added reviewers: jfb, arphaman. Herald added subscribers: cfe-commits, jsji, dexonsmith, jkorous, christof, kbarton, javed.absar, nemanjai. Herald added a project: clang. This commit moves the logic for determining system, resource and C++ header search path

[PATCH] D61722: Prototype of RecoveryExpr. Here, it's emitted when overload resolution fails.

2019-05-15 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 199678. sammccall added a comment. Herald added a subscriber: arphaman. This should work for real now: handle types properly, make tests pass, add some tests. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61722/new/ https:

[PATCH] D61909: Add Clang shared library with C++ exports

2019-05-15 Thread Wink Saville via Phabricator via cfe-commits
winksaville added a comment. In D61909#1503483 , @beanz wrote: > In D61909#1503433 , @winksaville > wrote: > > > IMHO "`BUILD_CLANG_DYLIB`" is needed. As you have it now libclang_shared.so > > is always builds on

[PATCH] D61909: Add Clang shared library with C++ exports

2019-05-15 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. In D61909#1503642 , @winksaville wrote: > Sorry, maybe I didn't make myself clear. I understood you fine. I don't think you understand the guidance for building distributions of LLVM. Distributions only get libclang_shared if the

[PATCH] D59702: Unbreak the build of compiler-rt on Linux/mips64el

2019-05-15 Thread Simon Atanasyan via Phabricator via cfe-commits
atanasyan added a comment. I hope the rL360825 fixes the problem so this patch can be switch to the `abandoned` state. Repository: rCRT Compiler Runtime CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59702/new/ https://reviews.llvm.org/D59702 __

  1   2   >