[PATCH] D55349: Convert some ObjC alloc msgSends to runtime calls

2018-12-07 Thread Pete Cooper via Phabricator via cfe-commits
pete added a comment. In D55349#1323926 , @rjmccall wrote: > LGTM. Thanks for the review! Landed in r348687. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55349/new/ https://reviews.llvm.org/D55349 _

[libunwind] r348699 - Creating release candidate rc3 from release_701 branch

2018-12-07 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Fri Dec 7 21:19:40 2018 New Revision: 348699 URL: http://llvm.org/viewvc/llvm-project?rev=348699&view=rev Log: Creating release candidate rc3 from release_701 branch Added: libunwind/tags/RELEASE_701/rc3/ (props changed) - copied from r348698, libunwind/branche

r348687 - Convert some ObjC msgSends to runtime calls.

2018-12-07 Thread Pete Cooper via cfe-commits
Author: pete Date: Fri Dec 7 21:13:50 2018 New Revision: 348687 URL: http://llvm.org/viewvc/llvm-project?rev=348687&view=rev Log: Convert some ObjC msgSends to runtime calls. It is faster to directly call the ObjC runtime for methods such as alloc/allocWithZone instead of sending a message to t

[PATCH] D55470: Cpp11 Braced List Style Ignores BAS_AlwaysBreak

2018-12-07 Thread John Gehrig via Phabricator via cfe-commits
jgehrig created this revision. jgehrig added a project: clang. Herald added a subscriber: cfe-commits. First patch attempt :) I've noticed that clang-format does not honor the BAS_AlwaysBreak when Cpp11BracedListStyle is set. This seems like a bug, as BAS_DontAlign will change the line continua

r348685 - Move diagnostic enums into Basic.

2018-12-07 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Fri Dec 7 21:05:03 2018 New Revision: 348685 URL: http://llvm.org/viewvc/llvm-project?rev=348685&view=rev Log: Move diagnostic enums into Basic. Move enums from */*Diagnostic.h to Basic/Diagnostic*.h. Basic/AllDiagnostics.h needs all the enums and moving the sources to Basi

[PATCH] D55468: Use zip_longest for list comparisons.

2018-12-07 Thread Michael Kruse via Phabricator via cfe-commits
Meinersbur created this revision. Meinersbur added reviewers: dblaikie, hfinkel. Use zip_longest in two locations that compare iterator ranges. zip_longest allows the iteration using a range-based for-loop and to be symmetric over both ranges instead of prioritizing one over the other. In that l

[PATCH] D55097: [constexpr][c++2a] Try-catch blocks in constexpr functions

2018-12-07 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 177367. bruno marked an inline comment as done. bruno added a comment. Address @aaron.ballman and @erik.pilkington reviews. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55097/new/ https://reviews.llvm.org/D55097 Files: include/clang/Basic/Diagnost

[PATCH] D55465: Stop tracking retain count of OSObject after escape to void * / other primitive types

2018-12-07 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC348675: Stop tracking retain count of OSObject after escape to void * / other primitive… (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: h

r348675 - Stop tracking retain count of OSObject after escape to void * / other primitive types

2018-12-07 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Dec 7 17:18:40 2018 New Revision: 348675 URL: http://llvm.org/viewvc/llvm-project?rev=348675&view=rev Log: Stop tracking retain count of OSObject after escape to void * / other primitive types Escaping to void * / uint64_t / others non-OSObject * should stop t

[PATCH] D55456: [CUDA] added missing 'inline' for the functions defined in the header.

2018-12-07 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. jlebar@ LGTM'ed via email. Landed in rL348662 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55456/new/ https://reviews.llvm.org/D55456 ___

[PATCH] D55455: Remove stat cache chaining as it's no longer needed after PTH support has been removed

2018-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. In D55455#1323836 , @dexonsmith wrote: > This patch LGTM, but before committing I suggest sending an RFC to cfe-dev > and waiting a few days. I posted to `cfe-dev` to check if there are any objections. Repository: rC Clang

[PATCH] D55097: [constexpr][c++2a] Try-catch blocks in constexpr functions

2018-12-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Some minor nits from the peanut gallery. Comment at: lib/AST/ExprConstant.cpp:4278 + case Stmt::CXXTryStmtClass: +// Evaluate try blocks by evaluating all sub statements +return EvaluateStmt(Result, Info, cast(S)->getTryBlock(), Case); -

[PATCH] D55097: [constexpr][c++2a] Try-catch blocks in constexpr functions

2018-12-07 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. LGTM, but you should probably let @rsmith have the final word! Comment at: lib/Sema/SemaDeclCXX.cpp:1916-1919 +for (Stmt *SubStmt : S->children()) + if (SubStmt && + !CheckConstexprFunctionStmt(SemaRef, Dcl, SubStmt, ReturnStmt

[PATCH] D55463: Introduce a source minimizer that reduces source to directives that might affect the dependency list for a compilation

2018-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: dexonsmith, Bigcheese, dblaikie, vsapsai, sammccall, rsmith, bruno. Herald added subscribers: jkorous, mgorny. This patch introduces a dependency directives source minimizer to clang that minimizes header and source files to the minimum n

[clang-tools-extra] r348666 - [Documentation] Alphabetical order in new checks list.

2018-12-07 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Fri Dec 7 16:07:34 2018 New Revision: 348666 URL: http://llvm.org/viewvc/llvm-project?rev=348666&view=rev Log: [Documentation] Alphabetical order in new checks list. Modified: clang-tools-extra/trunk/docs/ReleaseNotes.rst Modified: clang-tools-extra/trunk/docs/Re

[PATCH] D55451: [tests] Fix the FileManagerTest getVirtualFile test on Windows

2018-12-07 Thread Stella Stamenova via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC348665: [tests] Fix the FileManagerTest getVirtualFile test on Windows (authored by stella.stamenova, committed by ). Rep

r348665 - [tests] Fix the FileManagerTest getVirtualFile test on Windows

2018-12-07 Thread Stella Stamenova via cfe-commits
Author: stella.stamenova Date: Fri Dec 7 15:50:05 2018 New Revision: 348665 URL: http://llvm.org/viewvc/llvm-project?rev=348665&view=rev Log: [tests] Fix the FileManagerTest getVirtualFile test on Windows Summary: The test passes on Windows only when it is executed on the C: drive. If the build

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 177341. jfb added a comment. - Fix typo Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54604/new/ https://reviews.llvm.org/D54604 Files: include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.td include/clang/Basic/Diagno

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski resigned from this revision. krytarowski added a comment. Herald added a subscriber: krytarowski. I don't feel enough comfortable with this Python code. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55443/new/ https://reviews.llvm.org/D55443 __

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: include/clang/Basic/DiagnosticDriverKinds.td:412 + "Enable it at your own peril for benchmarking purpose only with " + "-enable-trivial-auto-var-init-zero-knowning-it-will-be-removed-from-clang">; + s/knowning/knowi

[PATCH] D51329: [Attribute/Diagnostics] Print macro instead of whole attribute for address_space

2018-12-07 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 177335. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D51329/new/ https://reviews.llvm.org/D51329 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/RecursiveASTVisitor.h clang/include/clang/AST/Type.

[PATCH] D55429: [analyzer] Add CheckerManager::getChecker, make sure that a registry function registers no more than 1 checker

2018-12-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D55429#1324035 , @NoQ wrote: > Aha, ok, so what's the final procedure In D55429#1324035 , @NoQ wrote: > Aha, ok, so what's the final procedure now to register a checker that's > a

[PATCH] D54438: [analyzer] Reimplement dependencies between checkers

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Also you might need to rebase on top of D55400 . CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54438/new/ https://reviews.llvm.org/D54438 ___ cfe-commits mailing list cfe-commits@lists.

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 177331. jfb added a comment. - Update warning-flags.c Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54604/new/ https://reviews.llvm.org/D54604 Files: include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.td include/clan

[PATCH] D55388: [analyzer] MoveChecker Pt.8: Add checks for dereferencing a smart pointer after move.

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 177332. NoQ added a comment. Fix typo. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55388/new/ https://reviews.llvm.org/D55388 Files: lib/StaticAnalyzer/Checkers/MoveChecker.cpp test/Analysis/use-after-move.cpp Index: test/Analysis/use-after-move

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177330. MyDeveloperDay added a comment. Minor alterations to Release notes and Documentation to address review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55433/new/ https://reviews.llvm.org/D55433 Files: clang-tidy/modernize/CM

[PATCH] D54438: [analyzer] Reimplement dependencies between checkers

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Generally, because the primary user of checker names is clang-tidy, the correct name to display is the name of the specific checker that the user needs to disable in order to get rid of the warning. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54438/new/ https://

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. I added an option that's required when using `clang` directly (*not* `-cc1`!) If you use `-ftrivial-auto-var-init=zero` without `-enable-trivial-auto-var-init-zero-knowning-it-will-be-removed-from-clang` in `clang` it'll generate a warning and change initialization to patte

[PATCH] D54438: [analyzer] Reimplement dependencies between checkers

2018-12-07 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. I'm seeing no problems with this patch and i'm happy that we're replacing hacks with well-defined patterns :) In D54438#1322970 , @Szelethus wrote: > - Regi

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 177328. jfb added a comment. - Add an ugly option to enable zero init Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54604/new/ https://reviews.llvm.org/D54604 Files: include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.t

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177327. MyDeveloperDay added a comment. - Move the final conditional statements into AST_MATCHERS - Add additional IgnoreInternalFunctions option to allow adding of ``[[nodiscard]]`` to functions starting with _ (e.g. _Foo()) CHANGES SINCE LAST ACTIO

[PATCH] D55429: [analyzer] Add CheckerManager::getChecker, make sure that a registry function registers no more than 1 checker

2018-12-07 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. Aha, ok, so what's the final procedure now to register a checker that's artificially split in two? Something like this, right? def CommonModel : Checker<"Common">, HelpText<"Doesn't emit warni

[PATCH] D55245: [clang-tidy] Add the abseil-duration-subtraction check

2018-12-07 Thread Hyrum Wright via Phabricator via cfe-commits
hwright updated this revision to Diff 177325. hwright marked 7 inline comments as done. hwright added a comment. Use an `IndexedMap` instead of an `std::unordered_map` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55245/new/ https://reviews.llvm.org/D55245 Files: clang-tidy/abseil/Ab

[PATCH] D55245: [clang-tidy] Add the abseil-duration-subtraction check

2018-12-07 Thread Hyrum Wright via Phabricator via cfe-commits
hwright added inline comments. Comment at: clang-tidy/abseil/DurationRewriter.cpp:35 +getInverseForScale(DurationScale Scale) { + static const std::unordered_map> lebedev.ri wrote: > hwright wrote: > > lebedev.ri wrote: > > > https://llvm.org/docs/ProgrammersMan

[PATCH] D52117: Generate llvm.loop.parallel_accesses instead of llvm.mem.parallel_loop_access metadata.

2018-12-07 Thread Michael Kruse via Phabricator via cfe-commits
Meinersbur updated this revision to Diff 177324. Meinersbur added a comment. - Fix wrong patch upload - Simplify access group emission ... .. possible due to the added possibility for instructions to belong to multiple access groups in D52116 . However, the numbe

[PATCH] D52117: Generate llvm.loop.parallel_accesses instead of llvm.mem.parallel_loop_access metadata.

2018-12-07 Thread Michael Kruse via Phabricator via cfe-commits
Meinersbur updated this revision to Diff 177320. Meinersbur marked an inline comment as done. Meinersbur added a comment. - Allow multiple access groups per instructions, i.e. an instruction can be in multiple access groups. This allows a simple 'union' operation that occurs when inlining into a

[PATCH] D55424: [analyzer] Supply all checkers with a shouldRegister function

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. Yeah, this part looks easy :) Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55424/new/ https://reviews.llvm.org/D55424 ___ cfe-commits mailing list cfe-commits@lists.l

r348662 - [CUDA] Added missing 'inline' for functions defined in a header.

2018-12-07 Thread Artem Belevich via cfe-commits
Author: tra Date: Fri Dec 7 14:20:53 2018 New Revision: 348662 URL: http://llvm.org/viewvc/llvm-project?rev=348662&view=rev Log: [CUDA] Added missing 'inline' for functions defined in a header. Modified: cfe/trunk/lib/Headers/cuda_wrappers/new Modified: cfe/trunk/lib/Headers/cuda_wrappers/n

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: docs/ReleaseNotes.rst:173 + + This check adds ``[[nodiscard]]`` attributes (introduced in C++17) to member + functions to highlight at compile time where the return value of a function Please omit this check. Sa

[PATCH] D55425: [analyzer] Split unix.API up to UnixAPIMisuseChecker and UnixAPIPortabilityChecker

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: test/Analysis/Inputs/expected-plists/unix-fns.c.plist:3018 - /clang/test/Analysis/unix-fns.c + /home/szelethus/Documents/analyzer_opts/clang/test/Analysis/unix-fns.c Szelethus wrote: > NoQ wrote: > > Does this actua

[PATCH] D55425: [analyzer] Split unix.API up to UnixAPIMisuseChecker and UnixAPIPortabilityChecker

2018-12-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked an inline comment as done. Szelethus added inline comments. Comment at: test/Analysis/Inputs/expected-plists/unix-fns.c.plist:3018 - /clang/test/Analysis/unix-fns.c + /home/szelethus/Documents/analyzer_opts/clang/test/Analysis/unix-fns.c

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177313. MyDeveloperDay added a comment. Move the conditional statements into AST_MATCHERS CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55433/new/ https://reviews.llvm.org/D55433 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/mode

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177312. MyDeveloperDay added a comment. Move the conditional checks into matchers CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55433/new/ https://reviews.llvm.org/D55433 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/Mo

[PATCH] D55425: [analyzer] Split unix.API up to UnixAPIMisuseChecker and UnixAPIPortabilityChecker

2018-12-07 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. Nice! Comment at: test/Analysis/Inputs/expected-plists/unix-fns.c.plist:3018 - /clang/test/Analysis/unix-fns.c + /home/szelethus/Documents/analyzer_opts/clang/test/Analysis/u

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177311. MyDeveloperDay marked 3 inline comments as done. MyDeveloperDay added a comment. Move more of the conditional checks into the matchers CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55433/new/ https://reviews.llvm.org/D55433 Files:

Re: [PATCH] D55456: [CUDA] added missing 'inline' for the functions defined in the header.

2018-12-07 Thread Justin Lebar via cfe-commits
Lgtm On Fri, Dec 7, 2018, 1:12 PM Artem Belevich via Phabricator < revi...@reviews.llvm.org> wrote: > tra created this revision. > tra added a reviewer: jlebar. > Herald added subscribers: bixia, sanjoy. > > https://reviews.llvm.org/D55456 > > Files: > clang/lib/Headers/cuda_wrappers/new > > >

[PATCH] D55349: Convert some ObjC alloc msgSends to runtime calls

2018-12-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. LGTM. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55349/new/ https://reviews.llvm.org/D55349 ___ cfe-commits mailing list cfe-comm

[PATCH] D55388: [analyzer] MoveChecker Pt.8: Add checks for dereferencing a smart pointer after move.

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 177307. NoQ marked an inline comment as done. NoQ added a comment. Fxd! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55388/new/ https://reviews.llvm.org/D55388 Files: lib/StaticAnalyzer/Checkers/MoveChecker.cpp test/Analysis/use-after-move.cpp In

[PATCH] D55349: Convert some ObjC alloc msgSends to runtime calls

2018-12-07 Thread Pete Cooper via Phabricator via cfe-commits
pete updated this revision to Diff 177308. pete marked an inline comment as done. pete added a comment. Added test for integer argument and updated code to only accept pointer types to allocWithZone. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55349/new/ https://reviews.llvm.org/D553

[PATCH] D55387: [analyzer] MoveChecker Pt.7: NFC: Misc refactoring.

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 177306. NoQ marked 2 inline comments as done. NoQ added a comment. Fxd. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55387/new/ https://reviews.llvm.org/D55387 Files: lib/StaticAnalyzer/Checkers/MoveChecker.cpp Index: lib/StaticAnalyzer/Checkers/Mo

[PATCH] D55458: [analyzer] ObjCContainers: Track index values.

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ marked 2 inline comments as done. NoQ added inline comments. Comment at: test/Analysis/CFContainers.mm:178 void TestGetCount(CFArrayRef A, CFIndex sIndex) { - CFIndex sCount = CFArrayGetCount(A); - if (sCount > sIndex) + CFIndex sCount = CFArrayGetCount(A); // expected-no

[PATCH] D55458: [analyzer] ObjCContainers: Track index values.

2018-12-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, george.karpenkov. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, Szelethus, arphaman, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. This is a checker for CF (well, not really ObjC) arrays that checks array

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked 12 inline comments as done. MyDeveloperDay added inline comments. Comment at: clang-tidy/modernize/UseNodiscardCheck.cpp:28-30 +bool isOperator(const FunctionDecl *D) { + return D->getNameAsString().find("operator") != std::string::npos; +}

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/modernize/UseNodiscardCheck.cpp:40 +void UseNodiscardCheck::registerMatchers(MatchFinder *Finder) { + + // if we are using C++17 attributes we are going to need c++17 Unnecessary empty line.

[PATCH] D55349: Convert some ObjC alloc msgSends to runtime calls

2018-12-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGObjC.cpp:385 +// prefix are identified as OMF_alloc but we only want to call the +// runtime for this version. +if (Sel.isUnarySelector() && Sel.getNameForSlot(0) == "alloc") Actual

[PATCH] D55455: Remove stat cache chaining as it's no longer needed after PTH support has been removed

2018-12-07 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a comment. This patch LGTM, but before committing I suggest sending an RFC to cfe-dev and waiting a few days. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55455/new/ https://reviews.llvm.org/D55455 ___

[PATCH] D55455: Remove stat cache chaining as it's no longer needed after PTH support has been removed

2018-12-07 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. I've no problem with this, but I don't consider myself 'expert' on this stuff enough to mark 'Approve' without giving others time to take a look. I'd say give this until this time tuesday for the others to take a look, then you can consider this an 'approve'. I won

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 177295. MyDeveloperDay added a comment. Address some (not all yet) review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55433/new/ https://reviews.llvm.org/D55433 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/M

[PATCH] D55456: [CUDA] added missing 'inline' for the functions defined in the header.

2018-12-07 Thread Artem Belevich via Phabricator via cfe-commits
tra created this revision. tra added a reviewer: jlebar. Herald added subscribers: bixia, sanjoy. https://reviews.llvm.org/D55456 Files: clang/lib/Headers/cuda_wrappers/new Index: clang/lib/Headers/cuda_wrappers/new === --- clang

[PATCH] D55455: Remove stat cache chaining as it's no longer needed after PTH support has been removed

2018-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: erichkeane, dexonsmith, vsapsai, Bigcheese, ilya-biryukov. Herald added a subscriber: jkorous. Stat cache chaining was implemented for a StatListener in the PTH writer so that it could write out the stat information to PTH. r348266 remove

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D55433#1323757 , @MyDeveloperDay wrote: > a lot of projects aren't setup for c++17 yet which is needed for > [[nodiscard]] to be allowed, You can use `[[clang::warn_unused_result]]` for this evaluation, that does not req

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Michał Górny via Phabricator via cfe-commits
mgorny marked an inline comment as done. mgorny added inline comments. Comment at: test/lit.cfg.py:100 config.available_features.add('gnutar') -tar_version.wait() ruiu wrote: > Maybe a silly question, but is this OK to remove this line? Yes. [[ http

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. I'm trying to generate an example of the modernize-use-nodiscard checker on something open source...as I developed this checker on Windows I struggled a little getting cmake to build me the json file to run clang-tidy over everything and a lot of projects aren't

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added inline comments. Comment at: test/lit.cfg.py:100 config.available_features.add('gnutar') -tar_version.wait() Maybe a silly question, but is this OK to remove this line? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55443/new/ ht

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/modernize/UseNodiscardCheck.cpp:28-30 +bool isOperator(const FunctionDecl *D) { + return D->getNameAsString().find("operator") != std::string::npos; +} Can't you use `isOverloadedOperator()`? No way going

[PATCH] D55451: [tests] Fix the FileManagerTest getVirtualFile test on Windows

2018-12-07 Thread Stella Stamenova via Phabricator via cfe-commits
stella.stamenova created this revision. stella.stamenova added reviewers: kadircet, asmith. Herald added a subscriber: cfe-commits. The test passes on Windows only when it is executed on the C: drive. If the build and tests run on a different drive, the test is currently failing. Repository:

r348641 - [Preprocessor] Don't avoid entering included files after hitting a fatal error.

2018-12-07 Thread Volodymyr Sapsai via cfe-commits
Author: vsapsai Date: Fri Dec 7 12:29:54 2018 New Revision: 348641 URL: http://llvm.org/viewvc/llvm-project?rev=348641&view=rev Log: [Preprocessor] Don't avoid entering included files after hitting a fatal error. Change in r337953 violated the contract for `CXTranslationUnit_KeepGoing`: > Do no

[PATCH] D55385: [analyzer] RetainCountChecker: remove untested, unused, incorrect option IncludeAllocationLine

2018-12-07 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC348637: [analyzer] RetainCountChecker: remove untested, unused, incorrect option… (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https://

[PATCH] D55400: [analyzer] Move out tracking retain count for OSObjects into a separate checker

2018-12-07 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC348638: [analyzer] Move out tracking retain count for OSObjects into a separate checker (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: ht

r348638 - [analyzer] Move out tracking retain count for OSObjects into a separate checker

2018-12-07 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Dec 7 12:21:51 2018 New Revision: 348638 URL: http://llvm.org/viewvc/llvm-project?rev=348638&view=rev Log: [analyzer] Move out tracking retain count for OSObjects into a separate checker Allow enabling and disabling tracking of ObjC/CF objects separately from t

r348637 - [analyzer] RetainCountChecker: remove untested, unused, incorrect option IncludeAllocationLine

2018-12-07 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Dec 7 12:21:37 2018 New Revision: 348637 URL: http://llvm.org/viewvc/llvm-project?rev=348637&view=rev Log: [analyzer] RetainCountChecker: remove untested, unused, incorrect option IncludeAllocationLine The option has no tests, is not used anywhere, and is actu

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I recently had trouble with ignoring the return type, I would certainly appreciate a tool like this. Can you test it on LLVM+Clang? Maybe some methods in the AST library could also benefit from `LLVM_NODISCARD` (containers with factories is my no1 thought), and it's a

[PATCH] D53830: [clang-tidy]: Abseil: new check 'abseil-upgrade-duration-conversions'

2018-12-07 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF closed this revision. EricWF added a comment. Committed as r348633. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53830/new/ https://reviews.llvm.org/D53830 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.or

[PATCH] D55245: [clang-tidy] Add the abseil-duration-subtraction check

2018-12-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/abseil/DurationRewriter.cpp:35 +getInverseForScale(DurationScale Scale) { + static const std::unordered_map> hwright wrote: > lebedev.ri wrote: > > https://llvm.org/docs/ProgrammersManual.html#other-map-li

[clang-tools-extra] r348633 - [clang-tidy]: Abseil: new check 'abseil-upgrade-duration-conversions'

2018-12-07 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Fri Dec 7 12:03:03 2018 New Revision: 348633 URL: http://llvm.org/viewvc/llvm-project?rev=348633&view=rev Log: [clang-tidy]: Abseil: new check 'abseil-upgrade-duration-conversions' Patch by Alex Strelnikov. Reviewed as D53830 Introduce a new check to upgrade user code based

[PATCH] D48342: [libcxx] Optimize vectors construction of trivial types from an iterator range with const-ness mismatch.

2018-12-07 Thread Steve Canon via Phabricator via cfe-commits
scanon added inline comments. Comment at: libcxx/test/std/containers/sequences/vector/vector.cons/construct_iter_iter.pass.cpp:187 + assert(std::fabs(v[0] - 0.0f) < FLT_EPSILON); + assert(std::fabs(v[1] - 1.0f) < FLT_EPSILON); + assert(std::fabs(v[2] - 2.0f) < FLT_EPSILON); -

[PATCH] D49754: Add -m(no-)spe, and e500 CPU definitions and support to clang

2018-12-07 Thread vit9696 via Phabricator via cfe-commits
vit9696 added a comment. In D49754#1321078 , @glaubitz wrote: > I have applied this patch to the llvm-toolchain-7 package in Debian and did > not see any regressions on x86_64 or 32-Bit PowerPC. Additionally, I have > included the patches from https://re

[PATCH] D48342: [libcxx] Optimize vectors construction of trivial types from an iterator range with const-ness mismatch.

2018-12-07 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. If you use some of my suggestions, please make sure it compiles in C++03 mode. I might be using some C++11 features (not sure whether default argument for template parameters is C++03). Comment at: libcxx/test/std/containers/sequences/vector/vector.c

[PATCH] D55245: [clang-tidy] Add the abseil-duration-subtraction check

2018-12-07 Thread Hyrum Wright via Phabricator via cfe-commits
hwright added inline comments. Comment at: clang-tidy/abseil/DurationRewriter.cpp:35 +getInverseForScale(DurationScale Scale) { + static const std::unordered_map> lebedev.ri wrote: > https://llvm.org/docs/ProgrammersManual.html#other-map-like-container-options >

[PATCH] D55245: [clang-tidy] Add the abseil-duration-subtraction check

2018-12-07 Thread Hyrum Wright via Phabricator via cfe-commits
hwright updated this revision to Diff 177266. hwright marked 8 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55245/new/ https://reviews.llvm.org/D55245 Files: clang-tidy/abseil/AbseilTidyModule.cpp clang-tidy/abseil/CMakeLists.txt clang-tidy/abseil/Duration

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Michał Górny via Phabricator via cfe-commits
mgorny updated this revision to Diff 177265. mgorny marked 2 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55443/new/ https://reviews.llvm.org/D55443 Files: test/lit.cfg.py Index: test/lit.cfg.py ===

[PATCH] D48342: [libcxx] Optimize vectors construction of trivial types from an iterator range with const-ness mismatch.

2018-12-07 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Thanks for the feedback. Answered one simple question, the rest needs more time. Comment at: libcxx/test/std/containers/sequences/vector/vector.cons/construct_iter_iter.pass.cpp:186 + std::vector v(array, array + 3); + assert(std::fabs(v[0] - 0.0f) <

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. I've addressed @pcc's comments. I'll now update the patch to mandate a `-Xclang` option for zero-init (otherwise it'll warn and pattern-init instead), and remove documentation for zero-init. I'm also thinking of changing float init to negative NaN with infinite scream paylo

[PATCH] D54604: Automatic variable initialization

2018-12-07 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 177262. jfb marked 10 inline comments as done. jfb added a comment. - Make sure uninit-variables.c doesn't break. - Address Peter's comments, improve tests. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54604/new/ https://reviews

[PATCH] D55447: [Sema] Fix Modified Type in address_space AttributedType

2018-12-07 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan created this revision. leonardchan added reviewers: rsmith, aaron.ballman. leonardchan added a project: clang. This is a fix for https://reviews.llvm.org/D51229 where we pass the address_space qualified type as the modified type of an AttributedType. This change now instead wraps the

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: test/lit.cfg.py:101 +env={'LANG': 'C'}) +sout, serr = tar_version.communicate() +if 'GNU tar' in sout.decode(): LG, but `serr` can be replaced by `_` if it is not used. CHANGES SINCE LAST ACTION https

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added inline comments. Comment at: test/lit.cfg.py:99 +stdout=subprocess.PIPE, +stderr=subprocess.PIPE, +env={'LANG': 'C'}) ruiu wrote: > mgorny wrote: > > MaskRay wrote: > > > If you don't need stderr, remove `stderr=subprocess.PIPE,

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Michał Górny via Phabricator via cfe-commits
mgorny added a comment. Sorry, it seems that my reply didn't go through. Comment at: test/lit.cfg.py:99 +stdout=subprocess.PIPE, +stderr=subprocess.PIPE, +env={'LANG': 'C'}) MaskRay wrote: > If you don't need stderr, remove `stderr=subpr

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added inline comments. Comment at: test/lit.cfg.py:99 +stdout=subprocess.PIPE, +stderr=subprocess.PIPE, +env={'LANG': 'C'}) MaskRay wrote: > If you don't need stderr, remove `stderr=subprocess.PIPE,` > > `subprocess.Popen followed by

[PATCH] D55441: [lld] [test] Fix reproduce-blackslash.s test with NetBSD tar

2018-12-07 Thread Michał Górny via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL348628: [test] Fix reproduce-blackslash.s test with NetBSD tar (authored by mgorny, committed by ). Changed prior to commit: https://reviews.llvm.org/D55441?vs=177232&id=177251#toc Repository: rL LLV

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D55433#1323145 , @MyDeveloperDay wrote: > In D55433#1323106 , @lebedev.ri > wrote: > > > Have you evaluated this on some major C++ projects yet? > > I suspect this may have pretty l

[PATCH] D55433: [clang-tidy] Adding a new modernize use nodiscard checker

2018-12-07 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/modernize/UseNodiscardCheck.cpp:21 +namespace modernize { +namespace { + Please use static instead anonymous namespace for functions. See LLVM code style guidelines. Comment at: clan

[PATCH] D55443: [test] Capture stderr from 'tar --version' call as well

2018-12-07 Thread Michał Górny via Phabricator via cfe-commits
mgorny updated this revision to Diff 177250. mgorny marked 2 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55443/new/ https://reviews.llvm.org/D55443 Files: test/lit.cfg.py Index: test/lit.cfg.py ===

[PATCH] D55410: [clang-tidy] check for flagging using declarations in headers

2018-12-07 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: docs/clang-tidy/checks/abseil-alias-free-headers.rst:13 +The style guide http://google.github.io/styleguide/cppguide.html#Aliases discusses this +issue in more detail Missing link to guidelines, Repository:

[PATCH] D55410: [clang-tidy] check for flagging using declarations in headers

2018-12-07 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: docs/ReleaseNotes.rst:73 + + Flags using declarations in header files, and suggests that + these aliases be removed Please highlight using with ``. Comment at: docs/clang-tidy/checks/abseil-al

[PATCH] D55441: [lld] [test] Fix reproduce-blackslash.s test with NetBSD tar

2018-12-07 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. bsdtar is libarchive (by BSD people too) We can align our native tar later and land this as is. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55441/new/ https://reviews.llvm.org/D55441 _

[PATCH] D34796: upporting -f(no)-reorder-functions flag, clang side change

2018-12-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: docs/ClangCommandLineReference.rst:1953 +.. option:: -freorder-functions, -fno-reorder-functions + Isn't this autogenerated from `include/clang/Driver/Options.td`? Repository: rC Clang CHANGES SINCE LAST ACTION

[PATCH] D55441: [lld] [test] Fix reproduce-blackslash.s test with NetBSD tar

2018-12-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu accepted this revision. ruiu added a comment. This revision is now accepted and ready to land. LGTM We might be able to change NetBSD's tar but I guess that takes very long time. This test is not very important in the sense that this tests just test a corner case. So I think we should just

[PATCH] D54438: [analyzer] Reimplement dependencies between checkers

2018-12-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D54438#1315953 , @Szelethus wrote: > - ❌ Move `CheckerManager::registerChecker` out of the registry functions. > - ❌ Since `shouldRegister##CHECKERNAME` is a thing, we can move everything > to the checker's constructor, sup

[PATCH] D55441: [lld] [test] Fix reproduce-blackslash.s test with NetBSD tar

2018-12-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added a comment. I thought NetBSD's tar is bsdtar because it's BSD... Anyways, I think I'm fine with this change, as the new test (which matches both `foo\\.o` and `foo\.o`) does not match a string that we don't want it to match. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION

  1   2   3   >