[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Parse/ParseTentative.cpp:2130 + ParsedAttributesWithRange attrs(AttrFactory); + ParseGNUAttributes(attrs, nullptr, nullptr); + if (attrs.size() <= 0) { It's not correct in general to call arbitrary parsing ac

[PATCH] D64850: Remove use of malloc in PPC mm_malloc.

2019-07-16 Thread Chaofan Qiu via Phabricator via cfe-commits
qiucf created this revision. qiucf added reviewers: hubert.reinterpretcast, jsji, wschmidt, nemanjai, kbarton. qiucf added a project: clang. Herald added a subscriber: cfe-commits. Remove dependency of `malloc` in implementation of `mm_malloc` function and alignment assumption on glibc. Reposi

[PATCH] D64849: Add platform guards to PPC vector intrinsics headers.

2019-07-16 Thread Chaofan Qiu via Phabricator via cfe-commits
qiucf created this revision. qiucf added reviewers: jsji, hfinkel, nemanjai, wschmidt, kbarton, hubert.reinterpretcast. qiucf added a project: clang. Herald added subscribers: cfe-commits, MaskRay, krytarowski. Intrinsic headers are supported only on 64-bit PowerPC. This patch is to move the pla

[PATCH] D64695: [clang-format] Added new style rule: SortNetBSDIncludes

2019-07-16 Thread Manikishan Ghantasala via Phabricator via cfe-commits
Manikishan added a comment. In the following patch I have modified Include categories by adding a new field "sortInlcudes" which defines the priority of the sort. And priority field will now only be used for grouping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D64799: [Sema] Emit diagnostics for uncorrected delayed typos at the end of TU

2019-07-16 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: clang/test/SemaObjC/typo-correction-subscript.m:1 // RUN: %clang_cc1 -triple i386-apple-macosx10.10 -fobjc-arc -fsyntax-only -Wno-objc-root-class %s -verify -disable-free I think you can even remove `-disable-free` i

[PATCH] D64843: hwasan: Initialize the pass only once.

2019-07-16 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc created this revision. pcc added a reviewer: eugenis. Herald added subscribers: cfe-commits, hiraditya. Herald added projects: clang, LLVM. This will let us instrument globals during initialization. This required making the new PM pass a module pass, which should still provide access to analys

[PATCH] D64842: [OPENMP] Fix crash in LoopCounterRefChecker when MemberExpr is not Var or Field

2019-07-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64842/new/ https://reviews.llvm.org/D64842 ___ cfe-commits mailing list cfe-commits@l

[PATCH] D64842: [OPENMP] Fix crash in LoopCounterRefChecker when MemberExpr is not Var or Field

2019-07-16 Thread Mike Rice via Phabricator via cfe-commits
mikerice created this revision. mikerice added reviewers: ABataev, cfe-commits. Herald added a subscriber: guansong. checkDecl is only valid for VarDecls or FieldDecls, since getCanonicalDecl expects only these. Prevent other Decl kinds (such as CXXMethodDecls and EnumConstantDecls) from enteri

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
quantum added a comment. In D64537#1588699 , @dschuff wrote: > I had a reply that got eaten here, so I'm going to keep trolling you on your > CL since we don't have a design doc for this. > The `offset` field of a data segment initializer can be a `globa

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Derek Schuff via Phabricator via cfe-commits
dschuff added a comment. I had a reply that got eaten here, so I'm going to keep trolling you on your CL since we don't have a design doc for this. The `offset` field of a data segment initializer can be a `global.get` on an imported global. (https://webassembly.github.io/spec/core/valid/instr

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added inline comments. Comment at: clang/lib/Parse/ParseStmt.cpp:104 + + if (isNullStmtWithAttributes()) { +MaybeParseGNUAttributes(Attrs); If we're going to generally support statement attributes, it should be possible to apply them to non-null st

[PATCH] D64828: AMDGPU: Add some missing builtins

2019-07-16 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm closed this revision. arsenm added a comment. r366286 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64828/new/ https://reviews.llvm.org/D64828 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mai

r366286 - AMDGPU: Add some missing builtins

2019-07-16 Thread Matt Arsenault via cfe-commits
Author: arsenm Date: Tue Jul 16 17:01:03 2019 New Revision: 366286 URL: http://llvm.org/viewvc/llvm-project?rev=366286&view=rev Log: AMDGPU: Add some missing builtins Added: cfe/trunk/test/CodeGenOpenCL/builtins-amdgcn-gfx10.cl cfe/trunk/test/SemaOpenCL/builtins-amdgcn-error-gfx10-param.c

[PATCH] D41412: [libcxx] implement concat() and split()

2019-07-16 Thread Tim Shen via Phabricator via cfe-commits
timshen added a comment. In D41412#1586966 , @grosser wrote: > Hi @timshen, > > I am very interested in these patches. Any chance you can take up the > upstreaming process again? I'm glad to spend time upstreaming these patches. Now we just need a libc+

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/Parse/ParseTentative.cpp:2146 +bool Parser::isNullStmtWithAttributes() { + RevertingTentativeParsingAction PA(*this); + return TryParseNullStmtWithAttributes() == TPResult::True; Is this “cheap” in terms of

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Thanks, I think this is fine solution for now. Probably not ideal (@aaron.ballman mentioned the ideal solution - rewrite the parser), but “suboptimal” parser should not stop any progress in this area. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

r366284 - Fix OpenCLCXX test on 32-bit Windows where thiscall is present

2019-07-16 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Jul 16 16:44:33 2019 New Revision: 366284 URL: http://llvm.org/viewvc/llvm-project?rev=366284&view=rev Log: Fix OpenCLCXX test on 32-bit Windows where thiscall is present Modified: cfe/trunk/test/SemaOpenCLCXX/address-space-deduction.cl Modified: cfe/trunk/test/SemaOpen

r366282 - Fix darwin-ld.c if dsymutil.exe exists on PATH

2019-07-16 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Jul 16 16:38:05 2019 New Revision: 366282 URL: http://llvm.org/viewvc/llvm-project?rev=366282&view=rev Log: Fix darwin-ld.c if dsymutil.exe exists on PATH Modified: cfe/trunk/test/Driver/darwin-ld.c Modified: cfe/trunk/test/Driver/darwin-ld.c URL: http://llvm.org/viewv

[PATCH] D64695: [clang-format] Added new style rule: SortNetBSDIncludes

2019-07-16 Thread Manikishan Ghantasala via Phabricator via cfe-commits
Manikishan updated this revision to Diff 210218. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64695/new/ https://reviews.llvm.org/D64695 Files: include/clang/Tooling/Inclusions/HeaderIncludes.h include/clang/Tooling/Inclusions/IncludeStyle.h lib/Format/Form

[PATCH] D64828: AMDGPU: Add some missing builtins

2019-07-16 Thread Stanislav Mekhanoshin via Phabricator via cfe-commits
rampitec accepted this revision. rampitec added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64828/new/ https://reviews.llvm.org/D64828 ___ cfe-commits mailing list cfe-commi

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/Parse/ParseTentative.cpp:2131 + ParseGNUAttributes(attrs, nullptr, nullptr); + if (attrs.size() <= 0) { +return TPResult::False; Negative size() ? Did you mean “== 0”? Not sure if “empty()” exists ther

[PATCH] D64828: AMDGPU: Add some missing builtins

2019-07-16 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm updated this revision to Diff 210216. arsenm added a comment. Drop one and fix missing test CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64828/new/ https://reviews.llvm.org/D64828 Files: include/clang/Basic/BuiltinsAMDGPU.def lib/CodeGen/CGBuiltin.cpp test/CodeGenOpenCL/b

[PATCH] D64274: [analyzer] VirtualCallChecker overhaul.

2019-07-16 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D64274#1584974 , @baloghadamsoftware wrote: > Hmm, I still fail to understand the problem with the current `VirtualCall` > checker. Is it unstable? Does it report many false positives? Yeah, pretty much. It's basically defined t

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry added a comment. Revival of https://reviews.llvm.org/D63260 and https://reviews.llvm.org/D63299. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64838/new/ https://reviews.llvm.org/D64838

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry updated this revision to Diff 210215. Nathan-Huckleberry added a comment. - Fixed formatting Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64838/new/ https://reviews.llvm.org/D64838 Files: clang/include/clang/Basic/Attr.td c

[PATCH] D64838: [Attr] Support _attribute__ ((fallthrough))

2019-07-16 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Fixed extraneous matches of non-NullStmt Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D64838 Files: clang/include/clang/Basic/Attr.td clang/include/clang/Parse

[PATCH] D64799: [Sema] Emit diagnostics for uncorrected delayed typos at the end of TU

2019-07-16 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. I'm in favor of this as is. We should loop in and get confirmation from @rsmith though. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64799/new/ https://reviews.llvm.org/D64799 __

r366276 - Fix a typo in target features

2019-07-16 Thread George Burgess IV via cfe-commits
Author: gbiv Date: Tue Jul 16 15:32:17 2019 New Revision: 366276 URL: http://llvm.org/viewvc/llvm-project?rev=366276&view=rev Log: Fix a typo in target features There was a slight typo in r364352 that ended up causing our backend to complain on some x86 Android builds. This CL fixes that. Differ

[PATCH] D64491: [Driver] Enable __cxa_atexit on Solaris

2019-07-16 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. lgtm Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64491/new/ https://reviews.llvm.org/D64491 ___ cfe-commits mailing

[PATCH] D64828: AMDGPU: Add some missing builtins

2019-07-16 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm created this revision. arsenm added reviewers: rampitec, yaxunl, kzhuravl, b-sumner. Herald added subscribers: t-tye, tpr, dstuttard, nhaehnle, wdng, jvesely. https://reviews.llvm.org/D64828 Files: include/clang/Basic/BuiltinsAMDGPU.def lib/CodeGen/CGBuiltin.cpp test/CodeGenOpenCL/bu

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
quantum updated this revision to Diff 210188. quantum added a comment. Disable atomics when TLS is stripped Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64537/new/ https://reviews.llvm.org/D64537 Files: clang/include/clang/Basic/BuiltinsWebAsse

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Thomas Lively via Phabricator via cfe-commits
tlively accepted this revision. tlively added a comment. Nice work! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64537/new/ https://reviews.llvm.org/D64537 ___ cfe-commits mailing list cfe-commits@lis

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL366272: [WebAssembly] Implement thread-local storage (local-exec model) (authored by quantum, committed by ). Changed prior to commit: https://reviews.llvm.org/D64537?vs=210188&id=210191#toc Repository

r366272 - [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via cfe-commits
Author: quantum Date: Tue Jul 16 15:00:45 2019 New Revision: 366272 URL: http://llvm.org/viewvc/llvm-project?rev=366272&view=rev Log: [WebAssembly] Implement thread-local storage (local-exec model) Summary: Thread local variables are placed inside a `.tdata` segment. Their symbols are offsets fro

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
quantum updated this revision to Diff 210187. quantum added a comment. Remove extra braces Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64537/new/ https://reviews.llvm.org/D64537 Files: clang/include/clang/Basic/BuiltinsWebAssembly.def clang/

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
quantum updated this revision to Diff 210184. quantum added a comment. Removed the trailing `.`. I would add a test to make sure things work without `-fdata-sections`, but `this->Options.DataSections = true;` is hard-coded in `WebAssemblyTargetMachine.cpp`. Repository: rG LLVM Github Monorep

[PATCH] D64632: [clang-format] Don't detect call to ObjC class method as C++11 attribute specifier

2019-07-16 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton added a comment. Submitted as r366267. Thanks! Comment at: clang/lib/Format/TokenAnnotator.cpp:389 bool isCpp11AttributeSpecifier(const FormatToken &Tok) { if (!Style.isCpp() || !Tok.startsSequence(tok::l_square, tok::l_square)) return false;

[PATCH] D64632: [clang-format] Don't detect call to ObjC class method as C++11 attribute specifier

2019-07-16 Thread Ben Hamilton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL366267: [clang-format] Don't detect call to ObjC class method as C++11 attribute… (authored by benhamilton, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed p

[PATCH] D64671: [clang-tidy] New check: misc-init-local-variables

2019-07-16 Thread Jussi Pakkanen via Phabricator via cfe-commits
jpakkane marked an inline comment as done. jpakkane added inline comments. Comment at: clang-tools-extra/clang-tidy/misc/InitLocalVariablesCheck.cpp:21 + Finder->addMatcher( + varDecl(unless(hasInitializer(anything(.bind("vardecl"), this); +} alexfh wro

r366267 - [clang-format] Don't detect call to ObjC class method as C++11 attribute specifier

2019-07-16 Thread Ben Hamilton via cfe-commits
Author: benhamilton Date: Tue Jul 16 14:29:40 2019 New Revision: 366267 URL: http://llvm.org/viewvc/llvm-project?rev=366267&view=rev Log: [clang-format] Don't detect call to ObjC class method as C++11 attribute specifier Summary: Previously, clang-format detected something like the following as

[PATCH] D64820: Avoids an assertion failure when an invalid conversion declaration is used

2019-07-16 Thread Mark de Wever via Phabricator via cfe-commits
Mordante created this revision. Mordante added a reviewer: rsmith. Mordante added a project: clang. When using a user-defined conversion function template with a deduced return type the compiler gives a set of warnings: bug.cc:252:44: error: cannot specify any part of a return type in the dec

[PATCH] D61749: [clang-tidy] initial version of readability-convert-member-functions-to-static

2019-07-16 Thread Matthias Gehre via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL366265: [clang-tidy] initial version of readability-convert-member-functions-to-static (authored by mgehre, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed

[PATCH] D61749: [clang-tidy] initial version of readability-convert-member-functions-to-static

2019-07-16 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added a comment. Thank you for the review, Aaron! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61749/new/ https://reviews.llvm.org/D61749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang-tools-extra] r366265 - [clang-tidy] initial version of readability-convert-member-functions-to-static

2019-07-16 Thread Matthias Gehre via cfe-commits
Author: mgehre Date: Tue Jul 16 14:19:00 2019 New Revision: 366265 URL: http://llvm.org/viewvc/llvm-project?rev=366265&view=rev Log: [clang-tidy] initial version of readability-convert-member-functions-to-static Summary: Finds non-static member functions that can be made ``static``. I have run t

Re: r366123 - ARM MTE stack sanitizer.

2019-07-16 Thread Evgenii Stepanov via cfe-commits
I could not reproduce this on Linux nor on Mac. I wonder if triggering a clean build would help? I don't see a way to do that though. On Tue, Jul 16, 2019 at 10:50 AM Evgenii Stepanov wrote: > > Hi, > > thanks for letting me know! Is this reproducible on Linux? It is > possible to extract a repro

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 accepted this revision. sbc100 added inline comments. This revision is now accepted and ready to land. Comment at: lld/wasm/Writer.cpp:400 + StringRef name = segment->getName(); + if (name.startswith(".tdata.") || name.startswith(".tbss.")) +tlsUsed = tru

[PATCH] D61879: WIP: Prototype of DSE optimizations for -ftrivial-auto-var-init

2019-07-16 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka marked an inline comment as done. vitalybuka added inline comments. Comment at: llvm/lib/Transforms/Scalar/DeadStoreEliminationExpGlobal.cpp:27 +static const char GlobalArgumentMemAccess[] = { +// grep -P -o "(?<=FUNCTION_INFO: ).*" | sort -u > +// ../llvm-project/ll

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Guanzhong Chen via Phabricator via cfe-commits
quantum updated this revision to Diff 210166. quantum added a comment. More fine-grainted stripping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64537/new/ https://reviews.llvm.org/D64537 Files: clang/include/clang/Basic/BuiltinsWebAssembly.de

[PATCH] D64780: Disallow most calling convention attributes on PS4.

2019-07-16 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Some suggestions, you don't have to take all of them. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:2961 +def error_cconv_unsupported : Error< + "%0 calling convention not supported %select{" + // Use CallingConventionIgnoredReason Enum to specif

[PATCH] D64380: Add 'require_designated_init' and 'required' attribute to clang

2019-07-16 Thread Emmett Neyman via Phabricator via cfe-commits
emmettneyman planned changes to this revision. emmettneyman added a comment. Changes planned: - Move diagnostics into a diagnostic group. - Add behavior and test cases for private members of structs/classes. - Investigate behavior of GCC `designated_init` attribute Repository: rG LLVM Github

[PATCH] D64482: [Driver] Define _FILE_OFFSET_BITS=64 on Solaris

2019-07-16 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. > To avoid a similar inconsistence with host compilers that don't predefine > _FILE_OFFSET_BITS=64 > (e.g. clang < 9, gcc < 9), this needs a compantion patch to be submitted > shortly. I'm curious

[PATCH] D64537: [WebAssembly] Implement thread-local storage (local-exec model)

2019-07-16 Thread Thomas Lively via Phabricator via cfe-commits
tlively added a comment. LGTM apart from one last comment Comment at: llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp:193 + +if (!Features[WebAssembly::FeatureBulkMemory]) Stripped |= stripThreadLocals(M); quantum wrote: > tlively wrote: > >

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-07-16 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added inline comments. Comment at: clang/test/Frontend/rewrite-includes-conditions.c:17 +line4 +#elif value2 < value2 +line5 rsmith wrote: > Did you mean for this to be `value1 < value2` rather than `value2 < value2`? Yes, not that it'd matter in practice.

[PATCH] D64518: [LibTooling] Relax Transformer to allow rewriting macro expansions

2019-07-16 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 210148. ymandel added a comment. tweaks in response to comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64518/new/ https://reviews.llvm.org/D64518 Files: clang/lib/Tooling/Refactoring/Transformer.cpp

[PATCH] D64518: [LibTooling] Relax Transformer to allow rewriting macro expansions

2019-07-16 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel marked 2 inline comments as done. ymandel added a comment. In D64518#1585917 , @ilya-biryukov wrote: > This clearly increases the utility of the library, but also seems to add > corner cases that the library won't handle (see the comment about un

[PATCH] D64780: Disallow most calling convention attributes on PS4.

2019-07-16 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. I'm fine with the idea of targets making unsupported CCs hard errors. Comment at: test/Sema/no_callconv.cpp:44 +void __attribute__((sysv_abi)) funcI() {} +void __attribute__((cdecl)) funcC() {} Please include a newline at the end of th

[PATCH] D64804: [OpenCL][Sema] Minor refactoring and constraint checking

2019-07-16 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. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64804/new/ https://reviews.llvm.org/D64804

[PATCH] D64644: Fixes an assertion failure while instantiation a template with an incomplete typo corrected type

2019-07-16 Thread Mark de Wever via Phabricator via cfe-commits
Mordante updated this revision to Diff 210146. Mordante added a comment. Remove the includes from the test. Changed the `std::is_constructible` to `is_same` since the latter is easier to mock. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64644/new/ https://reviews.llvm.org/D64644 Fil

[PATCH] D64736: [clang-tidy] New bugprone-infinite-loop check for detecting obvious infinite loops

2019-07-16 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added reviewers: JonasToth, gribozavr. lebedev.ri added a comment. Thanks. Are there any tests missing for `volatile`, atomics? I'm not really current on clang-tidy state of affairs, so i'm gonna leave most of the review for others.. Comment at: clang-tidy/bugprone/

Re: r366076 - fix unnamed fiefield issue and add tests for __builtin_preserve_access_index intrinsic

2019-07-16 Thread Yonghong Song via cfe-commits
On 7/16/19 11:03 AM, Nick Desaulniers wrote: > On Tue, Jul 16, 2019 at 11:02 AM Nick Desaulniers > wrote: >> >> On Mon, Jul 15, 2019 at 5:13 PM Eric Christopher wrote: >>> >>> I'm going to cheat and make Nick do it :) >> >> I suspect that Eric still compiles LLVM by specifying all object files

[PATCH] D48680: Add missing visibility annotation for __base

2019-07-16 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added a comment. In D48680#1587967 , @ldionne wrote: > @pcc In your reproducer, what is `~/l3/ra-cmake/bin/clang++`? That's just clang built from trunk at the time that I posted my comment. > Are you able to reproduce without `-fuse-ld=lld`? I'm try

Re: r366076 - fix unnamed fiefield issue and add tests for __builtin_preserve_access_index intrinsic

2019-07-16 Thread Nick Desaulniers via cfe-commits
On Tue, Jul 16, 2019 at 11:02 AM Nick Desaulniers wrote: > > On Mon, Jul 15, 2019 at 5:13 PM Eric Christopher wrote: > > > > I'm going to cheat and make Nick do it :) > > I suspect that Eric still compiles LLVM by specifying all object files > in order on the command line and doesn't want to talk

Re: r366076 - fix unnamed fiefield issue and add tests for __builtin_preserve_access_index intrinsic

2019-07-16 Thread Nick Desaulniers via cfe-commits
On Mon, Jul 15, 2019 at 5:13 PM Eric Christopher wrote: > > I'm going to cheat and make Nick do it :) I suspect that Eric still compiles LLVM by specifying all object files in order on the command line and doesn't want to talk about it on cfe-commits. :) Though, even I'm behind the times as I thi

[PATCH] D64811: Warn when NumParams overflows

2019-07-16 Thread Mark de Wever via Phabricator via cfe-commits
Mordante created this revision. Mordante added reviewers: rsmith, rjmccall. Mordante added a project: clang. Before when the overflow occurred an assertion was triggered. Now check whether the maximum has been reached and warn properly. This patch fixes bug 33162 which is marked as 'duplicate' o

[PATCH] D48680: Add missing visibility annotation for __base

2019-07-16 Thread Louis Dionne via Phabricator via cfe-commits
ldionne requested changes to this revision. ldionne added a comment. This revision now requires changes to proceed. Herald added a subscriber: dexonsmith. @pcc In your reproducer, what is `~/l3/ra-cmake/bin/clang++`? Are you able to reproduce without `-fuse-ld=lld`? I'm trying to reproduce locall

[PATCH] D48680: Add missing visibility annotation for __base

2019-07-16 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added a comment. I think it would be up to the libc++ maintainers to approve the patch. Repository: rCXX libc++ CHANGES SINCE LAST ACTION https://reviews.llvm.org/D48680/new/ https://reviews.llvm.org/D48680 ___ cfe-commits mailing list cfe

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-16 Thread Steve Canon via Phabricator via cfe-commits
scanon accepted this revision. scanon added a comment. This revision is now accepted and ready to land. LGTM. Please get at least one additional reviewer's approval before merging, as this is a corner of clang that I don't work on often. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D646

Re: r366123 - ARM MTE stack sanitizer.

2019-07-16 Thread Evgenii Stepanov via cfe-commits
Hi, thanks for letting me know! Is this reproducible on Linux? It is possible to extract a reproducer from the bot? On Mon, Jul 15, 2019 at 9:30 PM Amara Emerson wrote: > > Hi Evgeniy, > > This commit looks like it broke the lldb bot: > http://green.lab.llvm.org/green/job/lldb-cmake/31011/ > >

[PATCH] D48680: Add missing visibility annotation for __base

2019-07-16 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta added a comment. @pcc can you please submit this patch if there are no objections? Repository: rCXX libc++ CHANGES SINCE LAST ACTION https://reviews.llvm.org/D48680/new/ https://reviews.llvm.org/D48680 ___ cfe-commits mailing list c

[PATCH] D64569: [OpenCL] Improve destructor support in C++ for OpenCL

2019-07-16 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/CodeGen/CGClass.cpp:2016 CGF.EmitCXXDestructorCall(dtor, Dtor_Complete, /*for vbase*/ false, -/*Delegating=*/false, addr); +/*Delegating=*/false, addr, type); } -

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-16 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan marked an inline comment as done. ziangwan added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:11429 + S.Context.getFloatTypeSemantics(QualType(TargetBT, 0))); +TargetFloatValue.convertFromAPInt(SourceInt, + SourceBT->isSignedInte

[PATCH] D64089: [Driver] Introduce -stdlib++-isystem

2019-07-16 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:1307 + HasStdlibxxIsystem ? TC.AddClangCXXStdlibIsystemArgs(Args, CmdArgs) + : TC.AddClangCXXStdlibIncludeArgs(Args, CmdArgs); +}); So, b

Re: r365825 - [clang-shlib] Fix clang-shlib for PRIVATE dependencies

2019-07-16 Thread Shoaib Meenai via cfe-commits
Makes sense, thanks. Seems like INTERFACE is the way to go then. From: on behalf of Chris Bieneman Date: Tuesday, July 16, 2019 at 10:32 AM To: Shoaib Meenai Cc: Alex Bradbury , cfe-commits Subject: Re: r365825 - [clang-shlib] Fix clang-shlib for PRIVATE dependencies I get that CMake does som

Re: r365825 - [clang-shlib] Fix clang-shlib for PRIVATE dependencies

2019-07-16 Thread Chris Bieneman via cfe-commits
I get that CMake does something different for PRIVATE, but the way we use CMake in LLVM we really can't make a private distinction reasonable. Because we don't sub-divide our headers per library, we don't support per-dependency include paths in LLVM or Clang's libraries. This behavior also assu

[PATCH] D62584: [OpenCL][PR42033] Deducing addr space with template parameter types

2019-07-16 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Minor comment then LGTM Comment at: lib/Sema/SemaType.cpp:7418 + // Expect for pointer or reference types because the addr space in + // template argument can only belong to a pointee. + (T->isDependentType() && !T->isPointerType() && !T

r366231 - fix unnamed fiefield issue and add tests for __builtin_preserve_access_index intrinsic

2019-07-16 Thread Yonghong Song via cfe-commits
Author: yhs Date: Tue Jul 16 10:24:33 2019 New Revision: 366231 URL: http://llvm.org/viewvc/llvm-project?rev=366231&view=rev Log: fix unnamed fiefield issue and add tests for __builtin_preserve_access_index intrinsic The original commit is r366076. It is temporarily reverted (r366155) due to tes

[PATCH] D64644: Fixes an assertion failure while instantiation a template with an incomplete typo corrected type

2019-07-16 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang/test/SemaTemplate/instantiate-incomplete-typo-suggested-error-limit.cpp:9-10 + +#include +#include + Please don't pull in any external headers - just mock what you need. CHANGES SINCE LAST ACTION https://

[PATCH] D64644: Fixes an assertion failure while instantiation a template with an incomplete typo corrected type

2019-07-16 Thread Mark de Wever via Phabricator via cfe-commits
Mordante updated this revision to Diff 210128. Mordante marked an inline comment as done. Mordante retitled this revision from "Fixes a clang frontend assertion failure (bug 35682)" to "Fixes an assertion failure while instantiation a template with an incomplete typo corrected type". Mordante edi

[PATCH] D63648: [Preprocessor] Honor absolute paths in diagnostics

2019-07-16 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea added a comment. Ping! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63648/new/ https://reviews.llvm.org/D63648 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D64804: [OpenCL][Sema] Minor refactoring and constraint checking

2019-07-16 Thread Marco Antognini via Phabricator via cfe-commits
mantognini added reviewers: Anastasia, rjmccall. mantognini added a comment. This should address the minor refactoring requesting in D64083 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64804/new/ https://reviews

[PATCH] D64804: [OpenCL][Sema] Minor refactoring and constraint checking

2019-07-16 Thread Marco Antognini via Phabricator via cfe-commits
mantognini created this revision. Herald added subscribers: cfe-commits, Anastasia, yaxunl. Herald added a project: clang. Simplify code a bit and add assertion to address post-landing comments from D64083 . Repository: rG LLVM Github Monorepo https://reviews.

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

2019-07-16 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. In D61634#1586047 , @tejohnson wrote: > Checking in to see where we are on this issue. I haven't had any time to work > on 4 but hopefully can start on that soon. But it needs the first part done > to be effective. Thx for th

[PATCH] D64801: [analyzer] Add CTU user docs

2019-07-16 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: dkrupp, a_sidorin, Szelethus, NoQ. Herald added subscribers: cfe-commits, Charusso, gamesh411, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun, whisperity. Herald added a project: clang. Repository:

[PATCH] D64799: [Sema] Emit diagnostics for uncorrected delayed typos at the end of TU

2019-07-16 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 210105. ilya-biryukov added a comment. Fix a typo (xD) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64799/new/ https://reviews.llvm.org/D64799 Files: clang/lib/Sema/Sema.cpp clang/test/SemaObjC/typo

[PATCH] D64418: [Docs][OpenCL] Documentation of C++ for OpenCL mode

2019-07-16 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia updated this revision to Diff 210101. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64418/new/ https://reviews.llvm.org/D64418 Files: docs/LanguageExtensions.rst docs/UsersManual.rst Index: docs/UsersManual.rst ==

[PATCH] D64765: [OPENMP]Add support for analysis of firstprivate variables.

2019-07-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 210100. ABataev added a comment. Rebase Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64765/new/ https://reviews.llvm.org/D64765 Files: include/clang/AST/OpenMPClause.h test/Analysis/cfg-openmp.cpp test/OpenMP/distribu

[PATCH] D64799: [Sema] Emit diagnostics for uncorrected delayed typos at the end of TU

2019-07-16 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added reviewers: rnk, sammccall. Herald added a subscriber: kadircet. Herald added a project: clang. Instead of asserting all typos are corrected in the sema destructor. The sema destructor is not run in the common case of running the compiler wi

[PATCH] D64791: [OpenCL] Fix sampler initialization for C++ mode

2019-07-16 Thread Neil Hickey via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL366212: [OpenCL] Fixing sampler initialisations for C++ mode. (authored by neil.hickey, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: ht

r366212 - [OpenCL] Fixing sampler initialisations for C++ mode.

2019-07-16 Thread Neil Hickey via cfe-commits
Author: neil.hickey Date: Tue Jul 16 07:57:32 2019 New Revision: 366212 URL: http://llvm.org/viewvc/llvm-project?rev=366212&view=rev Log: [OpenCL] Fixing sampler initialisations for C++ mode. Allow conversions between integer and sampler type. Differential Revision: https://reviews.llvm.org/D647

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-16 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. the code looks clearer now! Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:609 FixItsMap.erase(File); +std::lock_guard HLock(HighlightingsMutex); +FileToPrevHighlightings.erase(File); nit: I would create a new `{}`

r366211 - [OPENMP]Add support for analysis of if clauses.

2019-07-16 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Tue Jul 16 07:51:46 2019 New Revision: 366211 URL: http://llvm.org/viewvc/llvm-project?rev=366211&view=rev Log: [OPENMP]Add support for analysis of if clauses. Summary: Added support for analysis of if clauses in the OpenMP directives to be able to check for the use of unini

[PATCH] D64775: [Format/ObjC] Avoid breaking between unary operators and ObjC method invocations

2019-07-16 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton marked an inline comment as done. benhamilton added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:2427-2428 return 50; + if (Left.is(TT_UnaryOperator) && Right.is(TT_ObjCMethodExpr)) +return 60; sammccall wrote: > This l

[PATCH] D64775: [Format/ObjC] Avoid breaking between unary operators and ObjC method invocations

2019-07-16 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton updated this revision to Diff 210095. benhamilton marked an inline comment as done. benhamilton added a comment. - Rebase. - Change to just avoid breaking when the left-hand side is a unary operator Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.ll

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-07-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Starting to look real good! Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:807 + "", + Released>, + ]>, We mark options that are not yet ready for used with `InAlpha`, rather then `Re

[PATCH] D61466: [Rewrite][NFC] Add FIXMEs and tests for RemoveLineIfEmpty bug

2019-07-16 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61466/new/ https://reviews.llvm.org/D61466 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D61879: WIP: Prototype of DSE optimizations for -ftrivial-auto-var-init

2019-07-16 Thread Alexander Potapenko via Phabricator via cfe-commits
glider added inline comments. Comment at: llvm/lib/Transforms/Scalar/DeadStoreEliminationExpGlobal.cpp:27 +static const char GlobalArgumentMemAccess[] = { +// grep -P -o "(?<=FUNCTION_INFO: ).*" | sort -u > +// ../llvm-project/llvm/lib/Transforms/Scalar/DeadStoreEliminationExpD

[PATCH] D64554: [CrossTU] Add a function to retrieve original source location.

2019-07-16 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: include/clang/AST/ASTImporter.h:317 +std::shared_ptr SharedState = nullptr, +ASTUnit *Unit = nullptr); martong wrote: > balazske wrote: > > balazske wrote: > > > martong wrote: > > > > W

[PATCH] D64554: [CrossTU] Add a function to retrieve original source location.

2019-07-16 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: include/clang/AST/ASTImporter.h:317 +std::shared_ptr SharedState = nullptr, +ASTUnit *Unit = nullptr); balazske wrote: > balazske wrote: > > martong wrote: > > > What if we provided an a

[PATCH] D64569: [OpenCL] Improve destructor support in C++ for OpenCL

2019-07-16 Thread Marco Antognini via Phabricator via cfe-commits
mantognini marked 10 inline comments as done. mantognini added a comment. Mind the fact that I've rebased the changes onto a more recent master version. If you look at the diff of v1 against v2 you might see some unrelated changes. Let me know if there's anything else that I need to change. =

[PATCH] D64754: [clangd] Added highlighting for the targets in typedefs.

2019-07-16 Thread Johan Vikström via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL366207: [clangd] Added highlighting for the targets in typedefs and using. (authored by jvikstrom, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to c

  1   2   >