[PATCH] D46050: [Frontend] Avoid running plugins during code completion parse

2018-05-07 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik marked an inline comment as done. nik added inline comments. Comment at: test/Frontend/plugins.c:8 +// RUN: c-index-test -code-completion-at=%s:6:1 -load %llvmshlibdir/PrintFunctionNames%pluginext -add-plugin print-fns %s | FileCheck -check-prefix=CHECK-COMPLETION-WITHOUT-P

[PATCH] D46050: [Frontend] Avoid running plugins during code completion parse

2018-05-07 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik updated this revision to Diff 145430. nik added a comment. Moved the test to "Index". https://reviews.llvm.org/D46050 Files: lib/Frontend/FrontendAction.cpp test/Index/complete-and-plugins.c Index: test/Index/complete-and-plugins.c =

[PATCH] D40481: [libclang] Fix cursors for arguments of Subscript and Call operators

2018-05-07 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik added a comment. Ping. https://reviews.llvm.org/D40481 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D46504: [clang-tidy] Profile is a per-AST (per-TU) data.

2018-05-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:181 std::unique_ptr OptionsProvider) -: DiagEngine(nullptr), OptionsProvider(std::move(OptionsProvider)), - Profile(nullptr) { +: DiagEngine(nullptr), OptionsProvider(std::m

[PATCH] D46176: Add SourceManagerForFile helper which sets up SourceManager and dependencies for a single file with code snippet

2018-05-07 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: include/clang/Basic/SourceManager.h:1819 +/// SourceManager and necessary depdencies (e.g. VFS, FileManager) for a single +/// file. +class SourceManage

[PATCH] D44435: CUDA ctor/dtor Module-Unique Symbol Name

2018-05-07 Thread Simeon Ehrig via Phabricator via cfe-commits
SimeonEhrig added a comment. In https://reviews.llvm.org/D44435#1088019, @tra wrote: > Perhaps we should take a step back and consider whether this is the right > approach to solve your problem. > > If I understand it correctly, the real issue is that you repeatedly recompile > the same module

?????? If I want to disable certain attributes, such as"swiftcall",isthereany way to do it now?

2018-05-07 Thread ???? via cfe-commits
hi, Aaron I may found a useful example. For example, I tested the alias attribute on my own Apple laptop (Target: x86_64-apple-darwin17.5.0). First, I use __has_attribute to test that the alias is usable or not. The test code is as follows: #include void print() { #if __has_attribute(

[PATCH] D46450: [Driver] Add mips_Features_Group to Options to improve documentation sorting

2018-05-07 Thread Vince Del Vecchio via Phabricator via cfe-commits
vdelvecc added a comment. In https://reviews.llvm.org/D46450#1089105, @atanasyan wrote: > LGTM > > Do you have commit access? Nope. Would you commit it please? Thanks much! Repository: rC Clang https://reviews.llvm.org/D46450 ___ cfe-commits

[PATCH] D46519: [clang-format] Respect BreakBeforeClosingBrace while calculating length

2018-05-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch makes `getLengthToMatchingParen` respect the `BreakBeforeClosingBrace` ParenState for matching scope closers. In order to distinguish between paren states introduced by real vs. fake parens, I've added the

[PATCH] D46241: [CodeGen] Recognize more cases of zero initialization

2018-05-07 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 145445. sepavloff marked an inline comment as done. sepavloff added a comment. Avoid redundant initializer calculation Repository: rC Clang https://reviews.llvm.org/D46241 Files: include/clang/AST/Expr.h lib/AST/ExprConstant.cpp lib/CodeGen/CGExp

[PATCH] D46520: [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo created this revision. mstorsjo added reviewers: rnk, hans, thakis. Don't use the GNU extension form of line markers in MSVC mode. Repository: rC Clang https://reviews.llvm.org/D46520 Files: lib/Driver/ToolChains/Clang.cpp test/Driver/cl-options.c Index: test/Driver/cl

[PATCH] D46520: [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Seems reasonable to me (but please update the comment before landing). Comment at: lib/Driver/ToolChains/Clang.cpp:4218 // -fno-use-line-directives is default. if (Args.h

r331630 - [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType, DependentScopeDeclRefExpr

2018-05-07 Thread Peter Szecsi via cfe-commits
Author: szepet Date: Mon May 7 05:08:27 2018 New Revision: 331630 URL: http://llvm.org/viewvc/llvm-project?rev=331630&view=rev Log: [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType, DependentScopeDeclRefExpr The visit callback implementations for the 3 C++ AST Node added

[PATCH] D38845: [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType, DependentScopeDeclRefExpr

2018-05-07 Thread Peter Szecsi via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC331630: [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType… (authored by szepet, committed by ). Changed prior to commit: https://reviews.llvm.org/D38845?vs=145159&id=145447#toc Re

Re: If I want to disable certain attributes, such as"swiftcall", isthereany way to do it now?

2018-05-07 Thread Aaron Ballman via cfe-commits
On Mon, May 7, 2018 at 5:48 AM, 朴素 <772847...@qq.com> wrote: > hi, Aaron > > > I may found a useful example. For example, I tested the alias attribute on > my own Apple laptop (Target: x86_64-apple-darwin17.5.0). First, I use > __has_attribute to test that the alias is usable or not. The test cod

[PATCH] D46241: [CodeGen] Recognize more cases of zero initialization

2018-05-07 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added inline comments. Comment at: lib/CodeGen/CGExprConstant.cpp:1413 + } else if (!Init->isEvaluatable(CE.CGM.getContext())) { +return false; + } else if (InitTy->hasPointerRepresentation()) { rsmith wrote: > sepavloff wrote: > > rjmccall wrote:

[PATCH] D46522: [clang] cmake: resolve symlinks in ClangConfig.cmake

2018-05-07 Thread Peter Wu via Phabricator via cfe-commits
Lekensteyn created this revision. Lekensteyn added a reviewer: sylvestre.ledru. Herald added subscribers: cfe-commits, mgorny. Ensure that symlinks such as /usr/lib/cmake/clang-X.Y (pointing to /usr/lib/llvm-X.Y/lib/cmake/llvm) are resolved. This ensures that CLANG_INSTALL_PREFIX ends up to be /us

[PATCH] D33537: [clang-tidy] Exception Escape Checker

2018-05-07 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 145452. baloghadamsoftware added a comment. Updated according to the comments. https://reviews.llvm.org/D33537 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/ExceptionEscapeCheck.cpp

[PATCH] D33537: [clang-tidy] Exception Escape Checker

2018-05-07 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware marked 10 inline comments as done. baloghadamsoftware added inline comments. Comment at: test/clang-tidy/bugprone-exception-escape.cpp:178 +void indirect_implicit() noexcept { + // CHECK-MESSAGES: :[[@LINE-1]]:6: warning: function 'indirect_implicit' throws +

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

2018-05-07 Thread Clement Courbet via Phabricator via cfe-commits
courbet added a comment. @aaron.ballman Ping 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] D33537: [clang-tidy] Exception Escape Checker

2018-05-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: test/clang-tidy/bugprone-exception-escape.cpp:178 +void indirect_implicit() noexcept { + // CHECK-MESSAGES: :[[@LINE-1]]:6: warning: function 'indirect_implicit' throws + implicit_int_thrower(); baloghadamsoftware

[PATCH] D46524: [clangd] Extract scoring/ranking logic, and shave yaks.

2018-05-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, mgrang, jkorous, MaskRay, ioeric, mgorny, klimek. Code completion scoring was embedded in CodeComplete.cpp, which is bad: - awkward to test. The mechanisms (extracting info from ind

[PATCH] D44684: [mips] Improve handling of -fno-[pic/PIC] option

2018-05-07 Thread Aleksandar Beserminji via Phabricator via cfe-commits
abeserminji updated this revision to Diff 145460. abeserminji marked 4 inline comments as done. abeserminji added a comment. Comments resolved. https://reviews.llvm.org/D44684 Files: include/clang/Basic/DiagnosticDriverKinds.td lib/Driver/ToolChains/Arch/Mips.cpp lib/Driver/ToolChains/Com

[PATCH] D44684: [mips] Improve handling of -fno-[pic/PIC] option

2018-05-07 Thread Aleksandar Beserminji via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL331636: [mips] Improve handling of -fno-[pic/PIC] option (authored by abeserminji, committed by ). Changed prior to commit: https://reviews.llvm.org/D44684?vs=145460&id=145462#toc Repository: rL LLVM

[libcxx] r331638 - Update for Rapperswil

2018-05-07 Thread Marshall Clow via cfe-commits
Author: marshall Date: Mon May 7 07:21:52 2018 New Revision: 331638 URL: http://llvm.org/viewvc/llvm-project?rev=331638&view=rev Log: Update for Rapperswil Modified: libcxx/trunk/www/upcoming_meeting.html Modified: libcxx/trunk/www/upcoming_meeting.html URL: http://llvm.org/viewvc/llvm-pro

r331636 - [mips] Improve handling of -fno-[pic/PIC] option

2018-05-07 Thread Aleksandar Beserminji via cfe-commits
Author: abeserminji Date: Mon May 7 07:19:54 2018 New Revision: 331636 URL: http://llvm.org/viewvc/llvm-project?rev=331636&view=rev Log: [mips] Improve handling of -fno-[pic/PIC] option In order to disable PIC and to match GCC behaviour, -mno-abicalls option is neccessary. When -fno-[pic/PIC] is

r331639 - Revert "[mips] Improve handling of -fno-[pic/PIC] option"

2018-05-07 Thread Aleksandar Beserminji via cfe-commits
Author: abeserminji Date: Mon May 7 07:28:42 2018 New Revision: 331639 URL: http://llvm.org/viewvc/llvm-project?rev=331639&view=rev Log: Revert "[mips] Improve handling of -fno-[pic/PIC] option" This reverts commit r331636. Forgot to add the test case. Modified: cfe/trunk/include/clang/Bas

[PATCH] D46520: [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: lib/Driver/ToolChains/Clang.cpp:4218 // -fno-use-line-directives is default. if (Args.hasFlag(options::OPT_fuse_line_directives, hans wrote: > The comment needs an update I think. Thanks, will change into "-fno-

[PATCH] D46524: [clangd] Extract scoring/ranking logic, and shave yaks.

2018-05-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. The change makes both testing and scoring code better. Even though those are largely independent changes, perfectly happy to review them together. I mostly have NITs here, overall the changes LG. Comment at: clangd/CodeComplete.cpp:36 +#define

r331642 - [OPENMP, NVPTX] Added support for L2 parallelism.

2018-05-07 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Mon May 7 07:50:05 2018 New Revision: 331642 URL: http://llvm.org/viewvc/llvm-project?rev=331642&view=rev Log: [OPENMP, NVPTX] Added support for L2 parallelism. Added initial codegen for level 2, 3 etc. parallelism. Currently, all the second, the third etc. parallel regions

r331640 - [mips] Improve handling of -fno-[pic/PIC] option

2018-05-07 Thread Aleksandar Beserminji via cfe-commits
Author: abeserminji Date: Mon May 7 07:30:49 2018 New Revision: 331640 URL: http://llvm.org/viewvc/llvm-project?rev=331640&view=rev Log: [mips] Improve handling of -fno-[pic/PIC] option In order to disable PIC and to match GCC behaviour, -mno-abicalls option is neccessary. When -fno-[pic/PIC] is

[PATCH] D46497: [clangd] Populate #include insertions as additional edits in completion items.

2018-05-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. I'm concerned about the scope of this patch - it does too many things and touches too many files for me to feel comfortable that I understand it well enough to review. Is it possible to split it up? (You mention 6 distinct things in the description). Have tried to fo

[PATCH] D46501: [OpenCL] Guard all half float usage based on cl_khr_fp16 extension

2018-05-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. Only halfn type requires cl_khr_fp16. These functions do not use halfn type, therefore cl_khr_fp16 is not required. Repository: rC Clang https://reviews.llvm.org/D46501 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[PATCH] D46471: [HIP] Add hip offload kind

2018-05-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: lib/Driver/Compilation.cpp:201 + // not compiled again if there are already failures. It is OK to abort the + // CUDA pipeline on errors. + if (A->isOffloading(Action::OFK_Cuda) || A->isOffloadi

[PATCH] D46471: [HIP] Add hip offload kind

2018-05-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 145472. yaxunl marked 2 inline comments as done. yaxunl added a comment. Updated comments. https://reviews.llvm.org/D46471 Files: include/clang/Driver/Action.h lib/Driver/Action.cpp lib/Driver/Compilation.cpp lib/Driver/ToolChains/Clang.cpp Index: l

[PATCH] D46472: [HIP] Support offloading by linkscript

2018-05-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: lib/CodeGen/CGCUDANV.cpp:317 + if (GpuBinaryFileName.empty() && !IsHIP) return nullptr; rjmccall wrote: > Is this filename string only used for CUDA? If so, please rename

[PATCH] D46524: [clangd] Extract scoring/ranking logic, and shave yaks.

2018-05-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 145478. sammccall marked 9 inline comments as done. sammccall added a comment. Address comments Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D46524 Files: clang-move/ClangMove.cpp clang-tidy/ClangTidy.cpp clang-tidy/ClangTidyDiagno

[PATCH] D46524: [clangd] Extract scoring/ranking logic, and shave yaks.

2018-05-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clangd/CodeComplete.cpp:909 + +auto QualScore = Quality.evaluate(), RelScore = Relevance.evaluate(); +CompletionItemScores Scores; ilya-biryukov wrote: > NIT: Maybe use `float` here instead of auto? Would remov

[PATCH] D46472: [HIP] Support offloading by linkscript

2018-05-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 145480. yaxunl marked 2 inline comments as done. yaxunl added a comment. Rename variables used for CUDA only. https://reviews.llvm.org/D46472 Files: include/clang/Driver/Options.td lib/CodeGen/CGCUDANV.cpp lib/Driver/ToolChains/CommonArgs.cpp lib/Dri

r331644 - [docs] Fix typos in the Clang User's Manual.

2018-05-07 Thread Joel Galenson via cfe-commits
Author: jgalenson Date: Mon May 7 09:23:46 2018 New Revision: 331644 URL: http://llvm.org/viewvc/llvm-project?rev=331644&view=rev Log: [docs] Fix typos in the Clang User's Manual. Modified: cfe/trunk/docs/UsersManual.rst Modified: cfe/trunk/docs/UsersManual.rst URL: http://llvm.org/viewvc/

[PATCH] D46115: [ASTImporter] properly import SrcLoc of Attr

2018-05-07 Thread Rafael Stahl via Phabricator via cfe-commits
r.stahl updated this revision to Diff 145486. r.stahl edited the summary of this revision. r.stahl added a comment. full patch with test https://reviews.llvm.org/D46115 Files: include/clang/AST/ASTImporter.h lib/AST/ASTImporter.cpp test/Import/attr/Inputs/S.cpp test/Import/attr/test.cpp

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. erichkeane added reviewers: aaron.ballman, spatel, RKSimon. As identified and briefly discussed here: https://bugs.llvm.org/show_bug.cgi?id=37305 Converting a floating point number to an integer type when the integral part is out of the range of the integer type

r331651 - Fix explicit template parameter reporting for narrowing conversions

2018-05-07 Thread Erich Keane via cfe-commits
Author: erichkeane Date: Mon May 7 10:05:20 2018 New Revision: 331651 URL: http://llvm.org/viewvc/llvm-project?rev=331651&view=rev Log: Fix explicit template parameter reporting for narrowing conversions I found that explicit template parameters that caused a narrowing integer conversion resulte

[PATCH] D42664: Fix explicit template parameter reporting for narrowing conversions

2018-05-07 Thread Erich Keane via Phabricator via cfe-commits
erichkeane abandoned this revision. erichkeane added a comment. Did Review-after-commit, in retrospect this is a pretty tiny change. https://reviews.llvm.org/D42664 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bi

[PATCH] D46115: [ASTImporter] properly import SrcLoc of Attr

2018-05-07 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a comment. Hi Rafael! Please find my comments inline. Comment at: lib/AST/ASTImporter.cpp:2650 + for (const auto *A : D->attrs()) +ToIndirectField->addAttr(Importer.Import(const_cast(A))); Could we just remove 'const' qualifier from `A` t

[PATCH] D46115: [ASTImporter] properly import SrcLoc of Attr

2018-05-07 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a comment. Sorry, two more nits. Comment at: include/clang/AST/ASTImporter.h:137 +/// +/// \returns the equivalent attribute in the "to" context, or NULL if an +/// error occurred. nullptr Comment at: lib/AST/ASTIm

r331652 - [OPENMP, NVPTX] Codegen for critical construct.

2018-05-07 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Mon May 7 10:23:05 2018 New Revision: 331652 URL: http://llvm.org/viewvc/llvm-project?rev=331652&view=rev Log: [OPENMP, NVPTX] Codegen for critical construct. Added correct codegen for the critical construct on NVPTX devices. Modified: cfe/trunk/lib/CodeGen/CGOpenMPRun

[PATCH] D43341: [clang-doc] Implement reducer portion of the frontend framework

2018-05-07 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added inline comments. Comment at: clang-doc/Representation.cpp:53 + move(Namespace, std::move(Other.Namespace)); + extend(Description, std::move(Other.Description)); + return true; sammccall wrote: > is plain concatenation of comments what you wa

[PATCH] D46241: [CodeGen] Recognize more cases of zero initialization

2018-05-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGExprConstant.cpp:1403 + if (auto *IL = dyn_cast_or_null(Init)) { +if (InitTy->isConstantArrayType()) { + for (auto I : IL->inits()) sepavloff wrote: > rjmccall wrote: > > Do you actually care if

[PATCH] D46471: [HIP] Add hip offload kind

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

r331654 - [OPENMP, NVPTX] Small test fix, NFC.

2018-05-07 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Mon May 7 10:38:13 2018 New Revision: 331654 URL: http://llvm.org/viewvc/llvm-project?rev=331654&view=rev Log: [OPENMP, NVPTX] Small test fix, NFC. Modified: cfe/trunk/test/OpenMP/nvptx_parallel_codegen.cpp Modified: cfe/trunk/test/OpenMP/nvptx_parallel_codegen.cpp URL

[PATCH] D45476: [C++2a] Implement operator<=> CodeGen and ExprConstant

2018-05-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGExprAgg.cpp:964 +RHS = CGF.EmitAnyExpr(E->getRHS()).getAggregatePointer(); +break; + case TEK_Complex: EricWF wrote: > EricWF wrote: > > rjmccall wrote: > > > It looks like we don't actually suppo

[PATCH] D45702: [clang-tidy] Add a new check, readability-redundant-data-call, that finds and removes redundant calls to .data().

2018-05-07 Thread Shuai Wang via Phabricator via cfe-commits
shuaiwang added inline comments. Comment at: clang-tidy/readability/RedundantDataCallCheck.cpp:45 + anyOf(TypesMatcher, pointerType(pointee(TypesMatcher)), + callee(namedDecl(hasName("data" + .bind("call", aa

[PATCH] D45476: [C++2a] Implement operator<=> CodeGen and ExprConstant

2018-05-07 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added inline comments. Comment at: lib/AST/ExprConstant.cpp:8829 + return EvaluateComparisonBinaryOperator(Info, E, OnSuccess, [&]() { +return ExprEvaluatorBaseTy::VisitBinaryOperator(E); + }); rsmith wrote: > EricWF wrote: > > rsmith wrote: > > > It

[PATCH] D46540: [X86] ptwrite intrinsic

2018-05-07 Thread Gabor Buella via Phabricator via cfe-commits
GBuella created this revision. GBuella added a reviewer: craig.topper. Herald added subscribers: cfe-commits, mgorny. Repository: rC Clang https://reviews.llvm.org/D46540 Files: include/clang/Basic/BuiltinsX86.def include/clang/Basic/BuiltinsX86_64.def include/clang/Driver/Options.td l

Re: r331556 - [analyzer] Treat more const variables and fields as known contants.

2018-05-07 Thread Alexander Kornienko via cfe-commits
It looks like this commit has introduced an assertion failure. See https://bugs.llvm.org/show_bug.cgi?id=37357. On Fri, May 4, 2018 at 10:56 PM Artem Dergachev via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: dergachev > Date: Fri May 4 13:52:39 2018 > New Revision: 331556 > > URL:

[PATCH] D46541: [CodeGen] Improve diagnostics related to target attributes

2018-05-07 Thread Gabor Buella via Phabricator via cfe-commits
GBuella created this revision. GBuella added reviewers: craig.topper, echristo, dblaikie. Herald added a subscriber: cfe-commits. When requirement imposed by __target__ attributes on functions are not satisfied, prefer printing those requirements, which are explicitly mentioned in the attributes.

[PATCH] D24867: Request init/fini array on FreeBSD 12 and later

2018-05-07 Thread Dimitry Andric via Phabricator via cfe-commits
dim added a comment. Brooks, I can commit this if you prefer. Maybe it can go into 6.0.2 still... https://reviews.llvm.org/D24867 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] r331661 - Status updates for Rapperswil

2018-05-07 Thread Marshall Clow via cfe-commits
Author: marshall Date: Mon May 7 11:59:04 2018 New Revision: 331661 URL: http://llvm.org/viewvc/llvm-project?rev=331661&view=rev Log: Status updates for Rapperswil Modified: libcxx/trunk/www/upcoming_meeting.html Modified: libcxx/trunk/www/upcoming_meeting.html URL: http://llvm.org/viewvc/

Re: r331536 - [NFC]Convert Class to use member initialization instead of inline.

2018-05-07 Thread David Blaikie via cfe-commits
Perhaps this should use non-static data member initializers instead? On Fri, May 4, 2018 at 9:23 AM Erich Keane via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: erichkeane > Date: Fri May 4 09:19:53 2018 > New Revision: 331536 > > URL: http://llvm.org/viewvc/llvm-project?rev=331536

[PATCH] D46300: [Clang] Implement function attribute no_stack_protector.

2018-05-07 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta updated this revision to Diff 145514. manojgupta added a comment. Added docs, Sema test case for the attribute. Repository: rC Clang https://reviews.llvm.org/D46300 Files: include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.td lib/CodeGen/CodeGenModule.cpp lib/Sema/Se

[PATCH] D45093: [AST] Fix -ast-print for _Bool when have diagnostics

2018-05-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny added a comment. In https://reviews.llvm.org/D45093#1087652, @aaron.ballman wrote: > This approach generally looks good to me, but I'd like @rsmith's opinion on > whether we should be trying to make -ast-print have good source fidelity or > not. I was under the impression we wanted -ast-

[PATCH] D46024: [clang-format] Add SpaceBeforeCpp11BracedList option.

2018-05-07 Thread Ross Kirsling via Phabricator via cfe-commits
rkirsling added a comment. Any further commentary? :) Repository: rC Clang https://reviews.llvm.org/D46024 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D46300: [Clang] Implement function attribute no_stack_protector.

2018-05-07 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta added inline comments. Comment at: include/clang/Basic/Attr.td:1494 +def NoStackProtector : InheritableAttr { + let Spellings = [GCC<"no_stack_protector">]; + let Subjects = SubjectList<[Function]>; aaron.ballman wrote: > This is not a GCC attribute,

[PATCH] D45476: [C++2a] Implement operator<=> CodeGen and ExprConstant

2018-05-07 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. Fine, that works. https://reviews.llvm.org/D45476 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailm

RE: r331536 - [NFC]Convert Class to use member initialization instead of inline.

2018-05-07 Thread Keane, Erich via cfe-commits
I don’t believe the member initialization for bitfields (of which all the ‘0’ values are) happened until C++17, right? I could definitely member initialize the two enum fields though. From: David Blaikie [mailto:dblai...@gmail.com] Sent: Monday, May 7, 2018 12:03 PM To: Keane, Erich Cc: cfe-co

[PATCH] D42933: [Sema] Avoid -Wformat warning for NSInteger/NSUInteger 'int' values with %zu/%zi long specifiers

2018-05-07 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. Herald added a reviewer: javed.absar. I was just looking at this, and I think @arphaman's patch is pretty much the right approach (with 2 suggested fixes below). I don't think the code we're currently warning on is broken: a user code has `NSInteger` with `%zd` or `NSUInteg

[PATCH] D24867: Request init/fini array on FreeBSD 12 and later

2018-05-07 Thread Brooks Davis via Phabricator via cfe-commits
brooks accepted this revision. brooks added a comment. I do think we should make this change, but don't have a strong opinion on the timing. If we do it for 12 and not 13 then we should probably try to get it into a 6.0.2. https://reviews.llvm.org/D24867 ___

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Caroline Tice via Phabricator via cfe-commits
cmtice updated this revision to Diff 145524. cmtice added a comment. Fix test failure that my previous changes caused. https://reviews.llvm.org/D46403 Files: lib/Driver/SanitizerArgs.cpp test/Driver/Inputs/resource_dir_with_cfi_blacklist/cfi_blacklist.txt test/Driver/fsanitize-blacklist.c

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Do you have commit access? If not I'd be happy to land this for you. Comment at: test/Driver/Inputs/resource_dir_with_cfi_blacklist/cfi_blacklist.txt:19 +# in order to call std::allocator_traits::construct. +fun:_ZNSt23_Sp_counted_ptr_inplace*

[PATCH] D45702: [clang-tidy] Add a new check, readability-redundant-data-call, that finds and removes redundant calls to .data().

2018-05-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/RedundantDataCallCheck.cpp:45 + anyOf(TypesMatcher, pointerType(pointee(TypesMatcher)), + callee(namedDecl(hasName("data" + .bind("call", ---

[PATCH] D42933: [Sema] Avoid -Wformat warning for NSInteger/NSUInteger 'int' values with %zu/%zi long specifiers

2018-05-07 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. Note that the alignment matters in addition to the size. The pattern I've seen internally is people using `%zd` for NSInteger and `%tu` for NSUInteger, since until clang 6 neither of those were format-checked at all. I'd be fine with adding an option to relax the printf

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Caroline Tice via Phabricator via cfe-commits
cmtice added a comment. I'm not sure if I have commit access or not; Peter was working with me on trying to commit the change. https://reviews.llvm.org/D46403 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mai

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: lib/Sema/SemaChecking.cpp:9432 if (IsLiteral) { +// Conversion of a floating point value to a non-bool integer where the +// integral part cannot be represented by the integer type is undefined. floating

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added inline comments. Comment at: test/Frontend/dependency-gen.c:24 // RUN: echo "fun:foo" > %t.blacklist -// RUN: %clang -MD -MF - %s -fsyntax-only -fsanitize=cfi-vcall -flto -fvisibility=hidden -fsanitize-blacklist=%t.blacklist -I ./ | FileCheck -check-prefix=CHECK-SEVE

[PATCH] D45093: [AST] Fix -ast-print for _Bool when have diagnostics

2018-05-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. If you want to force a particular printing policy to be used for `-ast-print`, I think it would be better to change the `print` call in `lib/Frontend/ASTConsumers.cpp` to pass your desired printing policy, rather than changing other components to prevent them from changi

r331666 - [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Martin Storsjo via cfe-commits
Author: mstorsjo Date: Mon May 7 13:26:09 2018 New Revision: 331666 URL: http://llvm.org/viewvc/llvm-project?rev=331666&view=rev Log: [Driver] Use -fuse-line-directives by default in MSVC mode Don't use the GNU extension form of line markers in MSVC mode. Differential Revision: https://reviews.

[PATCH] D46520: [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Martin Storsjö via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC331666: [Driver] Use -fuse-line-directives by default in MSVC mode (authored by mstorsjo, committed by ). Changed prior to commit: https://reviews.llvm.org/D46520?vs=145446&id=145528#toc Repository:

[PATCH] D46520: [Driver] Use -fuse-line-directives by default in MSVC mode

2018-05-07 Thread Martin Storsjö via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL331666: [Driver] Use -fuse-line-directives by default in MSVC mode (authored by mstorsjo, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D4652

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 2 inline comments as done. erichkeane added inline comments. Comment at: lib/Sema/SemaChecking.cpp:9440-9441 +diag::warn_impcast_literal_float_to_integer_out_of_range); + if (IntegerValue.isUnsigned() && + (IntegerValue.isMaxValue() ||

[PATCH] D46300: [Clang] Implement function attribute no_stack_protector.

2018-05-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman edited reviewers, added: probinson; removed: void. aaron.ballman added a subscriber: probinson. aaron.ballman added a comment. Adding in @probinson as he originally added the `optnone` attribute. Paul, do you recall why you opted (haha, pun totally intended) to implement `optnone`

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 145536. erichkeane marked an inline comment as done. erichkeane added a comment. Aaron's comments :) https://reviews.llvm.org/D46535 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaChecking.cpp test/SemaCXX/coroutines.cpp test/Sema

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Caroline Tice via Phabricator via cfe-commits
cmtice updated this revision to Diff 145537. cmtice added a comment. Make -resource-dir point to correct directory, in test case; move cfi_blacklist.txt file to 'share' subdirectory in test resource dir. https://reviews.llvm.org/D46403 Files: lib/Driver/SanitizerArgs.cpp test/Driver/Inputs

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 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. LGTM! https://reviews.llvm.org/D46535 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Caroline Tice via Phabricator via cfe-commits
cmtice updated this revision to Diff 145540. cmtice added a comment. Make cfi_blacklist.txt be an empty file. https://reviews.llvm.org/D46403 Files: lib/Driver/SanitizerArgs.cpp test/Driver/Inputs/resource_dir_with_cfi_blacklist/share/cfi_blacklist.txt test/Driver/fsanitize-blacklist.c

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc accepted this revision. pcc added a comment. LGTM https://reviews.llvm.org/D46403 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D46535: Correct warning on Float->Integer conversions.

2018-05-07 Thread Erich Keane via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC331673: Correct warning on Float->Integer conversions. (authored by erichkeane, committed by ). Changed prior to commit: https://reviews.llvm.org/D46535?vs=145536&id=145542#toc Repository: rC Clang

r331673 - Correct warning on Float->Integer conversions.

2018-05-07 Thread Erich Keane via cfe-commits
Author: erichkeane Date: Mon May 7 13:52:56 2018 New Revision: 331673 URL: http://llvm.org/viewvc/llvm-project?rev=331673&view=rev Log: Correct warning on Float->Integer conversions. As identified and briefly discussed here: https://bugs.llvm.org/show_bug.cgi?id=37305 Converting a floating poin

r331674 - [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Mon May 7 13:54:05 2018 New Revision: 331674 URL: http://llvm.org/viewvc/llvm-project?rev=331674&view=rev Log: [CFI] Force LLVM to die if the implicit blacklist files cannot be found. Currently LLVM CFI tries to use an implicit blacklist file, currently in /usr/lib64/clang//sha

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-05-07 Thread Peter Collingbourne via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC331674: [CFI] Force LLVM to die if the implicit blacklist files cannot be found. (authored by pcc, committed by ). Repository: rC Clang https://reviews.llvm.org/D46403 Files: lib/Driver/SanitizerArg

[PATCH] D42933: [Sema] Avoid -Wformat warning for NSInteger/NSUInteger 'int' values with %zu/%zi long specifiers

2018-05-07 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In https://reviews.llvm.org/D42933#1090286, @smeenai wrote: > Note that the alignment matters in addition to the size. Sure, but AFAICT from `./lib/Basic/Targets/*` the alignment is also specified properly, is it not? > The pattern I've seen internally is people using `%z

[PATCH] D45093: [AST] Fix -ast-print for _Bool when have diagnostics

2018-05-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny added a comment. In https://reviews.llvm.org/D45093#1090292, @rsmith wrote: > If you want to force a particular printing policy to be used for > `-ast-print`, I think it would be better to change the `print` call in > `lib/Frontend/ASTConsumers.cpp` to pass your desired printing policy,

[PATCH] D45476: [C++2a] Implement operator<=> CodeGen and ExprConstant

2018-05-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/AST/ASTContext.h:1983 + /// \brief Types and expressions required to build C++2a three-way comparisons + /// using operator<=>, including the values return by builtin <=> operators. + ComparisonCategories CompCategori

[PATCH] D43778: [clang-tidy] Adding RestrictIncludes check to Fuchsia module

2018-05-07 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added inline comments. Comment at: clang-tidy/fuchsia/RestrictIncludesCheck.cpp:75 +for (const auto &Include : FileDirectives) { + auto D = Check.diag(Include.Loc, "restricted include found"); + aaron.ballman wrote: > I believe this check wi

[PATCH] D43778: [clang-tidy] Adding RestrictIncludes check to Fuchsia module

2018-05-07 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett updated this revision to Diff 145547. juliehockett marked 9 inline comments as done. juliehockett edited the summary of this revision. juliehockett added a comment. Sorry for the delay in updating this -- check now restricts includes to a whitelist, rather than a blacklist, and only

[PATCH] D46550: Support Swift calling convention for PPC64 targets

2018-05-07 Thread Bob Wilson via Phabricator via cfe-commits
bob.wilson created this revision. bob.wilson added a reviewer: aschwaighofer. Herald added subscribers: kbarton, nemanjai, mcrosier. This adds basic support for the Swift calling convention with PPC64 targets. Patch provided by Atul Sowani in bug report #37223 Repository: rC Clang https://rev

[PATCH] D46550: Support Swift calling convention for PPC64 targets

2018-05-07 Thread Bob Wilson via Phabricator via cfe-commits
bob.wilson added a comment. Previous review (for the swift-llvm GitHub repo): https://github.com/apple/swift-clang/pull/167 Repository: rC Clang https://reviews.llvm.org/D46550 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists

[PATCH] D46052: GNUstep Objective-C ABI version 2

2018-05-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Thanks, the comments help a lot. Comment at: lib/CodeGen/CGObjCGNU.cpp:439 + ArrayRef IvarOffsets, + ArrayRef IvarAlign, + ArrayRef IvarOwnership); the

r331681 - Relax a FileCheck pattern to make it pass on Windows.

2018-05-07 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Mon May 7 14:40:53 2018 New Revision: 331681 URL: http://llvm.org/viewvc/llvm-project?rev=331681&view=rev Log: Relax a FileCheck pattern to make it pass on Windows. Should fix Windows bot failure: http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fas

r331682 - [X86] Make _mm256_gf2p8mul_epi8 require avx features since its 256 bits.

2018-05-07 Thread Craig Topper via cfe-commits
Author: ctopper Date: Mon May 7 14:47:11 2018 New Revision: 331682 URL: http://llvm.org/viewvc/llvm-project?rev=331682&view=rev Log: [X86] Make _mm256_gf2p8mul_epi8 require avx features since its 256 bits. Without this we throw an error on the header file instead of the user code when the right

  1   2   >