[PATCH] D87163: [DSE] Switch to MemorySSA-backed DSE by default.

2020-09-14 Thread Mikael Holmén via Phabricator via cfe-commits
uabelho added a comment. Hi, I'm seeing what I think is a miscompile with this: opt -S -dse -o - dse.ll on @x = global [10 x [10 x i16]] zeroinitializer, align 1 define i16 @f() { entry: br label %do.body do.body: ; preds = %if.end,

[PATCH] D83144: Allow to specify macro names for android-comparison-in-temp-failure-retry.

2020-09-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh accepted this revision. alexfh added a comment. Looks good modulo comment. Comment at: clang-tools-extra/test/clang-tidy/checkers/android-comparison-in-temp-failure-retry-custom-macro.c:25 +void with_custom_macro() { + MY_TEMP_FAILURE_RETRY((foo())); + MY_TEMP_FAILURE

[PATCH] D87587: [clang-format] Make one-line namespaces resistant to FixNamespaceComments, update documentation

2020-09-14 Thread Krystian Kuzniarek via Phabricator via cfe-commits
kuzkry added a comment. Thanks @JakeMerdichAMD for your quick feedback. > In any case, can you also add the full diff context? It makes it easier for > us to review. I'll do that starting from the next patch because I'm afraid if I resubmit the longer version of the same patch, your comment wo

[PATCH] D87598: [SyntaxTree][List] Fix: `ParameterDeclarationList` is the `List` inside `ParametersAndQualifiers`

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas created this revision. eduucaldas added a reviewer: gribozavr2. Herald added a project: clang. Herald added a subscriber: cfe-commits. eduucaldas requested review of this revision. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D87598 Files: clang/lib/Tooling/Syntax/

[PATCH] D87599: [SyntaxTree] Provide `List::classof`

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas created this revision. eduucaldas added a reviewer: gribozavr2. Herald added a project: clang. Herald added a subscriber: cfe-commits. eduucaldas requested review of this revision. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D87599 Files: clang/include/clang/Tooli

[PATCH] D87600: [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas created this revision. eduucaldas added a reviewer: gribozavr2. Herald added a project: clang. Herald added a subscriber: cfe-commits. eduucaldas requested review of this revision. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D87600 Files: clang/include/clang/Tooli

[PATCH] D87450: [clangd] Implement hot index reloading for clangd-index-server

2020-09-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 291508. kbobyrev marked 7 inline comments as done. kbobyrev added a comment. Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87450/new/ https://reviews.llvm.org/D87450 Files: clang-to

[PATCH] D87450: [clangd] Implement hot index reloading for clangd-index-server

2020-09-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/server/Server.cpp:226 + llvm::sys::TimePoint<> LastModificationTime = + std::chrono::system_clock::now(); + for (;; std::this_thread::sleep_for(std::chrono::seconds(90))) { k

[PATCH] D86694: [scudo] Allow -fsanitize=scudo on Linux and Windows (WIP, don't land as is)

2020-09-14 Thread Russell Gallop via Phabricator via cfe-commits
russell.gallop updated this revision to Diff 291511. russell.gallop added a comment. Re-upload patch with G LLVM Github Monorepo set. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86694/new/ https://reviews.llvm.org/D86694 Files: clang/lib/Drive

[PATCH] D87528: Enable '#pragma STDC FENV_ACCESS' in frontend cf. D69272 - Work in Progress

2020-09-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In D87528#2270561 , @rjmccall wrote: > Richard, what do you think the right rule is for when to use the special > constant-evaluation rules for this feature in C++? The C standard says that > constant expressions should use the d

[clang-tools-extra] 30667c9 - [clangd] Add error() function for creating formatv-style llvm::Errors. NFC

2020-09-14 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-09-14T10:43:42+02:00 New Revision: 30667c967d3f420d3f53fb1c9c2465550a1112df URL: https://github.com/llvm/llvm-project/commit/30667c967d3f420d3f53fb1c9c2465550a1112df DIFF: https://github.com/llvm/llvm-project/commit/30667c967d3f420d3f53fb1c9c2465550a1112df.diff LO

[PATCH] D83419: [clangd] Add error() function for creating formatv-style llvm::Errors. NFC

2020-09-14 Thread Sam McCall via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG30667c967d3f: [clangd] Add error() function for creating formatv-style llvm::Errors. NFC (authored by sammccall). Changed prior to commit: https:/

[PATCH] D87600: [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Tooling/Syntax/Tree.cpp:236 + + auto *L = dyn_cast(T); + if (!L) Comment at: clang/lib/Tooling/Syntax

[PATCH] D87450: [clangd] Implement hot index reloading for clangd-index-server

2020-09-14 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/index/remote/server/Server.cpp:226 + llvm::sys::TimePoint<> LastModificationTime = + std::chrono::system_clock::now(); + for (;; std::this_thread::sleep_for(std::chrono::seconds(90))) { k

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Gabor Marton via Phabricator via cfe-commits
martong accepted this revision. martong added a comment. This revision is now accepted and ready to land. > Unfortunately template specializations do not catch the descendants of the > class for which the template is specialized. Therefore it does not work > correcly for the descendants of Funct

[clang-tools-extra] 574dd60 - [clangd] Track tweaks that fail the apply stage

2020-09-14 Thread Kadir Cetinkaya via cfe-commits
Author: Kadir Cetinkaya Date: 2020-09-14T11:24:02+02:00 New Revision: 574dd60547179a2c143ac14cdd6f5f5a40156d54 URL: https://github.com/llvm/llvm-project/commit/574dd60547179a2c143ac14cdd6f5f5a40156d54 DIFF: https://github.com/llvm/llvm-project/commit/574dd60547179a2c143ac14cdd6f5f5a40156d54.dif

[PATCH] D87501: [clangd] Track tweaks that fail the apply stage

2020-09-14 Thread Kadir Cetinkaya via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG574dd6054717: [clangd] Track tweaks that fail the apply stage (authored by kadircet). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87501/new/ https://revie

[PATCH] D83144: Allow to specify macro names for android-comparison-in-temp-failure-retry.

2020-09-14 Thread Florian Mayer via Phabricator via cfe-commits
fmayer updated this revision to Diff 291520. fmayer added a comment. Added more simple cases to the test. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83144/new/ https://reviews.llvm.org/D83144 Files: clang-tools-extra/clang-tidy/android/ComparisonInTempFailureRetryCheck.cpp clang

[PATCH] D83144: Allow to specify macro names for android-comparison-in-temp-failure-retry.

2020-09-14 Thread Florian Mayer via Phabricator via cfe-commits
fmayer added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/android-comparison-in-temp-failure-retry-custom-macro.c:25 +void with_custom_macro() { + MY_TEMP_FAILURE_RETRY((foo())); + MY_TEMP_FAILURE_RETRY((int)(foo() == 1)); alexfh wro

[PATCH] D87450: [clangd] Implement hot index reloading for clangd-index-server

2020-09-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 291521. kbobyrev marked 2 inline comments as done. kbobyrev added a comment. Address remaining comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87450/new/ https://reviews.llvm.org/D87450 Files: clang

[clang-tools-extra] 687e1d7 - [clangd] makeStringError,make_error -> error()

2020-09-14 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-09-14T11:48:31+02:00 New Revision: 687e1d7121645d23aa5e919ed4d3c0e57af975cd URL: https://github.com/llvm/llvm-project/commit/687e1d7121645d23aa5e919ed4d3c0e57af975cd DIFF: https://github.com/llvm/llvm-project/commit/687e1d7121645d23aa5e919ed4d3c0e57af975cd.diff LO

[PATCH] D71199: [clang-tidy] New check cppcoreguidelines-prefer-member-initializer

2020-09-14 Thread Whisperity via Phabricator via cfe-commits
whisperity added a comment. Minor inline comments. Could you please add a test case where the constructor is defined out of line? So far in every test, the constructor //body// was inside the class. Something like: struct S { int i, j; S(); }; S::S() { i = 1; j = 2;

[PATCH] D71199: [clang-tidy] New check cppcoreguidelines-prefer-member-initializer

2020-09-14 Thread Whisperity via Phabricator via cfe-commits
whisperity added inline comments. Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/PreferMemberInitializerCheck.cpp:43 +static bool isLiteral(const Expr *E) { + return isa(E) || + isa(E) || baloghadamsoftware wrote: > aaron.ballman wrote: > >

[PATCH] D87600: [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas updated this revision to Diff 291522. eduucaldas marked 2 inline comments as done. eduucaldas added a comment. Fix build error and clang-tidy lint error Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87600/new/ https://reviews.llvm.org/D8

[PATCH] D87449: [clang-tidy] Add new check for SEI CERT rule SIG30-C.

2020-09-14 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 291524. balazske added a comment. Changed checker messages, reformatted text, rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87449/new/ https://reviews.llvm.org/D87449 Files: clang-tools-extra/clang-

[PATCH] D87598: [SyntaxTree][List] Fix: `ParameterDeclarationList` is the `List` inside `ParametersAndQualifiers`

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG12232dc181cb: [SyntaxTree][List] Fix: `ParameterDeclarationList` is the `List` inside… (authored by eduucaldas). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[clang] 12232dc - [SyntaxTree][List] Fix: `ParameterDeclarationList` is the `List` inside `ParametersAndQualifiers`

2020-09-14 Thread Eduardo Caldas via cfe-commits
Author: Eduardo Caldas Date: 2020-09-14T10:35:41Z New Revision: 12232dc181cbe78fbd40a6ed1a89795a2c9a1154 URL: https://github.com/llvm/llvm-project/commit/12232dc181cbe78fbd40a6ed1a89795a2c9a1154 DIFF: https://github.com/llvm/llvm-project/commit/12232dc181cbe78fbd40a6ed1a89795a2c9a1154.diff LOG

[clang] 0f4cc64 - [SyntaxTree] Provide `List::classof`

2020-09-14 Thread Eduardo Caldas via cfe-commits
Author: Eduardo Caldas Date: 2020-09-14T10:35:41Z New Revision: 0f4cc64fd747fbb33aeccfaccb8873762d2511f2 URL: https://github.com/llvm/llvm-project/commit/0f4cc64fd747fbb33aeccfaccb8873762d2511f2 DIFF: https://github.com/llvm/llvm-project/commit/0f4cc64fd747fbb33aeccfaccb8873762d2511f2.diff LOG

[PATCH] D87599: [SyntaxTree] Provide `List::classof`

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0f4cc64fd747: [SyntaxTree] Provide `List::classof` (authored by eduucaldas). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87599/new/ https://reviews.llvm.o

[PATCH] D87600: [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas updated this revision to Diff 291532. eduucaldas added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87600/new/ https://reviews.llvm.org/D87600 Files: clang/include/clang/Tooling/Syntax/Tree.h clang/lib/Tooling/Syn

[PATCH] D87600: [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Eduardo Caldas via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGceb0128509c5: [SyntaxTree][List] `assertInvariants` for `List`s (authored by eduucaldas). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[clang] ceb0128 - [SyntaxTree][List] `assertInvariants` for `List`s

2020-09-14 Thread Eduardo Caldas via cfe-commits
Author: Eduardo Caldas Date: 2020-09-14T10:36:11Z New Revision: ceb0128509c51100afbf804bda84d82b7ebe06b1 URL: https://github.com/llvm/llvm-project/commit/ceb0128509c51100afbf804bda84d82b7ebe06b1 DIFF: https://github.com/llvm/llvm-project/commit/ceb0128509c51100afbf804bda84d82b7ebe06b1.diff LOG

[PATCH] D87163: [DSE] Switch to MemorySSA-backed DSE by default.

2020-09-14 Thread Florian Hahn via Phabricator via cfe-commits
fhahn added a comment. In D87163#2270568 , @uabelho wrote: > Hi, > > I'm seeing what I think is a miscompile with this: Thanks for the reproducer. We have to be more careful around pointers that may reference multiple locations in memory. I pushed f715d8

[PATCH] D86137: Add ignore-unknown-options flag to clang-format.

2020-09-14 Thread George Rimar via Phabricator via cfe-commits
grimar added inline comments. Comment at: clang/unittests/Format/FormatTest.cpp:16079 + auto Style9 = getStyle("file", "/d/.clang-format", "LLVM", "", &FS, true); + ASSERT_TRUE((bool)Style9); } It looks like it is very similar to "Test 7:" and can be a part of

[PATCH] D87163: [DSE] Switch to MemorySSA-backed DSE by default.

2020-09-14 Thread Florian Hahn via Phabricator via cfe-commits
fhahn added a comment. In D87163#2270444 , @thakis wrote: > Heads-up: We're seeing fairly widespread test failures with this in Chromium > that go away when we force this flag off. It's possible that it's due to only > a small number of issues and they m

[PATCH] D87604: [X86] Convert integer _mm_reduce_* intrinsics to emit llvm.reduction intrinsics (PR47506)

2020-09-14 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon created this revision. RKSimon added a reviewer: craig.topper. Herald added a project: clang. RKSimon requested review of this revision. Placeholder patch for when the reduction intrinsics drop their experimental status, emitting the equivalent reduction intrinsic in IR instead of expandi

[PATCH] D87163: [DSE] Switch to MemorySSA-backed DSE by default.

2020-09-14 Thread Mikael Holmén via Phabricator via cfe-commits
uabelho added a comment. In D87163#2270860 , @fhahn wrote: > In D87163#2270568 , @uabelho wrote: > >> Hi, >> >> I'm seeing what I think is a miscompile with this: > > Thanks for the reproducer. We have to be more ca

[PATCH] D87395: Sema: add support for `__attribute__((__swift_objc_members__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87395/new/ https://reviews.llvm.org/D87395 ___ cfe-commits mailing list cfe-commit

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. Can you expand on what is wrong currently for `FunctionDecl` descendants? Would the new test `FindsBodyOfFunctionChildren` fail with the current implementation? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87527/new/ http

[PATCH] D87532: Sema: add support for `__attribute__((__swift_bridge__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2133 +def SwiftBridge : Attr { + let Spellings = [GNU<"swift_bridge">]; Is this a type or a declaration attribute? It looks like a declaration attribute based on the declaratio

[PATCH] D87532: Sema: add support for `__attribute__((__swift_bridge__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2137 + let Subjects = SubjectList<[Tag, TypedefName, ObjCInterface, ObjCProtocol], + ErrorDiag, "ExpectedType">; + let Documentation = [SwiftBridgeDocs]; -

[PATCH] D87607: [clang][aarch64] Support implicit casts between GNU and SVE vectors

2020-09-14 Thread Cullen Rhodes via Phabricator via cfe-commits
c-rhodes created this revision. c-rhodes added reviewers: sdesmalen, efriedma, rsandifo-arm. Herald added subscribers: kristof.beyls, tschuett. Herald added a reviewer: rengolin. Herald added a project: clang. c-rhodes requested review of this revision. This patch adds support for implicit casting

[PATCH] D87534: Sema: introduce `__attribute__((__swift_name__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2174 + ObjCInterface, ObjCClassMethod, ObjCInstanceMethod, ObjCProperty, ObjCProtocol], + ErrorDiag, "ExpectedSwiftNameSubjects">; + let Documentation = [SwiftNameDocs]; --

[PATCH] D87163: [DSE] Switch to MemorySSA-backed DSE by default.

2020-09-14 Thread Mikael Holmén via Phabricator via cfe-commits
uabelho added a comment. In D87163#2270918 , @uabelho wrote: > In D87163#2270860 , @fhahn wrote: > >> In D87163#2270568 , @uabelho wrote: >> >>> Hi, >>> >>> I'm seeing what I

[PATCH] D87396: Sema: add support for `__attribute__((__swift_typedef_bridged__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2123 + let Spellings = [GNU<"swift_bridged_typedef">]; + let Subjects = SubjectList<[TypedefName], ErrorDiag, "typedefs">; + let Documentation = [SwiftBridgedTypedefDocs]; compn

[PATCH] D87518: [analyzer][Liveness][NFC] Remove an unneeded pass to collect variables that appear in an assignment

2020-09-14 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > This problem only exists if we traverse a CFGBlock in order. And Liveness in > fact does it reverse order. So a distinct pass is indeed unnecessary, we can > note the appearance of the assignment by the time we reach the variable. Should this patch depend on https://r

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. In D87527#2270939 , @ymandel wrote: > Can you expand on what is wrong currently for `FunctionDecl` descendants? > Would the new test `FindsBodyOfFunctionChildren` fail with the current > implementation? Yes, exactly.

[PATCH] D87518: [analyzer][Liveness][NFC] Remove an unneeded pass to collect variables that appear in an assignment

2020-09-14 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/include/clang/Analysis/CFG.h:1311 + + llvm::iterator_range nodes() { return *this; } + llvm::iterator_range const_nodes() const { return *this; } martong wrote: > Do we convert `this` to `CFGBlock *Entry` here? I

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. In D87527#2271016 , @baloghadamsoftware wrote: > In D87527#2270939 , @ymandel wrote: > >> Can you expand on what is wrong currently for `FunctionDecl` descendants? >> Would the new test `F

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. > Thank you for clarifying. I might nitpick that it's not "obviously wrong": > I'm actually writing code now that depends on exactly that behavior -- I > don't care where the method decl body is, as long as it's visible in the > current TU. That said, I thin

[PATCH] D87519: [analyzer][Liveness][NFC] Enqueue the CFGBlocks post-order

2020-09-14 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/lib/Analysis/LiveVariables.cpp:522 - // FIXME: we should enqueue using post order. - for (const CFGBlock *B : cfg->nodes()) { + for (const CFGBlock *B : *AC.getAnalysis()) { worklist.enqueueBlock(B); xaza

[PATCH] D71199: [clang-tidy] New check cppcoreguidelines-prefer-member-initializer

2020-09-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 291562. baloghadamsoftware added a comment. No crash, no hang, no false positives on the LLVM Project. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71199/new/ https://reviews.llvm.org/D71199 Files: clang-tools-extra/clang-tidy/cppcore

[PATCH] D83500: [PowerPC][Power10] Implement custom codegen for the vec_replace_elt and vec_replace_unaligned builtins.

2020-09-14 Thread Amy Kwan via Phabricator via cfe-commits
amyk added a comment. @nemanjai Could you please take another look to see if I have addressed your comments? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83500/new/ https://reviews.llvm.org/D83500 ___

[PATCH] D86841: [clang] Add mustprogress and llvm.loop.mustprogress attribute deduction

2020-09-14 Thread Atmn Patel via Phabricator via cfe-commits
atmnpatel updated this revision to Diff 291567. atmnpatel added a comment. Fixed failing test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86841/new/ https://reviews.llvm.org/D86841 Files: clang/lib/CodeGen/CGLoopInfo.cpp clang/lib/CodeGen/C

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Fanbo Meng via Phabricator via cfe-commits
fanbo-meng created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. fanbo-meng requested review of this revision. Aligned allocation is not supported on z/OS. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D87611 Files: clang/lib/Driver/To

[PATCH] D87527: [ASTMatchers] Fix `hasBody` for the descendants of `FunctionDecl`

2020-09-14 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. In D87527#2271059 , @baloghadamsoftware wrote: > We must decide about the namings. If we want to be in sync with the methods > in `FunctionDecl`, then we keep `hasBody()` as is, but remove the template > specialization, and crea

[PATCH] D87615: [clang][Driver] Force stack realignment on 32-bit Solaris/x86

2020-09-14 Thread Rainer Orth via Phabricator via cfe-commits
ro created this revision. ro added reviewers: MaskRay, rahmanl, efriedma, RKSimon. ro added a project: clang. Herald added a subscriber: fedor.sergeev. ro requested review of this revision. On Solaris/x86, several hundred 32-bit tests `FAIL`, all in the same way: env ASAN_OPTIONS=halt_on_error=

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp:126 if (OldVar == nullptr) { +// Only allow initialization of a const reference from a free function if it +// has no arguments or only default

[PATCH] D83814: [clangd] Add Random Forest runtime for code completion.

2020-09-14 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz added inline comments. Comment at: clang-tools-extra/clangd/unittests/DecisionForestTests.cpp:5 + +namespace clangd { +namespace clangd { This is supposed to be "namespace clang", right? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D87459: [libcxx][test] ostream{,buf}_iterator::difference_type changes in C++20

2020-09-14 Thread Louis Dionne via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG71a16e40f78a: [libcxx] ostream{,buf}_iterator::difference_type changes in C++20 (authored by ldionne). Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D87615: [clang][Driver] Force stack realignment on 32-bit Solaris/x86

2020-09-14 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. Would it be possible to add some tests? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87615/new/ https://reviews.llvm.org/D87615 ___ cfe-commits mailing list cfe-commits@lists.ll

[clang] 3b7708e - Assert we've found the size of each (non-overlapping) structure. NFCI.

2020-09-14 Thread Simon Pilgrim via cfe-commits
Author: Simon Pilgrim Date: 2020-09-14T16:10:52+01:00 New Revision: 3b7708e2deb48befcef764fb69f9217f55ac1155 URL: https://github.com/llvm/llvm-project/commit/3b7708e2deb48befcef764fb69f9217f55ac1155 DIFF: https://github.com/llvm/llvm-project/commit/3b7708e2deb48befcef764fb69f9217f55ac1155.diff

[PATCH] D87396: Sema: add support for `__attribute__((__swift_typedef_bridged__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2123 + let Spellings = [GNU<"swift_bridged_typedef">]; + let Subjects = SubjectList<[TypedefName], ErrorDiag, "typedefs">; + let Documentation = [SwiftBridgedTypedefDocs]; aaron.ball

[PATCH] D77491: [Sema] Introduce BuiltinAttr, per-declaration builtin-ness

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:2088 + + if (Error || R.isNull()) +return nullptr; Should we do this check *before* we create the C linkage decl spec above? Repository: rG LLVM Github Monorepo CHANGES SINCE L

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Felix Berger via Phabricator via cfe-commits
flx added inline comments. Comment at: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp:126 if (OldVar == nullptr) { +// Only allow initialization of a const reference from a free function if it +// has no arguments or only default arguments

[PATCH] D86841: [clang] Add mustprogress and llvm.loop.mustprogress attribute deduction

2020-09-14 Thread Atmn Patel via Phabricator via cfe-commits
atmnpatel updated this revision to Diff 291581. atmnpatel added a comment. Tests renamed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86841/new/ https://reviews.llvm.org/D86841 Files: clang/lib/CodeGen/CGLoopInfo.cpp clang/lib/CodeGen/CGLoop

[PATCH] D87396: Sema: add support for `__attribute__((__swift_typedef_bridged__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd marked an inline comment as done. compnerd added inline comments. Comment at: clang/lib/Sema/SemaDeclAttr.cpp:7543 + case ParsedAttr::AT_SwiftBridgedTypedef: +handleSimpleAttribute(S, D, AL); +break; aaron.ballman wrote: > compnerd wrote: > > aa

[PATCH] D87395: Sema: add support for `__attribute__((__swift_objc_members__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG916b43403588: Sema: add support for `__attribute__((__swift_objc_members__))` (authored by compnerd). Changed prior to commit: https://reviews.llv

[clang] 916b434 - Sema: add support for `__attribute__((__swift_objc_members__))`

2020-09-14 Thread Saleem Abdulrasool via cfe-commits
Author: Saleem Abdulrasool Date: 2020-09-14T15:24:41Z New Revision: 916b43403588a85425bbc82712427cf53ed877cc URL: https://github.com/llvm/llvm-project/commit/916b43403588a85425bbc82712427cf53ed877cc DIFF: https://github.com/llvm/llvm-project/commit/916b43403588a85425bbc82712427cf53ed877cc.diff

[PATCH] D87615: [clang][Driver] Force stack realignment on 32-bit Solaris/x86

2020-09-14 Thread Rainer Orth via Phabricator via cfe-commits
ro added a comment. In D87615#2271268 , @RKSimon wrote: > Would it be possible to add some tests? Probably not reliably: the tests that usually fail bye the hundreds happen to `PASS` once in a while when the stack pointer is 16-byte aligned by accident.

[PATCH] D87587: [clang-format][PR47290] Make one-line namespaces resistant to FixNamespaceComments, update documentation

2020-09-14 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay requested changes to this revision. MyDeveloperDay added a comment. I have a hard time when people change tests! just because one person wants them this way doesn't mean everyone will. I am not sure about others but I'd be ok about seeing this as an option to override the value b

[PATCH] D87396: Sema: add support for `__attribute__((__swift_typedef_bridged__))`

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Sema/SemaDeclAttr.cpp:7543 + case ParsedAttr::AT_SwiftBridgedTypedef: +handleSimpleAttribute(S, D, AL); +break; compnerd wrote: > aaron.ballman wrote: > > compnerd wrote: > > > aaron.ballman wrot

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Felix Berger via Phabricator via cfe-commits
flx updated this revision to Diff 291584. flx edited the summary of this revision. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87455/new/ https://reviews.llvm.org/D87455 Files: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp clang-tools-extra/test/clang-

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Felix Berger via Phabricator via cfe-commits
flx added inline comments. Comment at: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp:126 if (OldVar == nullptr) { +// Only allow initialization of a const reference from a free function if it +// has no arguments or only default arguments

[PATCH] D86796: [Sema] Address-space sensitive index check for unbounded arrays

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM! Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:8841-8844 +def warn_array_index_exceeds_max_addressable_bounds : Warning< + "array index %0

[PATCH] D69272: Enable '#pragma STDC FENV_ACCESS' in frontend

2020-09-14 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. In D69272#2268337 , @mibintc wrote: > I am working on a task to ensure that clang is doing floating point constant > folding correctly. Could you please share your plans on it? I recently also started implementing constant fol

[PATCH] D87396: Sema: add support for `__attribute__((__swift_typedef_bridged__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd updated this revision to Diff 291587. compnerd added a comment. Add additional test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87396/new/ https://reviews.llvm.org/D87396 Files: clang/include/clang/Basic/Attr.td clang/include/c

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM with some minor nits. Comment at: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp:122 // the first. - for (unsigned int i =

[PATCH] D85408: Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map section, instead of emitting special unary-encoded symbols.

2020-09-14 Thread Rahman Lavaee via Phabricator via cfe-commits
rahmanl updated this revision to Diff 291589. rahmanl added a comment. - Remove the "labels" part of the clang test as the functionality is tested on LLVM tests. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85408/new/ https://reviews.llvm.org/D85

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Fanbo Meng via Phabricator via cfe-commits
fanbo-meng updated this revision to Diff 291590. fanbo-meng added a comment. emit the correct diagnostics for z/OS. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87611/new/ https://reviews.llvm.org/D87611 Files: clang/include/clang/Basic/AlignedAllocation.h clang/include/clang/Basi

[PATCH] D87588: [ASTMatchers] extract public matchers from const-analysis into own patch

2020-09-14 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth updated this revision to Diff 291592. JonasToth added a comment. - fix compilation error from removed brace Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87588/new/ https://reviews.llvm.org/D87588 Files: clang/docs/LibASTMatchersRefere

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Fanbo Meng via Phabricator via cfe-commits
fanbo-meng updated this revision to Diff 291593. fanbo-meng added a comment. Previous diff is incorrect and didn't include the entire change set, making a new one. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87611/new/ https://reviews.llvm.org/D87611 Files: clang/include/clang/Bas

[PATCH] D87534: Sema: introduce `__attribute__((__swift_name__))`

2020-09-14 Thread Doug Gregor via Phabricator via cfe-commits
doug.gregor added a comment. Thank you for doing this! Comment at: clang/include/clang/Basic/Attr.td:2173 + SubjectList<[Enum, EnumConstant, Field, Function, GlobalVar, Struct, TypedefName, + ObjCInterface, ObjCClassMethod, ObjCInstanceMethod, ObjCPrope

[PATCH] D85408: Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map section, instead of emitting special unary-encoded symbols.

2020-09-14 Thread Rahman Lavaee via Phabricator via cfe-commits
rahmanl updated this revision to Diff 291595. rahmanl added a comment. - Merge branch 'master' into arcpatch-D85408 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85408/new/ https://reviews.llvm.org/D85408 Files: clang/docs/UsersManual.rst clan

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added inline comments. Comment at: clang/lib/Driver/ToolChains/ZOS.cpp:25-27 +void ZOS::addClangTargetOptions(const llvm::opt::ArgList &DriverArgs, +llvm::opt::ArgStringList &CC1Args, +Action::

[PATCH] D87532: Sema: add support for `__attribute__((__swift_bridge__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd marked 4 inline comments as done. compnerd added inline comments. Comment at: clang/lib/Sema/SemaDeclAttr.cpp:5535 + // Don't duplicate annotations that are already set. + if (D->hasAttr()) { +S.Diag(AL.getLoc(), diag::warn_duplicate_attribute) << AL.getAttrName();

[PATCH] D87532: Sema: add support for `__attribute__((__swift_bridge__))`

2020-09-14 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd updated this revision to Diff 291601. compnerd marked an inline comment as done. compnerd added a comment. Address some feedback from @aaron.ballman Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87532/new/ https://reviews.llvm.org/D87532

[PATCH] D87081: [analyzer][StdLibraryFunctionsChecker] Elaborate the summary of fread and fwrite

2020-09-14 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 291606. martong added a comment. - Add tests to verify compatibility of the two checkers Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87081/new/ https://reviews.llvm.org/D87081 Files: clang/lib/StaticAnalyz

[PATCH] D85408: Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map section, instead of emitting special unary-encoded symbols.

2020-09-14 Thread Rahman Lavaee via Phabricator via cfe-commits
rahmanl updated this revision to Diff 291607. rahmanl added a comment. - Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85408/new/ https://reviews.llvm.org/D85408 Files: clang/docs/UsersManual.rst clang/test/CodeGen/basic-block-sections.

[clang] 7841e21 - Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map section, instead of emitting special unary-encoded symbols.

2020-09-14 Thread Rahman Lavaee via cfe-commits
Author: Rahman Lavaee Date: 2020-09-14T10:16:44-07:00 New Revision: 7841e21c98495ba5e33e0d2507d985bd5b938445 URL: https://github.com/llvm/llvm-project/commit/7841e21c98495ba5e33e0d2507d985bd5b938445 DIFF: https://github.com/llvm/llvm-project/commit/7841e21c98495ba5e33e0d2507d985bd5b938445.diff

[PATCH] D85408: Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map section, instead of emitting special unary-encoded symbols.

2020-09-14 Thread Rahman Lavaee via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG7841e21c9849: Let -basic-block-sections=labels emit basicblock metadata in a new .bb_addr_map… (authored by rahmanl). Repository: rG LLVM Github M

[PATCH] D87587: [clang-format][PR47290] Make one-line namespaces resistant to FixNamespaceComments, update documentation

2020-09-14 Thread Krystian Kuzniarek via Phabricator via cfe-commits
kuzkry added a comment. Hey @MyDeveloperDay, thanks for the review. On the one hand, you're right, it's a breaking change and I dislike it too. But please, reconsider because on the other hand: a) adding a new option means increasing our maintenance cost by possibly adding a rarely-used switch (

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Fanbo Meng via Phabricator via cfe-commits
fanbo-meng added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:1841 -<< IsDelete << FD.getType().getAsString() << OSName -<< alignedAllocMinVersion(T.getOS()).getAsString(); Diag(Loc, diag::note_silence_aligned_allocation_unavailable); -

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Felix Berger via Phabricator via cfe-commits
flx updated this revision to Diff 291610. flx marked an inline comment as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87455/new/ https://reviews.llvm.org/D87455 Files: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp clang-tools-extra/test/clang-tid

[PATCH] D87561: [Sema] List conversion validate character array

2020-09-14 Thread Mark de Wever via Phabricator via cfe-commits
Mordante marked 3 inline comments as done. Mordante added a comment. Thanks for the feedback! Comment at: clang/lib/Sema/SemaOverload.cpp:4988 + +if (ToType->isArrayType() && ToType->isCharType() && +isa(From->getInit(0))) { rsmith wrote: > `isCharT

[PATCH] D87455: [clang-tidy] performance-unnecessary-copy-initialization: Restrict UnnecessaryCopyInitialization check to variables initialized from free functions without arguments

2020-09-14 Thread Felix Berger via Phabricator via cfe-commits
flx added a comment. Thank you for the review, Aaron! I don't have have commit access. Would you mind submitting it? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87455/new/ https://reviews.llvm.org/D87455 ___ cfe-commits mailing list cfe-co

[PATCH] D84362: [NFC] Add missing functions to PartialDiagnostic

2020-09-14 Thread Artem Belevich via Phabricator via cfe-commits
tra added subscribers: aaron.ballman, rtrieu. tra added a comment. So, the idea here is to do some sort of duck-typing and allow DiagBuilder to work with both `DiagnosticBuilder` and `PartialDiagnostic`. What bothers me is that unlike `Diagnostic` `PartialDiagnostic` seems to be commingling fun

[PATCH] D86671: [clang-tidy] Add new case type to check variables with Hungarian notation

2020-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/clang-tidy/readability/IdentifierNamingCheck.cpp:216 +{"long","l"}, +{"long long", "ll"}, +{"unsigned long", "ul"}, `unsigned long long` -> `ull` ===

[PATCH] D87611: [SystemZ][z/OS] Set aligned allocation unavailable by default for z/OS

2020-09-14 Thread Fanbo Meng via Phabricator via cfe-commits
fanbo-meng updated this revision to Diff 291616. fanbo-meng added a comment. be consistent with namespace qualification CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87611/new/ https://reviews.llvm.org/D87611 Files: clang/include/clang/Basic/AlignedAllocation.h clang/include/clang/

[PATCH] D87425: [CodeGen][typeid] Emit typeinfo directly if type is known at compile-time

2020-09-14 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 291619. zequanwu added a comment. If the operand of CXXTypeidExpr is already most derived object, no need to look up vtable. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87425/new/ https://reviews.llvm.org/D

  1   2   >