[clang] 2080232 - Revert "[c++20] P1907R1: Support for generalized non-type template arguments of scalar type."

2020-12-22 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2020-12-22T10:18:08-08:00 New Revision: 208023233398a677cc0aacb8153be9801db03af6 URL: https://github.com/llvm/llvm-project/commit/208023233398a677cc0aacb8153be9801db03af6 DIFF: https://github.com/llvm/llvm-project/commit/208023233398a677cc0aacb8153be9801db03af6.diff

[clang] af0dbaa - Revert "Following up on PR48517, fix handling of template arguments that refer"

2020-12-22 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2020-12-22T10:18:08-08:00 New Revision: af0dbaaa38f54b0366177aae43545a8848d3fe56 URL: https://github.com/llvm/llvm-project/commit/af0dbaaa38f54b0366177aae43545a8848d3fe56 DIFF: https://github.com/llvm/llvm-project/commit/af0dbaaa38f54b0366177aae43545a8848d3fe56.diff

[clang] 34e72a1 - Revert "DR2064: decltype(E) is only a dependent type if E is type-dependent, not"

2020-12-22 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2020-12-22T10:18:08-08:00 New Revision: 34e72a146111dd986889a0f0ec8767b2ca6b2913 URL: https://github.com/llvm/llvm-project/commit/34e72a146111dd986889a0f0ec8767b2ca6b2913 DIFF: https://github.com/llvm/llvm-project/commit/34e72a146111dd986889a0f0ec8767b2ca6b2913.diff

[PATCH] D80623: WIP: Add an API to simplify setting TraversalKind in clang-tidy matchers

2020-12-22 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:118 +/// behavior of clang-tidy. +virtual llvm::Optional +getCheckTraversalKind() const; aaron.ballman wrote: > steveire wrote: > > aaron.ballman wrote: > > >

[clang-tools-extra] b2e734d - Revert "[clangd] zap a few warnings"

2020-12-22 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2020-12-22T10:34:03-08:00 New Revision: b2e734d5f46d70c5a73dd16b0619c58eff6b8052 URL: https://github.com/llvm/llvm-project/commit/b2e734d5f46d70c5a73dd16b0619c58eff6b8052 DIFF: https://github.com/llvm/llvm-project/commit/b2e734d5f46d70c5a73dd16b0619c58eff6b8052.diff

[PATCH] D91302: Handle template instantiations better in clang-tidy check

2020-12-22 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/D91302/new/ https://reviews.llvm.org/D91302 ___ cfe-commits mailing list cfe-commit

[PATCH] D80623: WIP: Add an API to simplify setting TraversalKind in clang-tidy matchers

2020-12-22 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! I'm assuming that @sammccall may be busy given the holiday season, so I think it's fine to land this as-is if you don't hear from him in the next day. If he has additional

[clang-tools-extra] a5311d7 - [clang-tidy] Handle template instantiations in container size check

2020-12-22 Thread Stephen Kelly via cfe-commits
Author: Stephen Kelly Date: 2020-12-22T18:44:45Z New Revision: a5311d731e1b95e93b35b1e9183a4a531df386e7 URL: https://github.com/llvm/llvm-project/commit/a5311d731e1b95e93b35b1e9183a4a531df386e7 DIFF: https://github.com/llvm/llvm-project/commit/a5311d731e1b95e93b35b1e9183a4a531df386e7.diff LOG:

[PATCH] D91302: Handle template instantiations better in clang-tidy check

2020-12-22 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGa5311d731e1b: [clang-tidy] Handle template instantiations in conta

[PATCH] D91303: [clang-tidy] readability-container-size-empty: simplify implementation

2020-12-22 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM! Comment at: clang-tools-extra/clang-tidy/readability/ContainerSizeEmptyCheck.cpp:101 - ignoringImpCasts(stringLiteral(hasSize(0))), - ignoringImpCasts(cxxBindTemporaryExpr(has(DefaultConstruct

[PATCH] D93721: [NFC][AMDGPU] Do not override GetDefaultDwarfVersion

2020-12-22 Thread Scott Linder via Phabricator via cfe-commits
scott.linder created this revision. Herald added subscribers: kerbowa, t-tye, tpr, dstuttard, yaxunl, nhaehnle, jvesely, kzhuravl. scott.linder requested review of this revision. Herald added subscribers: cfe-commits, wdng. Herald added a project: clang. Use the implementation inhereted from `Too

[PATCH] D93721: [NFC][AMDGPU] Do not override GetDefaultDwarfVersion

2020-12-22 Thread Scott Linder via Phabricator via cfe-commits
scott.linder added reviewers: t-tye, laurentm0, yaxunl. scott.linder added a comment. No other target overrides `GetDefaultDwarfVersion` with the same implementation, and in the future when we make changes we can add them at the points in the hierarchy where they make sense semantically. Repos

[PATCH] D91302: Handle template instantiations better in clang-tidy check

2020-12-22 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Looks like this breaks tests on windows: http://45.33.8.238/win/30322/step_8.txt Ptal, and revert for now if it takes a while to fix. (In particular, prefer reverting over disabling the test on win.) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION htt

[PATCH] D91302: Handle template instantiations better in clang-tidy check

2020-12-22 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. In D91302#2468665 , @thakis wrote: > Looks like this breaks tests on windows: > http://45.33.8.238/win/30322/step_8.txt > > Ptal, and revert for now if it takes a while to fix. (In particular, prefer > reverting over disabling t

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a subscriber: rnk. dblaikie added a comment. This should have a LLVM test coverage for the LLVM changes. (I realize they're also tested by the Clang test, because there's no way to test Clang's pass manager creation short of testing the effect of running the pass manager (hmm - /

[clang-tools-extra] 7ec7788 - Try to fix build on Windows

2020-12-22 Thread Stephen Kelly via cfe-commits
Author: Stephen Kelly Date: 2020-12-22T20:25:58Z New Revision: 7ec7788ac175f3ccb7083de0e786438ad8610771 URL: https://github.com/llvm/llvm-project/commit/7ec7788ac175f3ccb7083de0e786438ad8610771 DIFF: https://github.com/llvm/llvm-project/commit/7ec7788ac175f3ccb7083de0e786438ad8610771.diff LOG:

[PATCH] D90507: [Driver] Add DWARF64 flag: -gdwarf64

2020-12-22 Thread Alexander Yermolovich via Phabricator via cfe-commits
ayermolo updated this revision to Diff 313410. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90507/new/ https://reviews.llvm.org/D90507 Files: clang/include/clang/Basic/CodeGenOptions.def clang/include/clang/Driver/Options.td clang/lib/CodeGen

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Sriraman Tallam via Phabricator via cfe-commits
tmsriram added inline comments. Comment at: llvm/include/llvm/IR/DebugInfoMetadata.h:2056-2059 + void replaceRawLinkageName(MDString *LinkageName) { +replaceOperandWith(3, LinkageName); + } + dblaikie wrote: > The need to add this API makes me a bit uncerta

[PATCH] D90507: [Driver] Add DWARF64 flag: -gdwarf64

2020-12-22 Thread Alexander Yermolovich via Phabricator via cfe-commits
ayermolo updated this revision to Diff 313412. ayermolo marked an inline comment as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90507/new/ https://reviews.llvm.org/D90507 Files: clang/include/clang/Basic/CodeGenOptions.def clang/include/

[PATCH] D93726: [clangd] Use atomics instead of locks to track periodic memory trimming

2020-12-22 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: qchateau. Herald added subscribers: usaxena95, kadircet, jfb, arphaman. sammccall requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. Instead of always locking/

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added inline comments. Comment at: llvm/include/llvm/IR/DebugInfoMetadata.h:2056-2059 + void replaceRawLinkageName(MDString *LinkageName) { +replaceOperandWith(3, LinkageName); + } + tmsriram wrote: > dblaikie wrote: > > The need to add this API makes m

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Sriraman Tallam via Phabricator via cfe-commits
tmsriram added inline comments. Comment at: llvm/lib/Transforms/Utils/UniqueInternalLinkageNames.cpp:26-29 +static cl::opt UniqueDebugAndProfileNames( +"unqiue-debug-profile-names", cl::init(true), cl::Hidden, +cl::desc("Uniqueify debug and profile symbol Names")); +

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added inline comments. Comment at: llvm/include/llvm/Passes/PassBuilder.h:140 bool DebugLogging; + bool UniqueLinkageNames; TargetMachine *TM; This seems better suited to be part of PipelineTuningOptions rather than directly in PassBuilder Repo

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. Also it looks like this is doing 2 different things, the moving of things from Clang to LLVM's PassBuilder, and separately the change to the pass itself. Can these be separated? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added a comment. In D93656#2468821 , @aeubanks wrote: > Also it looks like this is doing 2 different things, the moving of things > from Clang to LLVM's PassBuilder, and separately the change to the pass > itself. Can these be separated? I'm not sur

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. In D93656#2468834 , @hoy wrote: > In D93656#2468821 , @aeubanks wrote: > >> Also it looks like this is doing 2 different things, the moving of things >> from Clang to LLVM's PassBuilder, a

[PATCH] D93683: [clangd] Do not take stale definition from the static index.

2020-12-22 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. In D93683#2467631 , @ArcsinX wrote: > I also want to propose the similar patch for fuzzyFind() (as a part of this > patch or a separate one), but

[PATCH] D93630: [Attr] Apply GNU-style attributes to expression statements

2020-12-22 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D93630#2468241 , @vsavchenko wrote: > In D93630#2468197 , @aaron.ballman > wrote: > >> However, taking a step back -- what attributes would need this functionality >> (and couldn'

[PATCH] D93726: [clangd] Use atomics instead of locks to track periodic memory trimming

2020-12-22 Thread Quentin Chateau via Phabricator via cfe-commits
qchateau accepted this revision. qchateau added a comment. This revision is now accepted and ready to land. LGTM Small nits: - `operator()` is not `const` but `Next` is `mutable`, seems to me you intended to have `operator()` as `const` - memory orders for the atomic operations can probably be

[PATCH] D90507: [Driver] Add DWARF64 flag: -gdwarf64

2020-12-22 Thread Alexander Yermolovich via Phabricator via cfe-commits
ayermolo updated this revision to Diff 313421. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90507/new/ https://reviews.llvm.org/D90507 Files: clang/include/clang/Basic/CodeGenOptions.def clang/include/clang/Driver/Options.td clang/lib/CodeGen

[PATCH] D93726: [clangd] Use atomics instead of locks to track periodic memory trimming

2020-12-22 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D93726#2468855 , @qchateau wrote: > LGTM > > Small nits: > > - `operator()` is not `const` but `Next` is `mutable`, seems to me you > intended to have `operator()` as `const` Oops, I originally did plan to make `operator()`

[clang-tools-extra] 3dbe471 - [clangd] Use atomics instead of locks to track periodic memory trimming

2020-12-22 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-12-22T22:32:22+01:00 New Revision: 3dbe471a260392ec63dda8deb2709160afc56dde URL: https://github.com/llvm/llvm-project/commit/3dbe471a260392ec63dda8deb2709160afc56dde DIFF: https://github.com/llvm/llvm-project/commit/3dbe471a260392ec63dda8deb2709160afc56dde.diff LO

[PATCH] D93726: [clangd] Use atomics instead of locks to track periodic memory trimming

2020-12-22 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 rG3dbe471a2603: [clangd] Use atomics instead of locks to track periodic memory trimming (authored by sammccall). Changed prior to commit: https://re

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: llvm/include/llvm/IR/DebugInfoMetadata.h:2056-2059 + void replaceRawLinkageName(MDString *LinkageName) { +replaceOperandWith(3, LinkageName); + } + hoy wrote: > tmsriram wrote: > > dblaikie wrote: > > > The need t

[clang-tools-extra] f7a2612 - [clangd] Release notes for b8c37153d5393aad96

2020-12-22 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-12-22T22:58:45+01:00 New Revision: f7a26127f21fb1ca8252879ca647835ea7c5903d URL: https://github.com/llvm/llvm-project/commit/f7a26127f21fb1ca8252879ca647835ea7c5903d DIFF: https://github.com/llvm/llvm-project/commit/f7a26127f21fb1ca8252879ca647835ea7c5903d.diff LO

[PATCH] D93452: [clangd] Trim memory periodically

2020-12-22 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D93452#2467471 , @njames93 wrote: > I feel like we need some kind of entry for this in release notes given how > much of an issue it is. Good point. I usually procrastinate this and do a sweep of `git log` at release time,

[PATCH] D93490: [clang-format] PR48539 ReflowComments breaks Qt translation comments

2020-12-22 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks accepted this revision. HazardyKnusperkeks added a comment. This revision is now accepted and ready to land. This looks good to me. In D93490#2468351 , @JVApen wrote: > In D93490#2467733 , @MyDev

[PATCH] D93600: [clangd] When querying drivers by binary, look in PATH too

2020-12-22 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Thanks, this looks good, just a couple of nits. I guess you don't have commit access, I'm happy to land this for you when you're happy with it. Just need an email address to associate th

[PATCH] D76572: Replace `T(x)` with `reinterpret_cast(x)` everywhere it means reinterpret_cast. No functional change

2020-12-22 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone updated this revision to Diff 313433. Quuxplusone edited the summary of this revision. Quuxplusone added a comment. Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Rebase in preparation for finally pushing this thing if the buildbots seem happy. Repository:

[PATCH] D91927: [X86] Add x86_amx type for intel AMX.

2020-12-22 Thread LuoYuanke via Phabricator via cfe-commits
LuoYuanke added inline comments. Comment at: llvm/lib/Target/X86/X86LowerAMXType.cpp:264 + SmallVector DeadInsts; + SmallVector DeadBitcasts; + pengfei wrote: > Maybe better to use BitCastInst? There may be dead load or store instructions. Co

[PATCH] D76572: Replace `T(x)` with `reinterpret_cast(x)` everywhere it means reinterpret_cast. No functional change

2020-12-22 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone updated this revision to Diff 313446. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76572/new/ https://reviews.llvm.org/D76572 Files: clang/lib/CodeGen/CGCall.h llvm/include/llvm/IR/SymbolTableListTraits.h llvm/include/llvm/Object/

[PATCH] D86844: [LoopDeletion] Allows deletion of possibly infinite side-effect free loops

2020-12-22 Thread Jonas Paulsson via Phabricator via cfe-commits
jonpa added inline comments. Comment at: llvm/lib/Transforms/Scalar/LoopDeletion.cpp:132 /// A loop is considered dead if it does not impact the observable behavior of /// the program other than finite running time. This never removes a loop that /// might be infinite (unless

[PATCH] D90507: [Driver] Add DWARF64 flag: -gdwarf64

2020-12-22 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/test/Driver/debug-options.c:379 +// VALIDT: x86_64 +// RUN: %clang -### -c -gdwarf-5 -gdwarf64 -target VALIDT %s 2>&1 | FileCheck -check-prefix=GDWARF64_ON %s +// RUN: %clang -### -c -gdwarf-4 -gdwarf64 -target VALIDT %s 2>&1 | Fi

[PATCH] D89617: Prepend "uniq" to symbol names hash with -funique-internal-linkage-names

2020-12-22 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. `.L` prefixed symbols will be discarded by the linker in the default mode (none of `--discard-none/--discard-locals/--discard-all` is specified). So if you use `.L` (called PrivateGlobalPrefix in MC), this will work without any linker change (if possible I would hope we

[PATCH] D90507: [Driver] Add DWARF64 flag: -gdwarf64

2020-12-22 Thread Alexander Yermolovich via Phabricator via cfe-commits
ayermolo added inline comments. Comment at: clang/test/Driver/debug-options.c:379 +// VALIDT: x86_64 +// RUN: %clang -### -c -gdwarf-5 -gdwarf64 -target VALIDT %s 2>&1 | FileCheck -check-prefix=GDWARF64_ON %s +// RUN: %clang -### -c -gdwarf-4 -gdwarf64 -target VALIDT %s 2>&1 | F

[PATCH] D93273: [CodeGen][ObjC] Destroy callee-destroyed arguments in the caller function when the receiver is nil

2020-12-22 Thread Nathan Lanza via Phabricator via cfe-commits
lanza added a comment. Hey @ahatanak, I've ran into this problem in my companies projects and was wondering what the status of this patch is? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93273/new/ https://reviews.llvm.org/D93273 ___

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

2020-12-22 Thread Douglas Chen via Phabricator via cfe-commits
dougpuob added a comment. In D86671#2456161 , @njames93 wrote: > One last point, is there a way to validate that these options are only set > where it makes sense. If someone tries to use say > `MacroDefinitionHungarianPrefix` That could be warning worth

[clang] 22cf54a - Replace `T(x)` with `reinterpret_cast(x)` everywhere it means reinterpret_cast. NFC.

2020-12-22 Thread Arthur O'Dwyer via cfe-commits
Author: Arthur O'Dwyer Date: 2020-12-22T19:54:29-05:00 New Revision: 22cf54a7fba670642c121684ac3c7ff7e35dfa5c URL: https://github.com/llvm/llvm-project/commit/22cf54a7fba670642c121684ac3c7ff7e35dfa5c DIFF: https://github.com/llvm/llvm-project/commit/22cf54a7fba670642c121684ac3c7ff7e35dfa5c.diff

[PATCH] D76572: Replace `T(x)` with `reinterpret_cast(x)` everywhere it means reinterpret_cast. No functional change

2020-12-22 Thread Arthur O'Dwyer via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG22cf54a7fba6: Replace `T(x)` with `reinterpret_cast(x)` everywhere it means… (authored by arthur.j.odwyer). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D91927: [X86] Add x86_amx type for intel AMX.

2020-12-22 Thread LuoYuanke via Phabricator via cfe-commits
LuoYuanke updated this revision to Diff 313458. LuoYuanke added a comment. Address Pengfei's comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91927/new/ https://reviews.llvm.org/D91927 Files: clang/test/CodeGen/X86/amx_api.c llvm/includ

[PATCH] D93743: [NewPM] Run ObjC ARC passes

2020-12-22 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. aeubanks added reviewers: ahatanak, ychen. Herald added a subscriber: hiraditya. aeubanks requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Match the legacy PM in running various ObjC ARC pass

[PATCH] D93743: [NewPM] Run ObjC ARC passes

2020-12-22 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. I couldn't find any existing tests that these passes run under the legacy PM. Perhaps checking the output of -debug-pass-manager is enough for a test? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93743/new/ https://revie

[PATCH] D91927: [X86] Add x86_amx type for intel AMX.

2020-12-22 Thread LuoYuanke via Phabricator via cfe-commits
LuoYuanke added inline comments. Comment at: llvm/lib/Target/X86/X86LowerAMXType.cpp:265 +// If the dst type is <256 x i32>*, it is valid intruction. +// %0 = bitcast x86_amx* %tile to <256 x i32>* +// %1 = load <256 x i32>, <256 x i32>* %0, align 64 -

[PATCH] D86844: [LoopDeletion] Allows deletion of possibly infinite side-effect free loops

2020-12-22 Thread Atmn Patel via Phabricator via cfe-commits
atmnpatel updated this revision to Diff 313484. atmnpatel added a comment. Addressed comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86844/new/ https://reviews.llvm.org/D86844 Files: clang/test/Misc/loop-opt-setup.c llvm/include/llvm/Tr

[PATCH] D92039: [-Wcalled-once-parameter] Introduce 'called_once' attribute

2020-12-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D92039#2463039 , @vsavchenko wrote: > Add one gigantic comment on status kinds and the reasons behind some of the > design choices This was freakin' awesome, thanks a lot. With all the background in place, the rest of the patch w

[PATCH] D86844: [LoopDeletion] Allows deletion of possibly infinite side-effect free loops

2020-12-22 Thread Atmn Patel via Phabricator via cfe-commits
atmnpatel added inline comments. Comment at: llvm/lib/Transforms/Utils/LoopUtils.cpp:621 } } nikic wrote: > Unrelated, but why do these updates happen before the branch from preheader > to exit is added in IR? Shouldn't it be the other way around a

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added a comment. In D93656#2468841 , @aeubanks wrote: > In D93656#2468834 , @hoy wrote: > >> In D93656#2468821 , @aeubanks wrote: >> >>> Also it looks like this is doing

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy updated this revision to Diff 313487. hoy added a comment. Separated PassBuilder changes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93656/new/ https://reviews.llvm.org/D93656 Files: clang/lib/CodeGen/BackendUtil.cpp llvm/include/llvm/P

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. In D93656#2469485 , @hoy wrote: > In D93656#2468841 , @aeubanks wrote: > >> In D93656#2468834 , @hoy wrote: >> >>> In D93656#2468821

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy updated this revision to Diff 313488. hoy added a comment. Fixing IR test failure. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93656/new/ https://reviews.llvm.org/D93656 Files: clang/lib/CodeGen/BackendUtil.cpp llvm/include/llvm/Passes/P

[PATCH] D93595: [analyzer] Fix extraction of punned and known scalar SVals

2020-12-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I think you've found a very nice and compact 50% solution to the problem. I didn't think of this while i was looking for a proper fix. Very nice. Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:1629-1631 +static SVal getSValAsConcreteInt(SValBuil

[PATCH] D93698: [clang][cli] Port a CommaJoined option to the marshalling infrastructure

2020-12-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith accepted this revision. dexonsmith added a comment. This revision is now accepted and ready to land. LGTM, with one nit. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:333-337 +for (const std::string &Value : Values) { + if (&Value != &Values.front())

[PATCH] D93595: [analyzer] Fix extraction of punned and known scalar SVals

2020-12-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/concrete-endian.cpp:49 +#elif defined(__BIG_ENDIAN__) + clang_analyzer_eval(pps[3] == 0x8877); // expected-warning{{TRUE}} + clang_analyzer_eval(pps[2] == 0xaa99); // expected-warning{{TRUE}}

[PATCH] D93679: [clang][cli] Port getAllArgumentValues to the marshalling infrastructure

2020-12-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith accepted this revision. dexonsmith added a comment. This revision is now accepted and ready to land. LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93679/new/ https://reviews.llvm.org/D93679

[PATCH] D93595: [analyzer] Fix extraction of punned and known scalar SVals

2020-12-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:1648 +else + bitPos = ORegionRawOffs.getOffset().getQuantity(); +return bitPos * Ctx.getCharWidth(); NoQ wrote: > This assignment can overflow. Both because the raw

[PATCH] D93701: [clang][cli] NFC: Make Diags optional in normalizer

2020-12-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a comment. > This is needed for a future patch, where we start using normalizers in > contexts where no Diags are available. Can you explain what those contexts are? I'm wondering if they can be changed to create a `DiagnosticsEngine` instead of having to account for it being m

[PATCH] D93747: Rename debug linkage name with -funique-internal-linkage-names

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy created this revision. Herald added subscribers: dexonsmith, wenlei, hiraditya. hoy requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Funtions that are renamed under -funique-internal-linkage-names have their debug link

[PATCH] D93702: [clang][cli] NFC: Make marshalling macros reusable

2020-12-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:3040 -#define OPTION_WITH_MARSHALLING( \ -PREFIX_TYPE, NAME, ID, KIND, GROUP, ALIAS, ALIASARGS, FLAGS, PARAM, \ -HELPTEXT, META

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added a comment. The changes that rename debug linkage name has been separated as D93747 . I'm moving the discussion there. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93656/new/ https://reviews.llvm.org/D936

[PATCH] D84673: [clang][cli] Port DiagnosticOpts to new option parsing system

2020-12-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: llvm/utils/TableGen/OptParserEmitter.cpp:102-107 + std::string getMacroName() const { +if (KeyPath.startswith("DiagnosticOpts.")) + return (Twine("DIAG_") + MarshallingInfo::MacroName).str(); + +return MarshallingInfo::M

[PATCH] D93683: [clangd] Do not take stale definition from the static index.

2020-12-22 Thread Aleksandr Platonov via Phabricator via cfe-commits
ArcsinX added a comment. In D93683#2468842 , @sammccall wrote: > I'm not 100% sure this bug would block adding the equivalent change for > `fuzzyFind` though - it'll affect documentSymbol but not code-completion IIUC > (because of the workaround I mentio

[PATCH] D93747: Rename debug linkage name with -funique-internal-linkage-names

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added a comment. > In D93656 , @dblaikie wrote: > Though the C case is interesting - it means you'll end up with C functions > with the same DWARF 'name' but different linkage name. I don't know what > that'll do to DWARF consumers - I guess they'll probably

[PATCH] D93656: Moving UniqueInternalLinkageNamesPass to the start of IR pipelines.

2020-12-22 Thread Hongtao Yu via Phabricator via cfe-commits
hoy added a comment. In D93656#2469504 , @dblaikie wrote: > In D93656#2469485 , @hoy wrote: > >> In D93656#2468841 , @aeubanks wrote: >> >>> In D93656#2468834

[PATCH] D88220: [C++20] P1825R0: More implicit moves

2020-12-22 Thread Yang Fan via Phabricator via cfe-commits
nullptr.cpp updated this revision to Diff 313493. nullptr.cpp added a comment. Add more tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88220/new/ https://reviews.llvm.org/D88220 Files: clang/include/clang/Basic/DiagnosticGroups.td clang/i

<    1   2