[PATCH] D42043: c-index: CXString: fix MSAN read-past-end bug

2018-08-17 Thread Steve O'Brien via Phabricator via cfe-commits
elsteveogrande updated this revision to Diff 161370. elsteveogrande added a comment. Rebase + fix conflicts for very old diff. Works again. `ninja check-clang` with MSAN-enabled build: Before: Failing Tests (2): Clang :: CodeGen/signed_metadata.cpp Clang :: Index/comment-to-html-

Re: r340114 - [analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker

2018-08-17 Thread Bruno Cardoso Lopes via cfe-commits
Hi George, This broke the modules build, reverted in r340117 for now. I can help you figure out any module map change if necessary next week. Thanks, On Fri, Aug 17, 2018 at 6:46 PM George Karpenkov via cfe-commits wrote: > > Author: george.karpenkov > Date: Fri Aug 17 18:45:50 2018 > New Revisi

r340117 - Revert "[analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker"

2018-08-17 Thread Bruno Cardoso Lopes via cfe-commits
Author: bruno Date: Fri Aug 17 20:22:11 2018 New Revision: 340117 URL: http://llvm.org/viewvc/llvm-project?rev=340117&view=rev Log: Revert "[analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker" This reverts commit a786521fa66c72edd308baff0c08961b6d964fb1. Bots haven't caught up

[PATCH] D41217: [Concepts] Concept Specialization Expressions

2018-08-17 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/AST/ExprCXX.h:4420 + /// \brief The concept named. + ConceptDecl *NamedConcept; + saar.raz wrote: > rsmith wrote: > > You should also track the `FoundDecl` and the optional > > `NestedNameSpecifierLoc` (j

[PATCH] D50870: Close FileEntries of cached files in ModuleManager::addModule().

2018-08-17 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Thanks for working on this Adrian, LGTM. > When we last discussed this my plan was to avoid the stat() in > lookupModuleFile() for files that were just added to the PCMCache by > WriteAST() ent

[PATCH] D50703: [clangd] NFC: Mark Workspace Symbol feature complete in the documentation

2018-08-17 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. Herald added a subscriber: kadircet. I hadn't marked it as done because without symbols in main files I found it quite lacking. Repository: rL LLVM https://reviews.llvm.org/D50703 ___ cfe-commits mailing list cfe-commi

r340110 - Quickfix for failing tests.

2018-08-17 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Aug 17 16:54:00 2018 New Revision: 340110 URL: http://llvm.org/viewvc/llvm-project?rev=340110&view=rev Log: Quickfix for failing tests. Modified: cfe/trunk/test/ARCMT/objcmt-arc-cf-annotations.m.result Modified: cfe/trunk/test/ARCMT/objcmt-arc-cf-annotation

r340109 - [index] For an ObjC message call, also record as receivers the protocols if they are present in the ObjC type

2018-08-17 Thread Argyrios Kyrtzidis via cfe-commits
Author: akirtzidis Date: Fri Aug 17 16:50:59 2018 New Revision: 340109 URL: http://llvm.org/viewvc/llvm-project?rev=340109&view=rev Log: [index] For an ObjC message call, also record as receivers the protocols if they are present in the ObjC type Modified: cfe/trunk/lib/Index/IndexBody.cpp

[PATCH] D40925: Add option -fkeep-static-consts

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: include/clang/Basic/LangOptions.def:311 +BENIGN_LANGOPT(KeepStaticConsts , 1, 0, "keep static const variables even if unused") + Let's make this a CodeGenOption, since only CodeGen needs to look at it. https://revi

[PATCH] D50932: [ASTImporter] Add test for C++ casts and fix broken const_cast importing.

2018-08-17 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor created this revision. Herald added a subscriber: martong. Herald added a reviewer: a.sidorin. Repository: rC Clang https://reviews.llvm.org/D50932 Files: lib/AST/ASTImporter.cpp test/Import/cxx-casts/Inputs/F.cpp test/Import/cxx-casts/test.cpp tools/clang-import-test/clang-i

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. Thanks, looks good! https://reviews.llvm.org/D50924 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

[PATCH] D41284: [Concepts] Associated constraints infrastructure.

2018-08-17 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: test/CXX/concepts-ts/temp/temp.constr/temp.constr.decl/var-template-decl.cpp:10 + +template requires bool(U()) +int B::A = int(U()); For my own edification, could you explain whether, given #define BOOL bool

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Looks ok to me. https://reviews.llvm.org/D50924 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. Talked to @ahatanak over IRC. It appears that this patch may have exposed a preexisting bug. Apparently `delete t;` in test/SemaCUDA/call-host-fn-from-device.cu does actually end up calling `__host__ operator delete`. It should've picked `__device__ operator delete`, but i

[PATCH] D41569: [Concepts] Constraint enforcement and diagnostics

2018-08-17 Thread Saar Raz via Phabricator via cfe-commits
saar.raz updated this revision to Diff 161348. saar.raz added a comment. - Adjusted to new CodeSynthesisContexts, added tests for them. Repository: rC Clang https://reviews.llvm.org/D41569 Files: include/clang/AST/ExprCXX.h include/clang/Basic/DiagnosticSemaKinds.td include/clang/Sema/

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Sanjay Patel via Phabricator via cfe-commits
spatel updated this revision to Diff 161346. spatel added a comment. Patch updated: Update the existing Microsoft rotate builtins to also use the LLVM funnel shift intrinsics. https://reviews.llvm.org/D50924 Files: docs/LanguageExtensions.rst include/clang/Basic/Builtins.def lib/CodeGen/

r340102 - [ObjC] Error out when using forward-declared protocol in a @protocol

2018-08-17 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Fri Aug 17 15:18:08 2018 New Revision: 340102 URL: http://llvm.org/viewvc/llvm-project?rev=340102&view=rev Log: [ObjC] Error out when using forward-declared protocol in a @protocol expression Clang emits invalid protocol metadata when a @protocol expression is used with a f

[PATCH] D49462: [ObjC] Error out when using forward-declared protocol in a @protocol expression

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL340102: [ObjC] Error out when using forward-declared protocol in a @protocol (authored by arphaman, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm

[PATCH] D41284: [Concepts] Associated constraints infrastructure.

2018-08-17 Thread Saar Raz via Phabricator via cfe-commits
saar.raz updated this revision to Diff 161345. saar.raz added a comment. - Fix bad reference to getRequiresClause on TemplateDecl in assertion Repository: rC Clang https://reviews.llvm.org/D41284 Files: include/clang/AST/DeclTemplate.h include/clang/AST/RecursiveASTVisitor.h include/cl

[PATCH] D50805: Don't warn on returning the address of a label from a statement expression

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340101: Don't warn on returning the address of a label from a statement expression (authored by rnk, committed by ). Changed prior to commit: https://reviews.llvm.org/D50805?vs=161148&id=161344#toc Rep

r340101 - Don't warn on returning the address of a label from a statement expression

2018-08-17 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Fri Aug 17 15:11:31 2018 New Revision: 340101 URL: http://llvm.org/viewvc/llvm-project?rev=340101&view=rev Log: Don't warn on returning the address of a label from a statement expression Summary: There isn't anything inherently wrong with returning a label from a statement expre

[PATCH] D41217: [Concepts] Concept Specialization Expressions

2018-08-17 Thread Saar Raz via Phabricator via cfe-commits
saar.raz updated this revision to Diff 161343. saar.raz added a comment. - Fix bad ArgsAsWritten assertion, add missing null initializer in ConceptSpecializationExpr. Repository: rC Clang https://reviews.llvm.org/D41217 Files: include/clang/AST/DeclTemplate.h include/clang/AST/ExprCXX.h

[PATCH] D50928: [ASTImporter] Test for importing condition variable from a ForStmt

2018-08-17 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor created this revision. Herald added a subscriber: martong. Herald added a reviewer: a.sidorin. Repository: rC Clang https://reviews.llvm.org/D50928 Files: test/Import/for-stmt/Inputs/F.cpp test/Import/for-stmt/test.cpp Index: test/Import/for-stmt/test.cpp ==

[PATCH] D50805: Don't warn on returning the address of a label from a statement expression

2018-08-17 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. Thank you for this! https://reviews.llvm.org/D50805 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50259: [OpenCL] Disallow negative attribute arguments

2018-08-17 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl accepted this revision. yaxunl added a comment. LGTM. Thanks. Repository: rC Clang https://reviews.llvm.org/D50259 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50879: [analyzer] [NFC] Minor refactoring of ISL-specific code in RetainCountChecker

2018-08-17 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340098: [analyzer] [NFC] Minor refactoring of ISL-specific code in RetainCountChecker (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: http

r340098 - [analyzer] [NFC] Minor refactoring of ISL-specific code in RetainCountChecker

2018-08-17 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Aug 17 14:43:27 2018 New Revision: 340098 URL: http://llvm.org/viewvc/llvm-project?rev=340098&view=rev Log: [analyzer] [NFC] Minor refactoring of ISL-specific code in RetainCountChecker Differential Revision: https://reviews.llvm.org/D50879 Modified: cfe/t

[PATCH] D50869: [analyzer] [NFC] Move ObjCRetainCount to include/Analysis

2018-08-17 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340096: [analyzer] [NFC] Move ObjCRetainCount to include/Analysis (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews.llvm.org

r340096 - [analyzer] [NFC] Move ObjCRetainCount to include/Analysis

2018-08-17 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Aug 17 14:42:32 2018 New Revision: 340096 URL: http://llvm.org/viewvc/llvm-project?rev=340096&view=rev Log: [analyzer] [NFC] Move ObjCRetainCount to include/Analysis Differential Revision: https://reviews.llvm.org/D50869 Added: cfe/trunk/include/clang/Analy

[PATCH] D50863: [analyzer] [NFC] Move canEval function from RetainCountChecker to RetainCountSummaries

2018-08-17 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340094: [analyzer] [NFC] Move canEval function from RetainCountChecker to… (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews

r340094 - [analyzer] [NFC] Move canEval function from RetainCountChecker to RetainCountSummaries

2018-08-17 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Aug 17 14:42:05 2018 New Revision: 340094 URL: http://llvm.org/viewvc/llvm-project?rev=340094&view=rev Log: [analyzer] [NFC] Move canEval function from RetainCountChecker to RetainCountSummaries Differential Revision: https://reviews.llvm.org/D50863 Modified:

[PATCH] D50830: [analyzer] [NFC] Split up summary generation in RetainCountChecker in two methods

2018-08-17 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340093: [analyzer] [NFC] Split up summary generation in RetainCountChecker in two… (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https:/

r340093 - [analyzer] [NFC] Split up summary generation in RetainCountChecker in two methods

2018-08-17 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Aug 17 14:41:37 2018 New Revision: 340093 URL: http://llvm.org/viewvc/llvm-project?rev=340093&view=rev Log: [analyzer] [NFC] Split up summary generation in RetainCountChecker in two methods Differential Revision: https://reviews.llvm.org/D50830 Modified:

[PATCH] D50927: [Sema] Remove location from implicit capture init expr

2018-08-17 Thread Vedant Kumar via Phabricator via cfe-commits
vsk created this revision. vsk added reviewers: rsmith, rtrieu, erichkeane. A lambda's closure is initialized when the lambda is declared. For implicit captures, the initialization code emitted from EmitLambdaExpr references source locations *within the lambda body* in the function containing the

[PATCH] D50814: [clangd] transfer the fixits with the notes instead of adding them to the main diagnostic if request by the client

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Our client has a presentation layer with a Clang-based hierarchical model for diagnostics, so we need the original notes. This is a hard requirement in that sense. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D50814 ___

[PATCH] D50740: [SourceManager] isPointWithin: avoid using isBeforeInTranslationUnit, compare buffer offsets directly for lexical correctness

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Hmm, after more analysis I realized that this is not the right solution for the rename problem. It would be correct to map one file:line:column location to a set of `SourceLocation`s, and to use the old `isPointWithin` on a set of such locations. I opened https://revie

[PATCH] D50509: [analyzer][UninitializedObjectChecker] Refactoring p6.: Move dereferencing to a function

2018-08-17 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp:223 + // int*). + while (auto Tmp = V.getAs()) { +// We can't reason about symbolic regions, assume its initialized. NoQ wrote: > Szelethu

[PATCH] D50926: [SourceManager] Extract 'findFileIDsForFile' from 'translateFile' to allow mapping from one file entry to multiple FileIDs

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: jkorous, ioeric. Herald added a subscriber: dexonsmith. This patch extracts the code that searches for a file id from `translateFile` to `findFileIDsForFile` to allow the users to map from one file entry to multiple FileIDs. Will be used

r340082 - test commit: add a comment

2018-08-17 Thread Mike Rice via cfe-commits
Author: mikerice Date: Fri Aug 17 14:16:21 2018 New Revision: 340082 URL: http://llvm.org/viewvc/llvm-project?rev=340082&view=rev Log: test commit: add a comment Modified: cfe/trunk/test/PCH/pch-through3c.cpp Modified: cfe/trunk/test/PCH/pch-through3c.cpp URL: http://llvm.org/viewvc/llvm-pr

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Sanjay Patel via Phabricator via cfe-commits
spatel added a comment. In https://reviews.llvm.org/D50924#1204772, @rnk wrote: > Do you mind updating the _rotl* and _rotr* intrinsics to use the same > codegen? They're right above in the switch. Sure - I didn't know about those. https://reviews.llvm.org/D50924 _

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Sanjay Patel via Phabricator via cfe-commits
spatel updated this revision to Diff 161325. spatel added a comment. Patch updated: Fixed a docs typo. https://reviews.llvm.org/D50924 Files: docs/LanguageExtensions.rst include/clang/Basic/Builtins.def lib/CodeGen/CGBuiltin.cpp test/CodeGen/builtin-rotate.c Index: test/CodeGen/builtin

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Do you mind updating the _rotl* and _rotr* intrinsics to use the same codegen? They're right above in the switch. https://reviews.llvm.org/D50924 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. The code you showed does compile with or without `-fcuda-is-device` after applying my patch. Repository: rC Clang https://reviews.llvm.org/D47757 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm

[PATCH] D50924: [CodeGen] add rotate builtins

2018-08-17 Thread Sanjay Patel via Phabricator via cfe-commits
spatel created this revision. spatel added reviewers: fabiang, craig.topper, rnk, thakis. Herald added a subscriber: mcrosier. This exposes the LLVM funnel shift intrinsics as more familiar bit rotation functions in clang (when both halves of a funnel shift are the same value, it's a rotate). I

r340080 - Update comments in CGDebugInfo to reflect changes in the MS mangler, NFC

2018-08-17 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Fri Aug 17 13:59:52 2018 New Revision: 340080 URL: http://llvm.org/viewvc/llvm-project?rev=340080&view=rev Log: Update comments in CGDebugInfo to reflect changes in the MS mangler, NFC I've tried to elaborate on the purpose of these type identifiers and why and when clang uses t

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340079: [MS] Mangle a hash of the main file path into anonymous namespaces (authored by rnk, committed by ). Changed prior to commit: https://reviews.llvm.org/D50877?vs=161310&id=161323#toc Repository:

r340079 - [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Fri Aug 17 13:59:27 2018 New Revision: 340079 URL: http://llvm.org/viewvc/llvm-project?rev=340079&view=rev Log: [MS] Mangle a hash of the main file path into anonymous namespaces Summary: This is needed to avoid conflicts in mangled names for codeview types in anonymous namespac

[PATCH] D50616: [Fixed Point Arithmetic] FixedPointCast

2018-08-17 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D50616#1203772, @lebedev.ri wrote: > In https://reviews.llvm.org/D50616#1203751, @rjmccall wrote: > > > In https://reviews.llvm.org/D50616#1203692, @ebevhan wrote: > > > > > > > > > > > Has anyone actually asked LLVM whether they would accept

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. In https://reviews.llvm.org/D50877#1204609, @thakis wrote: > Can you explicitly mention that this intentionally doesn't use an absolute > path in MicrosoftMangleContextImpl() or similar? Sure. I also described the issue with codeview that motivates why we want unique name

[PATCH] D40925: Add option -fkeep-static-consts

2018-08-17 Thread Elizabeth Andrews via Phabricator via cfe-commits
eandrews updated this revision to Diff 161307. eandrews edited the summary of this revision. eandrews added a comment. This patch fell through the cracks earlier. I apologize. Based on Reid's and Erich's feedback, I am now adding the variable to @llvm.used. Additionally I modified the if stateme

[PATCH] D50509: [analyzer][UninitializedObjectChecker] Refactoring p6.: Move dereferencing to a function

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp:223 + // int*). + while (auto Tmp = V.getAs()) { +// We can't reason about symbolic regions, assume its initialized. Szelethus wrote: > NoQ wrot

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk updated this revision to Diff 161310. rnk marked an inline comment as done. rnk added a comment. - improve comment https://reviews.llvm.org/D50877 Files: clang/lib/AST/MicrosoftMangle.cpp clang/test/CodeGenCXX/cfi-cross-dso.cpp clang/test/CodeGenCXX/cfi-icall.cpp clang/test/CodeGenC

[PATCH] D50509: [analyzer][UninitializedObjectChecker] Refactoring p6.: Move dereferencing to a function

2018-08-17 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp:223 + // int*). + while (auto Tmp = V.getAs()) { +// We can't reason about symbolic regions, assume its initialized. NoQ wrote: > Hmm, i s

[PATCH] D50862: [clang-tidy] Abseil: faster strsplit delimiter check

2018-08-17 Thread Deanna Garcia via Phabricator via cfe-commits
deannagarcia added inline comments. Comment at: clang-tidy/abseil/FasterStrsplitDelimiterCheck.cpp:49 + // in the character literal. + if (Result == R"("'")") { +return std::string(R"('\'')"); JonasToth wrote: > The comment suggest, that all single quotes n

[PATCH] D50862: [clang-tidy] Abseil: faster strsplit delimiter check

2018-08-17 Thread Deanna Garcia via Phabricator via cfe-commits
deannagarcia updated this revision to Diff 161309. deannagarcia marked 10 inline comments as done. https://reviews.llvm.org/D50862 Files: clang-tidy/abseil/AbseilTidyModule.cpp clang-tidy/abseil/CMakeLists.txt clang-tidy/abseil/FasterStrsplitDelimiterCheck.cpp clang-tidy/abseil/FasterStrs

[PATCH] D50488: [Analyzer] Checker for non-determinism caused by sorting of pointer-like keys

2018-08-17 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added inline comments. Comment at: lib/StaticAnalyzer/Checkers/PointerSortingChecker.cpp:72-76 + auto IteratesPointerKeysM = hasType(cxxRecordDecl(has( +fieldDecl(hasType(hasCanonicalType( + pointsTo(hasCano

[PATCH] D50616: [Fixed Point Arithmetic] FixedPointCast

2018-08-17 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. >> Has anyone actually asked LLVM whether they would accept fixed-point types >> into IR? I'm just a frontend guy, but it seems to me that there are >> advantages to directly representing these operations in a portable way even >> if there are no in-tree targets provi

[PATCH] D50488: [Analyzer] Checker for non-determinism caused by sorting of pointer-like keys

2018-08-17 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added a comment. In https://reviews.llvm.org/D50488#1203876, @Szelethus wrote: > I think testcases for non-class iterator objects would be valuable. Thanks @Szelethus. Yes, as you correctly pointed out this would not match non-class iterator objects. This is my first time with ASTMatch

[PATCH] D50413: [libunwind][include] Add some missing definitions to .

2018-08-17 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x added a comment. Ping. Repository: rUNW libunwind https://reviews.llvm.org/D50413 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50564: Add support for SEH unwinding on Windows.

2018-08-17 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x added a comment. Ping. Repository: rUNW libunwind https://reviews.llvm.org/D50564 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In https://reviews.llvm.org/D47757#1204621, @ahatanak wrote: > In https://reviews.llvm.org/D47757#1204561, @tra wrote: > > > It's a regression. There's a decent chance it breaks someone and this > > patch, if committed by itself, will end up being rolled back. > > > Is the r

[PATCH] D49462: [ObjC] Error out when using forward-declared protocol in a @protocol expression

2018-08-17 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. Comment at: lib/CodeGen/CGObjCMac.cpp:6788 + "emitting protocol metadata without definition"); + PD = PD->getDefinition(); arphaman wrot

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. In https://reviews.llvm.org/D47757#1204561, @tra wrote: > It's a regression. There's a decent chance it breaks someone and this patch, > if committed by itself, will end up being rolled back. Is the regression you are referring to about the static function case? I don

[PATCH] D50389: [clang-tidy] Abseil: integral division of Duration check

2018-08-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. In https://reviews.llvm.org/D50389#1204514, @Eugene.Zelenko wrote: > Somehow documentation file was not committed. Oops, I forgot to `git add` to the doc file. `arc patch` somehow failed to apply this patch, I applied it manually. Added in https://reviews.llvm.org/rL34

[PATCH] D49462: [ObjC] Error out when using forward-declared protocol in a @protocol expression

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: lib/CodeGen/CGObjCMac.cpp:6788 + "emitting protocol metadata without definition"); + PD = PD->getDefinition(); rjmccall wrote: > What happens in the `@implementation` case (the one that we're not diagnosing

[PATCH] D50904: [analyzer][UninitializedObjectChecker] Added documentation to the checker list

2018-08-17 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: www/analyzer/alpha_checks.html:334-336 +The checker regards inherited fields as direct fields, so one +will recieve warnings for uninitialized inherited data members +as well. NoQ wrote: > Szelethus wrote: > > This st

[clang-tools-extra] r340075 - [clang-tidy] Add missing check documentation.

2018-08-17 Thread Haojian Wu via cfe-commits
Author: hokein Date: Fri Aug 17 12:50:22 2018 New Revision: 340075 URL: http://llvm.org/viewvc/llvm-project?rev=340075&view=rev Log: [clang-tidy] Add missing check documentation. Added: clang-tools-extra/trunk/docs/clang-tidy/checks/abseil-duration-division.rst Added: clang-tools-extra/trun

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Nico Weber via Phabricator via cfe-commits
thakis accepted this revision. thakis added a comment. This revision is now accepted and ready to land. Can you explicitly mention that this intentionally doesn't use an absolute path in MicrosoftMangleContextImpl() or similar? https://reviews.llvm.org/D50877

r340074 - Improve diagnostic for missing comma in template parameter list.

2018-08-17 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri Aug 17 12:43:40 2018 New Revision: 340074 URL: http://llvm.org/viewvc/llvm-project?rev=340074&view=rev Log: Improve diagnostic for missing comma in template parameter list. Given 'typename T typename U', we would correctly diagnose the missing comma, but incorrectly disam

[PATCH] D41727: [libcxx] Disable tautological-type-limit-compare warning

2018-08-17 Thread Brian Cain via Phabricator via cfe-commits
bcain abandoned this revision. bcain added a comment. Herald added subscribers: ldionne, christof. I think this is now obsolete due to clang changing the warning. Repository: rCXX libc++ https://reviews.llvm.org/D41727 ___ cfe-commits mailing lis

[PATCH] D50616: [Fixed Point Arithmetic] FixedPointCast

2018-08-17 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. In https://reviews.llvm.org/D50616#1203692, @ebevhan wrote: > In https://reviews.llvm.org/D50616#1203446, @leonardchan wrote: > > > Sorry I forgot to address this also. Just to make sure I understand this > > correctly since I haven't used these before: target hooks

[PATCH] D50616: [Fixed Point Arithmetic] FixedPointCast

2018-08-17 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 161298. leonardchan marked 4 inline comments as done. Repository: rC Clang https://reviews.llvm.org/D50616 Files: include/clang/AST/OperationKinds.def include/clang/AST/Type.h include/clang/Basic/DiagnosticCommonKinds.td lib/AST/Expr.cpp lib/

[PATCH] D49462: [ObjC] Error out when using forward-declared protocol in a @protocol expression

2018-08-17 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGObjCMac.cpp:6788 + "emitting protocol metadata without definition"); + PD = PD->getDefinition(); What happens in the `@implementation` case (the one that we're not diagnosing yet) when the prot

[PATCH] D50509: [analyzer][UninitializedObjectChecker] Refactoring p6.: Move dereferencing to a function

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. Which shouldn't prevent us from moving code around. https://reviews.llvm.org/D50509 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50509: [analyzer][UninitializedObjectChecker] Refactoring p6.: Move dereferencing to a function

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp:223 + // int*). + while (auto Tmp = V.getAs()) { +// We can't reason about symbolic regions, assume its initialized. Hmm, i still have concerns

[PATCH] D50905: [analyzer][UninitializedObjectChecker][WIP] Explicit namespace resolution for inherited data members

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added inline comments. This revision is now accepted and ready to land. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedObjectChecker.cpp:114-115 + virtual void printNode(llvm::raw_ostream &Out) const override { +Out

[PATCH] D50904: [analyzer][UninitializedObjectChecker] Added documentation to the checker list

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added inline comments. This revision is now accepted and ready to land. Comment at: www/analyzer/alpha_checks.html:334-336 +The checker regards inherited fields as direct fields, so one +will recieve warnings for uninitialized inherited data member

[PATCH] D50896: [clangd] Add xrefs LSP boilerplate implementation.

2018-08-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. Agreed with Ilya. I'd probably also make this depend on the ongoing implementation, as exposing LSP endpoints without proper implementation might be confusing to clangd users who only look at the the LSP endpoints. Users need to dig two levels of abstraction to find out

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In https://reviews.llvm.org/D47757#1204545, @ahatanak wrote: > @tra and @rsmith: Can we move forward and fix the incorrect cuda diagnostics > in a separate patch? Doing that in a separate patch is OK, provided that that patch will be committed along with this one. It's a

[PATCH] D50892: [analyzer][UninitializedObjectChecker] Correct dynamic type is acquired for record pointees

2018-08-17 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp:187-191 // If FR is a pointer pointing to a non-primitive type. if (Optional RecordV = DerefdV.getAs()) { const TypedValueRegion *R = RecordV->

[PATCH] D50907: Make __shiftleft128 / __shiftright128 real compiler built-ins.

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. lgtm https://reviews.llvm.org/D50907 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-08-17 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. @tra and @rsmith: Can we move forward and fix the incorrect cuda diagnostics in a separate patch? Repository: rC Clang https://reviews.llvm.org/D47757 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk marked an inline comment as done. rnk added a comment. Exactly, this makes our names match MSVC more closely. Their hash depends on the path to the main source file. It doesn't care if the file is in a header. However, they use the absolute path to the file instead of the (probably relative

[PATCH] D50896: [clangd] Add xrefs LSP boilerplate implementation.

2018-08-17 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Having unimplemented stubs in the codebase creates some confusion, but that's my personal opinion. Not terribly opposed to that if others feel it's the right way to go. For experiments, we could simply patch this in locally without committing upstream. With git i

[PATCH] D50877: [MS] Mangle a hash of the main file path into anonymous namespaces

2018-08-17 Thread Reid Kleckner via Phabricator via cfe-commits
rnk updated this revision to Diff 161293. rnk added a comment. - Use xxHash64 https://reviews.llvm.org/D50877 Files: clang/lib/AST/MicrosoftMangle.cpp clang/test/CodeGenCXX/cfi-cross-dso.cpp clang/test/CodeGenCXX/cfi-icall.cpp clang/test/CodeGenCXX/debug-info-thunk.cpp clang/test/Code

[PATCH] D50876: Clean up newly created header

2018-08-17 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. In https://reviews.llvm.org/D50876#1204531, @mclow.lists wrote: > @craig.topper - that's existing code; I'm not changing it. > If we have a test bot that I can test this against, I'm happy to update it. I'm not really sure that this code is actually used anywhere.

[PATCH] D49462: [ObjC] Error out when using forward-declared protocol in a @protocol expression

2018-08-17 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: test/CodeGenObjC/forward-declare-protocol-gnu.m:6 -Protocol *getProtocol(void) -{ - return @protocol(P); -} +@interface I +@end rjmccall wrote: > arphaman wrote: > > rjmccall wrote: > > > Does this real

[PATCH] D50876: Clean up newly created header

2018-08-17 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. @craig.topper - that's existing code; I'm not changing it. If we have a test bot that I can test this against, I'm happy to update it. https://reviews.llvm.org/D50876 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[PATCH] D50389: [clang-tidy] Abseil: integral division of Duration check

2018-08-17 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Somehow documentation file was not committed. https://reviews.llvm.org/D50389 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50896: [clangd] Add xrefs LSP boilerplate implementation.

2018-08-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. In https://reviews.llvm.org/D50896#1204310, @ilya-biryukov wrote: > This change LG, but I would not commit it before we have an actual > implementation. > As soon as we have the `references` function in `ClangdUnit.cpp` > implemented, the merge of this change should be

[PATCH] D50596: [HIP] Make __hip_gpubin_handle hidden to avoid being merged across different shared libraries

2018-08-17 Thread Yaxun Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC340056: [HIP] Make __hip_gpubin_handle hidden to avoid being merged across different… (authored by yaxunl, committed by ). Repository: rC Clang https://reviews.llvm.org/D50596 Files: lib/CodeGen/CGC

r340056 - [HIP] Make __hip_gpubin_handle hidden to avoid being merged across different shared libraries

2018-08-17 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Fri Aug 17 10:47:31 2018 New Revision: 340056 URL: http://llvm.org/viewvc/llvm-project?rev=340056&view=rev Log: [HIP] Make __hip_gpubin_handle hidden to avoid being merged across different shared libraries Different shared libraries contain different fat binary, which is sto

[PATCH] D50747: [analyzer] Drop support for GC mode in RetainCountChecker

2018-08-17 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. Yay. Repository: rC Clang https://reviews.llvm.org/D50747 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mail

[PATCH] D50876: Clean up newly created header

2018-08-17 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: include/bit:140 static_assert(sizeof(unsigned) == 4, ""); return __popcnt(__x); } MSVC blindly uses the popcnt instruction whenever it sees this intrinsic. So this only works on Nehalem and newer Intel CPUs.

[libcxx] r340049 - Refactor the newly created header. Still (almost) NFC. Reviewed as https://reviews.llvm.org/D50876

2018-08-17 Thread Marshall Clow via cfe-commits
Author: marshall Date: Fri Aug 17 10:27:25 2018 New Revision: 340049 URL: http://llvm.org/viewvc/llvm-project?rev=340049&view=rev Log: Refactor the newly created header. Still (almost) NFC. Reviewed as https://reviews.llvm.org/D50876 Modified: libcxx/trunk/include/__bit_reference libcxx

[PATCH] D50876: Clean up newly created header

2018-08-17 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added inline comments. Comment at: include/bit:96 #if defined(_LIBCPP_HAS_BITSCAN64) (defined(_M_AMD64) || defined(__x86_64__)) + if (_BitScanForward64(&__where, __x)) I'm not sure this code is ever used - since how can this compile? https://

[PATCH] D50876: Clean up newly created header

2018-08-17 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists updated this revision to Diff 161284. mclow.lists added a comment. Clean up the windows code a bit - though I don't think is used - since I don't think it will compile. https://reviews.llvm.org/D50876 Files: include/__bit_reference include/bit Index: include/bit ==

[PATCH] D50907: Make __shiftleft128 / __shiftright128 real compiler built-ins.

2018-08-17 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. r340048, thanks! https://reviews.llvm.org/D50907 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r340048 - Make __shiftleft128 / __shiftright128 real compiler built-ins.

2018-08-17 Thread Nico Weber via cfe-commits
Author: nico Date: Fri Aug 17 10:19:06 2018 New Revision: 340048 URL: http://llvm.org/viewvc/llvm-project?rev=340048&view=rev Log: Make __shiftleft128 / __shiftright128 real compiler built-ins. r337619 added __shiftleft128 / __shiftright128 as functions in intrin.h. Microsoft's STL plans on using

[PATCH] D50907: Make __shiftleft128 / __shiftright128 real compiler built-ins.

2018-08-17 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 https://reviews.llvm.org/D50907 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/li

  1   2   3   >