[PATCH] D47108: [CodeGenCXX] Add -fforce-emit-vtables

2018-05-29 Thread Krzysztof Pszeniczny via Phabricator via cfe-commits
amharc accepted this revision. amharc added a comment. This revision is now accepted and ready to land. Looks good to me. Obviously, you should wait for someone more competent than me to accept it, too. Repository: rL LLVM https://reviews.llvm.org/D47108 __

r333396 - Testing commit access with whitespace change.

2018-05-29 Thread Rafael Stahl via cfe-commits
Author: r.stahl Date: Tue May 29 01:12:15 2018 New Revision: 96 URL: http://llvm.org/viewvc/llvm-project?rev=96&view=rev Log: Testing commit access with whitespace change. Modified: cfe/trunk/lib/AST/ASTImporter.cpp Modified: cfe/trunk/lib/AST/ASTImporter.cpp URL: http://llvm.org/v

[PATCH] D47459: [ASTImporter] Eliminated some unittest warnings.

2018-05-29 Thread Balázs Kéri via Phabricator via cfe-commits
balazske created this revision. Herald added subscribers: cfe-commits, martong. Herald added a reviewer: a.sidorin. Herald added a reviewer: a.sidorin. When running the ASTTests test, warnings produced by the compiler can be distracting when looking for test errors. A part of the warnings is remov

[PATCH] D47460: Treat files as volatile by default

2018-05-29 Thread Ivan Donchevskii via Phabricator via cfe-commits
yvvan created this revision. yvvan added reviewers: ilya-biryukov, nik, klimek, bkramer. Prevent accidental memory mapping for main file which sometimes happens through FileSystem::getBufferForFile https://reviews.llvm.org/D47460 Files: include/clang/Basic/VirtualFileSystem.h Index: includ

[PATCH] D47460: Treat files as volatile by default

2018-05-29 Thread Ivan Donchevskii via Phabricator via cfe-commits
yvvan added a comment. The precise path which leads here is yet unclear for me (it requires much more time to research) but changing this specific default value to true fixes main file from being memory mapped and therefore being blocked (on Windows) I assume it comes from FileManager::getBuffer

[PATCH] D46862: [libclang] Optionally add code completion results for arrow instead of dot

2018-05-29 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik requested changes to this revision. nik added a comment. This revision now requires changes to proceed. Generates build errors here: In file included from /d2/llvm/qtc/source/tools/clang/tools/c-index-test/c-index-test.c:4:0: /d2/llvm/qtc/source/tools/clang/include/clang-c/Index.h:1332:62: w

[PATCH] D47459: [ASTImporter] Eliminated some unittest warnings.

2018-05-29 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. Hello Balázs! Thank you for addressing this problem, it is really cool. However, it will be much better if we don't suppress warnings but fix them. Could you modify the tests

[PATCH] D47466: [clangd] Avoid inserting new #include when declaration is present in the main file.

2018-05-29 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added reviewers: sammccall, ilya-biryukov. Herald added subscribers: cfe-commits, jkorous, MaskRay, klimek. Also fix USR generation for classes in unit tests. The previous USR only works for class members, which happens to work when completing class name inside

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

2018-05-29 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a subscriber: hokein. sammccall added inline comments. Comment at: clangd/index/Index.h:158 unsigned References = 0; - + /// Whether or not this is symbol is meant to be used for the global + /// completion. ioeric wrote: > s/this is symbol/t

[PATCH] D47466: [clangd] Avoid inserting new #include when declaration is present in the main file.

2018-05-29 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added inline comments. This revision is now accepted and ready to land. Comment at: clangd/CodeComplete.cpp:249 + if (SemaResult->Kind == CodeCompletionResult::RK_Declaration) { +if (const auto *D = SemaResult->getDeclarati

[PATCH] D47471: [clangd] Minor cleanup

2018-05-29 Thread Kirill Bobyrev via Phabricator via cfe-commits
omtcyfz created this revision. omtcyfz added reviewers: ioeric, ilya-biryukov. omtcyfz added a project: clang-tools-extra. Herald added subscribers: jkorous, MaskRay. This patch silences few clang-tidy warnings, removes unwanted trailing whitespace and enforces coding guidelines. The functionali

[PATCH] D47471: [clangd] Minor cleanup

2018-05-29 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. lgtm. Nice! :) Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D47471 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[PATCH] D47471: [clangd] Minor cleanup

2018-05-29 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL333411: [clangd] Minor cleanup (authored by omtcyfz, committed by ). Herald added subscribers: llvm-commits, klimek. Changed prior to commit: https://reviews.llvm.org/D47471?vs=148847&id=148887#toc Rep

[clang-tools-extra] r333411 - [clangd] Minor cleanup

2018-05-29 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Tue May 29 04:50:51 2018 New Revision: 333411 URL: http://llvm.org/viewvc/llvm-project?rev=333411&view=rev Log: [clangd] Minor cleanup This patch silences few clang-tidy warnings, removes unwanted trailing whitespace and enforces coding guidelines. The functionality is not

[PATCH] D47471: [clangd] Minor cleanup

2018-05-29 Thread Kirill Bobyrev via Phabricator via cfe-commits
omtcyfz added a comment. Thank you, Eric! Repository: rL LLVM https://reviews.llvm.org/D47471 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47367: [ASTImporter] Add ms compatibility to tests which use the TestBase

2018-05-29 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a comment. > I think, it is overkill to test all possible combinations of the options, we > should come up with something better here. I agree with that. I think we need to test just import pairs {/*From*/no_option, /*To*/no_option}, {option_1, option1}, {option_2, option_2}, .

[PATCH] D45686: [Driver] Clean up tmp files when deleting Compilation objects

2018-05-29 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere accepted this revision. JDevlieghere added a comment. This revision is now accepted and ready to land. Thanks David, LGTM https://reviews.llvm.org/D45686 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-

[PATCH] D47459: [ASTImporter] Eliminated some unittest warnings.

2018-05-29 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Original idea was to not modify the test code to keep it as simple as possible. If you like it better I will change the test code. Repository: rC Clang https://reviews.llvm.org/D47459 ___ cfe-commits mailing list cfe-co

[PATCH] D44568: Fix emission of phony dependency targets when adding extra deps

2018-05-29 Thread David Stenberg via Phabricator via cfe-commits
dstenb added a comment. In https://reviews.llvm.org/D44568#1114188, @vsapsai wrote: > Looks good to me. Just watch the build bots in case some of them are strict > with warnings and require `(void)AddFilename(Filename)`. Yes, I'll keep an eye out for that. I'll submit this shortly. Thanks for

r333385 - [RISCV] Add -mrelax/-mno-relax flags to enable/disable RISCV linker relaxation

2018-05-29 Thread Shiva Chen via cfe-commits
Author: shiva Date: Mon May 28 17:44:15 2018 New Revision: 85 URL: http://llvm.org/viewvc/llvm-project?rev=85&view=rev Log: [RISCV] Add -mrelax/-mno-relax flags to enable/disable RISCV linker relaxation Differential Revision: https://reviews.llvm.org/D44888 Modified: cfe/trunk/includ

r333413 - Fix emission of phony dependency targets when adding extra deps

2018-05-29 Thread David Stenberg via cfe-commits
Author: dstenb Date: Tue May 29 06:07:58 2018 New Revision: 333413 URL: http://llvm.org/viewvc/llvm-project?rev=333413&view=rev Log: Fix emission of phony dependency targets when adding extra deps Summary: This commit fixes a bug where passing extra dependency entries (using -fdepfile-entry) woul

[PATCH] D44568: Fix emission of phony dependency targets when adding extra deps

2018-05-29 Thread David Stenberg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL333413: Fix emission of phony dependency targets when adding extra deps (authored by dstenb, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D4

[PATCH] D44568: Fix emission of phony dependency targets when adding extra deps

2018-05-29 Thread David Stenberg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333413: Fix emission of phony dependency targets when adding extra deps (authored by dstenb, committed by ). Repository: rL LLVM https://reviews.llvm.org/D44568 Files: lib/Frontend/DependencyFile.cp

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. erichkeane added reviewers: mikerice, echristo, aaron.ballman, gbiv. Herald added a reviewer: george.burgess.iv. Herald added a subscriber: mgrang. As documented here: https://software.intel.com/en-us/node/682969 and https://software.intel.com/en-us/node/523346.

[PATCH] D46944: [analyzer] Use sufficiently large types for index/size calculation.

2018-05-29 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a subscriber: NoQ. a.sidorin added a comment. There are some results for clang and gcc max value for x86 and x64. Source code: const unsigned long long SIZE_MAX = (unsigned long long)(unsigned long)(-1); const unsigned long long size = SIZE_MAX/2; char arr[size+1]; Compiler

[PATCH] D47476: Support __iso_volatile_load8 etc on aarch64-win32.

2018-05-29 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. Herald added a reviewer: javed.absar. Herald added subscribers: cfe-commits, kristof.beyls. These intrinsics are used by MSVC's header files on AArch64 Windows as well as AArch32, so we should support them for both targets. I've factored them out of CodeGenFunct

[PATCH] D45719: [clang-Format] Fix indentation of member call after block

2018-05-29 Thread Anders Karlsson via Phabricator via cfe-commits
ank added inline comments. Comment at: unittests/Format/FormatTest.cpp:4359 + "return 3;\n" + " }).as("");\n" + "}"); klimek wrote: > What would be interesting is tests that: > a) have another value after the closing

[PATCH] D47313: [ASTImporter] Corrected lookup at import of templated record decl

2018-05-29 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. LGTM too, thank you! Do you need someone to commit this for you? Repository: rC Clang https://reviews.llvm.org/D47313 ___ cfe-commits ma

[PATCH] D47367: [ASTImporter] Add ms compatibility to tests which use the TestBase

2018-05-29 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > I agree with that. I think we need to test just import pairs > {/*From*/no_option, /*To*/no_option}, {option_1, option1}, {option_2, > option_2}, ...{option_n, option_n}. This patch does exactly that with the parameterized tests. Each elements of the `DefaultTestValu

[PATCH] D46823: [analyzer] const init: handle non-explicit cases more accurately

2018-05-29 Thread Rafael Stahl via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333417: [analyzer] const init: handle non-explicit cases more accurately (authored by r.stahl, committed by ). Repository: rC Clang https://reviews.llvm.org/D46823 Files: lib/StaticAnalyzer/Core/Reg

r333417 - [analyzer] const init: handle non-explicit cases more accurately

2018-05-29 Thread Rafael Stahl via cfe-commits
Author: r.stahl Date: Tue May 29 07:14:22 2018 New Revision: 333417 URL: http://llvm.org/viewvc/llvm-project?rev=333417&view=rev Log: [analyzer] const init: handle non-explicit cases more accurately Summary: If the access is out of bounds, return UndefinedVal. If it is missing an explicit init,

[PATCH] D20118: Add support for injected class names and constructor initializers in C++

2018-05-29 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin abandoned this revision. a.sidorin added a comment. This revision seems to be already committed in https://reviews.llvm.org/rC269693, without Differential Revision set. Repository: rL LLVM https://reviews.llvm.org/D20118 ___ cfe-commit

[PATCH] D47367: [ASTImporter] Add ms compatibility to tests which use the TestBase

2018-05-29 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a comment. I meant that we can use this approach for testImport() too. Repository: rC Clang https://reviews.llvm.org/D47367 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe

r333423 - add test for r332053

2018-05-29 Thread Nico Weber via cfe-commits
Author: nico Date: Tue May 29 07:48:30 2018 New Revision: 333423 URL: http://llvm.org/viewvc/llvm-project?rev=333423&view=rev Log: add test for r332053 Modified: cfe/trunk/test/Driver/cl-options.c Modified: cfe/trunk/test/Driver/cl-options.c URL: http://llvm.org/viewvc/llvm-project/cfe/trun

Re: r332053 - [clang-cl] Make -f[no-]coverage-mapping available

2018-05-29 Thread Nico Weber via cfe-commits
(Added a test for this in r333423) On Thu, May 10, 2018 at 6:24 PM, Reid Kleckner via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: rnk > Date: Thu May 10 15:24:00 2018 > New Revision: 332053 > > URL: http://llvm.org/viewvc/llvm-project?rev=332053&view=rev > Log: > [clang-cl] Make -f

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

2018-05-29 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Impl looks good. Is there a way we can reasonably test this? (specifically that we don't just store all the ASTs forever) Comment at: clangd/ClangdUnit.h:143 +std::shared_ptr +buildPreamble(PathRef FileName, CompilerInvocation &CI, + std

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Nico Weber via Phabricator via cfe-commits
thakis created this revision. thakis added a reviewer: rnk. -no-canonical-prefixes is a weird flag: In gcc, it controls whether realpath() is called on the path of the driver binary. It's needed to support some usecases where gcc is symlinked to, see https://gcc.gnu.org/ml/gcc/2011-01/msg00429.

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Takuto Ikuta via Phabricator via cfe-commits
takuto.ikuta added a comment. Thank you for quick supporting, but this is not sufficient for clang-cl on windows. llvm::InitLLVM calls windows::GetCommandLineArguments, and argv0 is changed to absolute path. https://github.com/llvm-project/llvm-project-20170507/blob/7c81daae49eaf7f9681457b46c56

[PATCH] D47190: [Driver] Add -ivfsoverlay-lib option to load VFS from shared library

2018-05-29 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere added a comment. I don't know much about the VFS so I only did a superficial review. Comment at: include/clang/Lex/HeaderSearchOptions.h:176 + /// \brief The set of libraries with user-provided virtual filesystem. + std::vector VFSOverlayLibs;

[PATCH] D47313: [ASTImporter] Corrected lookup at import of templated record decl

2018-05-29 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Yes, I have no commit permissions. Repository: rC Clang https://reviews.llvm.org/D47313 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Samuel Antao via Phabricator via cfe-commits
sfantao added a comment. @gtbercea, thanks for the patch. > INTEROPERABILITY WITH OTHER COMPILERS: These bundled object files can end up > being passed between Clang and other compilers which may lead to > incompatibilities: passing a bundled file from Clang to another compiler > would lead to

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. I did test this locally before sending it out, and the -resource-dir arg passed to cc1 is relative with this patch: $ bin/clang-cl -no-canonical-prefixes -c test.cc -### clang version 7.0.0 Target: x86_64-pc-windows-msvc Thread model: posix InstalledDir: bin

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

2018-05-29 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 148918. leonardchan marked 4 inline comments as done. Repository: rC Clang https://reviews.llvm.org/D46911 Files: include/clang/AST/ASTContext.h include/clang/AST/BuiltinTypes.def include/clang/AST/Type.h include/clang/Basic/DiagnosticSemaKinds

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

2018-05-29 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added inline comments. Comment at: lib/Sema/SemaType.cpp:1430 } else { - switch (DS.getTypeSpecWidth()) { -case DeclSpec::TSW_short: - Result = Context.UnsignedShortAccumTy; - break; -case DeclSpec::TSW_unspecified: -

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-29 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. Hi all, I think I've addressed all comments on this patch and will be committing tomorrow morning unless anyone has any more comments they'd like to bring up. Repository: rC Clang https://reviews.llvm.org/D46084 ___

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Samuel Antao via Phabricator via cfe-commits
sfantao added a comment. Just to clarify one thing in my last comment: When I say that we didn't aim at having clang compatible with other compilers, I mean the OpenMP offloading descriptors, where all the variables and offloading entry points are. Of course we want to allow the resulting binar

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: test/Driver/openmp-offload.c:497 // RUN: %clang -### -fopenmp=libomp -o %t.out -lsomelib -target powerpc64le-linux -fopenmp-targets=powerpc64le-ibm-linux-gnu,x86_64-pc-linux-gnu %t.i -no-canonical-prefixes 2>&1 \ // RUN: | Fil

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: test/Driver/openmp-offload.c:497 // RUN: %clang -### -fopenmp=libomp -o %t.out -lsomelib -target powerpc64le-linux -fopenmp-targets=powerpc64le-ibm-linux-gnu,x86_64-pc-linux-gnu %t.i -no-canonical-prefixes 2>&1 \ // RUN: | Fil

[PATCH] D44226: [clangd] Add -log-lsp-to-stderr option

2018-05-29 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Herald added a subscriber: jkorous. Hey Simon, Sorry this patch got stalled. I hope you're still interested! I agree there's space for providing some high-signal information about error conditions to power users/potential developers/administrators, even if it's not "p

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Guansong Zhang via Phabricator via cfe-commits
guansong added a comment. I am not quite familiar with Clang driver set up, I will add Greg for more comments. But I have hacked one the latest YKT tree to support simple AMDGCN path the same way as NVPTX. The last patch is here https://github.com/ROCm-Developer-Tools/hcc2-clang/commit/8c1cce0d

[libcxx] r333435 - Mark __clear_and_shrink() as noexcept. This prevents the generation of a catch block and call to terminate in string's move assignment. Thanks to Howard for the 'catch'.

2018-05-29 Thread Marshall Clow via cfe-commits
Author: marshall Date: Tue May 29 10:04:37 2018 New Revision: 333435 URL: http://llvm.org/viewvc/llvm-project?rev=333435&view=rev Log: Mark __clear_and_shrink() as noexcept. This prevents the generation of a catch block and call to terminate in string's move assignment. Thanks to Howard for the

[PATCH] D47451: [analyzer] Remove the redundant check about same state transition in `ArrayBoundCheckerV2.cpp`.

2018-05-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Thx! Repository: rC Clang https://reviews.llvm.org/D47451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mail

[PATCH] D41976: Low-hanging fruit optimization in string::__move_assign().

2018-05-29 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. Howard just pointed out to me that `__clear_and_shrink` should be noexcept - otherwise we get the generation of an exception table and a call to `terminate` in string's move assignment operator. Fixed in revision 333435. Repository: rCXX libc++ https://reviews.

[PATCH] D47444: [X86] Lowering FMA intrinsics to native IR (Clang part)

2018-05-29 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM Comment at: lib/CodeGen/CGBuiltin.cpp:8416 +static Value *EmitX86FMAExpr(CodeGenFunction &CGF, ArrayRef Ops, + unsigned BuiltinID) { + -

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-29 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added inline comments. Comment at: test/Analysis/z3-crosscheck.c:2 +// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config crosscheck-with-z3=true -verify %s +// REQUIRES: z3 +// expected-no-diagnostics

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:536 + } } sfantao wrote: > What prevents all this from being done in the bundler? If I understand it > correctly, if the bundler implements this wrapping all the checks for > librari

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In https://reviews.llvm.org/D47394#1114848, @sfantao wrote: > Just to clarify one thing in my last comment: > > When I say that we didn't aim at having clang compatible with other > compilers, I mean the OpenMP offloading descriptors, where all the variables > and offl

[PATCH] D35110: [Analyzer] Constraint Manager Negates Difference

2018-05-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:191 +} +if (from.isMinSignedValue()) { + F.add(newRanges, Range(BV.getMinValue(from), BV.getMinValue(from))); We'll also need to merge the two adjacent segments

[PATCH] D35110: [Analyzer] Constraint Manager Negates Difference

2018-05-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:192 +if (from.isMinSignedValue()) { + F.add(newRanges, Range(BV.getMinValue(from), BV.getMinValue(from))); +} NoQ wrote: > Return value of `add` seems to be acc

r333446 - [X86] Tag some 128/256 load/store instructions as requiring avx512vl instead of avx512f.

2018-05-29 Thread Craig Topper via cfe-commits
Author: ctopper Date: Tue May 29 11:23:22 2018 New Revision: 333446 URL: http://llvm.org/viewvc/llvm-project?rev=333446&view=rev Log: [X86] Tag some 128/256 load/store instructions as requiring avx512vl instead of avx512f. Modified: cfe/trunk/include/clang/Basic/BuiltinsX86.def Modified: cf

r333447 - [CodeGen][Darwin] Set the calling-convention of thread-local variable

2018-05-29 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Tue May 29 11:28:49 2018 New Revision: 333447 URL: http://llvm.org/viewvc/llvm-project?rev=333447&view=rev Log: [CodeGen][Darwin] Set the calling-convention of thread-local variable initialization functions to 'cxx_fast_tlscc'. This fixes a bug where instructions calling in

[PATCH] D47354: [CodeGen][Darwin] Set the calling-convention of a thread-local variable initialization function to fix calling-convention mismatch

2018-05-29 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL333447: [CodeGen][Darwin] Set the calling-convention of thread-local variable (authored by ahatanak, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llv

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. "Interoperability with other compilers" is probably a statement that's a bit too strong. At best it's kind of compatible with CUDA tools and I don't think it's feasible for other compilers. I.e. it will be useless for AMD GPUs and whatever compiler they use. In general it

[PATCH] D47450: [ASTImporter] Use InjectedClassNameType at import of templated record.

2018-05-29 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. Hello, Balázs, You can find my comments inline. Comment at: lib/AST/ASTImporter.cpp:2131 D2CXX->setDescribedClassTemplate(ToDescribed); +if

[PATCH] D46476: [HIP] Add action builder for HIP

2018-05-29 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. One nit. LGTM otherwise. Comment at: test/Driver/cuda-phases.cu:16 +// RUN: | FileCheck -check-prefixes=BIN,BIN_NV %s +// RUN: %clang -x hip -target powerpc64le-ibm-linux-gnu -ccc-

[PATCH] D47394: [OpenMP][Clang][NVPTX] Replace bundling with partial linking for the OpenMP NVPTX device offloading toolchain

2018-05-29 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In https://reviews.llvm.org/D47394#1115086, @tra wrote: > On one hand I can see how being able to treat GPU-side binaries as any other > host files is convenient. On the other hand, this convenience comes with the > price of targeting only NVPTX. This seems contrary to

[PATCH] D44826: Add -Wunused-using, a warning that finds unused using declarations.

2018-05-29 Thread Carlos Alberto Enciso via Phabricator via cfe-commits
CarlosAlbertoEnciso added inline comments. Comment at: include/clang/Basic/DiagnosticGroups.td:828-829 // -Wunused-local-typedefs = -Wunused-local-typedef +def : DiagGroup<"unused-usings", [UnusedUsing]>; +// -Wunused-usings = -Wunused-using ---

[PATCH] D46476: [HIP] Add action builder for HIP

2018-05-29 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: test/Driver/cuda-phases.cu:16 +// RUN: | FileCheck -check-prefixes=BIN,BIN_NV %s +// RUN: %clang -x hip -target powerpc64le-ibm-linux-gnu -ccc-print-phases --cuda-gpu-arch=gfx803 %s 2>&1 \ +// RUN

[PATCH] D47476: Support __iso_volatile_load8 etc on aarch64-win32.

2018-05-29 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo accepted this revision. mstorsjo added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rC Clang https://reviews.llvm.org/D47476 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.ll

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-29 Thread Mikhail Ramalho via Phabricator via cfe-commits
mikhail.ramalho updated this revision to Diff 148969. mikhail.ramalho marked 6 inline comments as done. mikhail.ramalho added a comment. 1. Moved FalsePositiveRefutationBRVisitor::Profile definition to BugReporterVisitor.cpp 2. Update test cases two run twice, with and without the crosscheck 3. R

Re: r333141 - Use zeroinitializer for (trailing zero portion of) large array initializers

2018-05-29 Thread Richard Smith via cfe-commits
On 28 May 2018 at 15:34, David Blaikie via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Probably nice to mention in the commit message what the fix was (& > if/where there was there a test added for it?) so readers don't have to try > to eyeball diff this commit against the otherone. > Fair

[PATCH] D44480: [Sema] Don't skip function bodies with 'auto' without trailing return type

2018-05-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. This revision is now accepted and ready to land. Comment at: test/CodeCompletion/skip-auto-funcs.cpp:9 + if (x = 10) {} + // Check that this function is skipped. + // CHECK: 8:9: warning: using the result of an assig

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-29 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added inline comments. Comment at: lib/StaticAnalyzer/Core/BugReporter.cpp:3153 +if (getAnalyzerOptions().shouldCrosscheckWithZ3()) + R->addVisitor(llvm::make_unique()); + Unless I'm mistaken, visitors are run in the order they are being

Re: [libcxx] r333325 - Add nonnull; use it for atomics

2018-05-29 Thread JF Bastien via cfe-commits
Hi Marshall, I’ve been thinking about this, and I propose we proceed the following way: Add a new warning to clang, -Wnonnull-attribute (modulo name bikeshed), which is part of the nonnull group and on by default. That warning specifically controls warnings generated by usage of the nonnull att

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-29 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added inline comments. Comment at: lib/Sema/SemaDecl.cpp:9440 + // Sort order doesn't matter, it just needs to be consistent. + std::sort(NewParsed.Features.begin(), NewParsed.Features.end()); Please use llvm::sort instead of std::sort. See https://ll

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 2 inline comments as done. erichkeane added a comment. Woops, looks like I lost those in the rebase. Thanks for catching them! Repository: rC Clang https://reviews.llvm.org/D47474 ___ cfe-commits mailing list cfe-commits@lists.

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 148977. https://reviews.llvm.org/D47474 Files: include/clang/AST/Decl.h include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.td include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td include/clang/Basic/TargetInf

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Takuto Ikuta via Phabricator via cfe-commits
takuto.ikuta added a comment. On windows, argv0 is changed to absolute path before we call GetExecutablePath. That makes resource-dir absolute. I need clang-cl on windows has relative --resource-dir. See around heres. https://github.com/llvm-project/llvm-project-20170507/blob/83b39c10b1d7a9189b7e

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-29 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: include/clang/Basic/X86Target.def:295 +CPU_SPECIFIC("pentium_iii", 'H', + (1ULL << FEATURE_CMOV | 1ULL << FEATURE_MMX | 1ULL << FEATURE_SSE)) +CPU_SPECIFIC("pentium_iii_no_xmm_regs", 'H', Could we just

[PATCH] D47290: [Sema] -Wformat-pedantic only for NSInteger/NSUInteger %zu/%zi on Darwin

2018-05-29 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In https://reviews.llvm.org/D47290#1113422, @aaron.ballman wrote: > In https://reviews.llvm.org/D47290#1113412, @jfb wrote: > > > In https://reviews.llvm.org/D47290#1113365, @aaron.ballman wrote: > > > > > This is relaxing `-Wformat` and making users instead write > > > `-Wf

[PATCH] D46485: Add python tool to dump and construct header maps

2018-05-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D46485 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D45012: [Modules] Skip adding unused module maps to the dependency file

2018-05-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping Repository: rC Clang https://reviews.llvm.org/D45012 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47499: [analyzer] Annotate program state update methods with LLVM_NODISCARD.

2018-05-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs, baloghadamsoftware. Herald added a subscriber: cfe-commits. A follow-up to https://reviews.llvm.org/D47496. This would warn the developer on the very common bug that consists in w

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Consistency would be nice, but at the same time, I don't see a good metric > for when we'd know it's time to switch it to being on by default. I'm worried > that it'll remain off by default forever simply because no one thinks to go > turn it on (because it's silent b

[libcxx] r333467 - Fix embarrasing typo in uncaught_exceptions. Update tests to really test this. Thanks to Peter Klotz for calling my attention to this.

2018-05-29 Thread Marshall Clow via cfe-commits
Author: marshall Date: Tue May 29 15:25:42 2018 New Revision: 333467 URL: http://llvm.org/viewvc/llvm-project?rev=333467&view=rev Log: Fix embarrasing typo in uncaught_exceptions. Update tests to really test this. Thanks to Peter Klotz for calling my attention to this. Modified: libcxx/trunk

[PATCH] D45012: [Modules] Skip adding unused module maps to the dependency file

2018-05-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. This feature seems reasonable to me. Comment at: lib/Frontend/DependencyFile.cpp:206-223 class DFGMMCallback : public ModuleMapCallbacks { DFGImpl &Parent; public: DFGMMCallback(DFGImpl &Parent) : Parent(Parent) {} void moduleMapFileRead(Sourc

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-29 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: lib/Lex/HeaderSearch.cpp:753-754 + IncluderAndDir.second->getName())) +Diags.Report(IncludeLoc, + diag::warn_quoted_include_in_framework_header) +<< Filename; --

[PATCH] D47357: [Driver] Rename DefaultTargetTriple to TargetTriple

2018-05-29 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333468: [Driver] Rename DefaultTargetTriple to TargetTriple (authored by phosek, committed by ). Changed prior to commit: https://reviews.llvm.org/D47357?vs=148539&id=148996#toc Repository: rC Clang

r333468 - [Driver] Rename DefaultTargetTriple to TargetTriple

2018-05-29 Thread Petr Hosek via cfe-commits
Author: phosek Date: Tue May 29 15:35:39 2018 New Revision: 333468 URL: http://llvm.org/viewvc/llvm-project?rev=333468&view=rev Log: [Driver] Rename DefaultTargetTriple to TargetTriple While this value is initialized with the DefaultTargetTriple, it can be later overriden using the -target flag s

r333471 - Check pointer null-ness before dereferencing it.

2018-05-29 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Tue May 29 15:43:00 2018 New Revision: 333471 URL: http://llvm.org/viewvc/llvm-project?rev=333471&view=rev Log: Check pointer null-ness before dereferencing it. -Warc-repeated-use-of-weak may trigger a segmentation fault when the Decl being checked is outside of a function sc

Re: [PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Nico Weber via cfe-commits
But GetExecutablePath isn't called if -no-canonical-prefixes is passed, is it? (See the first link I pasted above) On Tue, May 29, 2018, 5:28 PM Takuto Ikuta via Phabricator via cfe-commits < cfe-commits@lists.llvm.org> wrote: > takuto.ikuta added a comment. > > On windows, argv0 is changed to ab

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-29 Thread Nico Weber via Phabricator via cfe-commits
thakis added a subscriber: rnk. thakis added a comment. But GetExecutablePath isn't called if -no-canonical-prefixes is passed, is it? (See the first link I pasted above) https://reviews.llvm.org/D47480 ___ cfe-commits mailing list cfe-commits@lists

[PATCH] D46971: [DWARF] Get RA from RA register even if it appears unused

2018-05-29 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added a comment. It would be nice if we had a test case added for this, but, seems correct to me. Comment at: src/DwarfInstructions.hpp:195 } +else if (i == (int)cieInfo.returnAddressRegister) + returnAddress = registers.getRegister(i); --

[PATCH] D46791: Make -gsplit-dwarf generally available

2018-05-29 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: test/Driver/split-debug.c:23 +// Macosx // RUN: %clang -target x86_64-macosx -gsplit-dwarf -c -### %s 2> %t NIT: macOS or the legacy spelling of Mac OS X. https://reviews.llvm.org/D46791

[PATCH] D47503: Sema: Add a warning for member pointers with incomplete base types.

2018-05-29 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc created this revision. pcc added reviewers: rnk, rsmith. Codebases that need to be compatible with the Microsoft ABI can enable this warning to avoid issues caused by the lack of a fixed ABI for incomplete member pointers. https://reviews.llvm.org/D47503 Files: clang/include/clang/Basic/D

[PATCH] D47503: Sema: Add a warning for member pointers with incomplete base types.

2018-05-29 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc updated this revision to Diff 149000. pcc added a comment. - Add some negative tests https://reviews.llvm.org/D47503 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaType.cpp clang/test/SemaCXX/warn-incomplete-member-pointers.cpp Index: clang/test/SemaCXX/w

[PATCH] D47503: Sema: Add a warning for member pointers with incomplete base types.

2018-05-29 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc updated this revision to Diff 149001. pcc added a comment. - One more negative test https://reviews.llvm.org/D47503 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaType.cpp clang/test/SemaCXX/warn-incomplete-member-pointers.cpp Index: clang/test/SemaCXX/wa

[PATCH] D47503: Sema: Add a warning for member pointers with incomplete base types.

2018-05-29 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Should we do this in exactly the places we would lock in an inheritance model in the MS ABI, i.e. when the member pointer type is required to be complete? I think we could take this code: bool Sema::RequireCompleteTypeImpl(SourceLocation Loc, QualType T,

[libcxx] r333479 - Mark deduction guide tests as failing on apple-clang-9

2018-05-29 Thread JF Bastien via cfe-commits
Author: jfb Date: Tue May 29 16:28:04 2018 New Revision: 333479 URL: http://llvm.org/viewvc/llvm-project?rev=333479&view=rev Log: Mark deduction guide tests as failing on apple-clang-9 As discussed here: http://lists.llvm.org/pipermail/cfe-dev/2018-May/058116.html The tests fail on clang-5, as we

[PATCH] D47503: Sema: Add a warning for member pointers with incomplete base types.

2018-05-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In https://reviews.llvm.org/D47503#1115505, @rnk wrote: > [...] And rewrite the side-effecting isCompleteType call to use > RequireCompleteType with the warning diagnostic. We should keep the `isCompleteType` call and diagnose `if (!isCompleteType(...))`. `RequireCompl

  1   2   >