[PATCH] D119525: [clang] Fix crash when array size is missing in initializer

2022-02-10 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder updated this revision to Diff 407785. tbaeder added a comment. This is a pretty big gotcha at best and I feel like `getArraySize()` should return `None` in that case instead... thoughts? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119525/new/ https://reviews.llvm.org/D119525

[PATCH] D119525: [clang] Fix crash when array size is missing in initializer

2022-02-10 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, rsmith. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This fixes the crash from https://github.com/llvm/llvm-project/issues/53742 `CXXNewExpr::getArraySize()`

[PATCH] D117681: [RISCV] Add the policy operand for some masked RVV ternary IR intrinsics.

2022-02-10 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. LGTM Note, I don't think vslidedown needs a tail policy, but vslideup does. But probably not worth making them different. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117681/new/ https://reviews.llvm.org/D117681 __

[PATCH] D117888: [clang][driver][wasm] Support -stdlib=libstdc++ for WebAssembly

2022-02-10 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder closed this revision. tbaeder added a comment. I screwed up using the right Differential Revision link, but this landed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117888/new/ https://reviews.llvm.org/D117888 ___

[PATCH] D117681: [RISCV] Add the policy operand for some masked RVV ternary IR intrinsics.

2022-02-10 Thread Zakk Chen via Phabricator via cfe-commits
khchen added a comment. Gentle ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117681/new/ https://reviews.llvm.org/D117681 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.

[PATCH] D117989: [RISCV] Add the passthru operand for RVV nomask binary intrinsics.

2022-02-10 Thread Zakk Chen via Phabricator via cfe-commits
khchen added a comment. Gentle ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117989/new/ https://reviews.llvm.org/D117989 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.

[PATCH] D119509: [analyzer] Fix a crash in NoStateChangeVisitor with body-farmed stack frames.

2022-02-10 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. I dont even see why should the no-state-changed-visitor attempt to do anything with that call. It should have disarm itself when it reaches the allocation. It its not the case, we should probably consider fixing that as well in a followup. Please consider rearranging th

[PATCH] D110869: [X86] Implement -fzero-call-used-regs option

2022-02-10 Thread Bill Wendling via Phabricator via cfe-commits
void added a comment. In D110869#3312360 , @RKSimon wrote: > @void This buildbot appears to be still broken due to this change: > https://lab.llvm.org/buildbot/#/builders/110/builds/10271 Strange...This is the first time seeing something like this. I'll

[PATCH] D108189: [RISCV] Support experimental 'P' extension 0.96

2022-02-10 Thread Jim Lin via Phabricator via cfe-commits
Jim updated this revision to Diff 407770. Jim added a comment. Herald added a subscriber: pcwang-thead. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108189/new/ https://reviews.llvm.org/D108189 Files: clang/test/Driver/riscv-arch.c cla

[PATCH] D93298: [RISCV] add the MC layer support of Zfinx extension

2022-02-10 Thread Jim Lin via Phabricator via cfe-commits
Jim added inline comments. Comment at: llvm/lib/Target/RISCV/RISCVRegisterInfo.td:557 + +let RegInfos = RegInfoByHwMode<[RV64], [RegInfo<64, 64, 64>]> in +def GPRPF64 : RegisterClass<"RISCV", [f64], 64, (add Is register pair only on RV32 for used as f64? Reposi

[PATCH] D119216: [AMDGPU] replace hostcall module flag with function attribute

2022-02-10 Thread Sameer Sahasrabuddhe via Phabricator via cfe-commits
sameerds updated this revision to Diff 407762. sameerds added a comment. use AAPointerInfo; add more tests to demonstrate the same Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119216/new/ https://reviews.llvm.org/D119216 Files: clang/lib/CodeGe

[PATCH] D119509: [analyzer] Fix a crash in NoStateChangeVisitor with body-farmed stack frames.

2022-02-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: Szelethus, t-rasmud, martong, steakhal, ASDenysPetrov, balazske, gamesh411. Herald added subscribers: manas, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, kristof.beyls, xazax.hun. NoQ requested review of this

[clang] d796901 - [C++20] [Modules] Check if modulemap exists to avoid crash in implicit used C++ module

2022-02-10 Thread Chuanqi Xu via cfe-commits
Author: ZezhengLi Date: 2022-02-11T11:22:50+08:00 New Revision: d7969012e40a0906512b5bb304fc8b245386bb15 URL: https://github.com/llvm/llvm-project/commit/d7969012e40a0906512b5bb304fc8b245386bb15 DIFF: https://github.com/llvm/llvm-project/commit/d7969012e40a0906512b5bb304fc8b245386bb15.diff LOG

[clang] ce42082 - [Analyzer] Re-enables trustnonnullchecker_test.m

2022-02-10 Thread Rashmi Mudduluru via cfe-commits
Author: Rashmi Mudduluru Date: 2022-02-10T18:52:48-08:00 New Revision: ce420820c815e806bab9c5f17cb3b829a616548a URL: https://github.com/llvm/llvm-project/commit/ce420820c815e806bab9c5f17cb3b829a616548a DIFF: https://github.com/llvm/llvm-project/commit/ce420820c815e806bab9c5f17cb3b829a616548a.di

[PATCH] D119271: CGCall: also emit LLVM `allocalign` attribute when handling AllocAlign

2022-02-10 Thread James Y Knight via Phabricator via cfe-commits
jyknight added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:4605 + TryEmitAsCallSiteAttribute(const llvm::AttributeList &Attrs) { +llvm::AttributeList NewAttrs = Attrs; +if (AA) We do need to fallback to an assume for "if(CGF.SanOpts.has(Sa

[PATCH] D119362: [NFC] Make file offsets a regex to handle CRLF

2022-02-10 Thread Chris Bieneman 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 rG6d8e5c968538: [NFC] Make file offsets a regex to handle CRLF (authored by beanz). Changed prior to commit: https://reviews.llvm.org/D119362?vs=407

[clang] e487ddc - [clang][OpaquePtr] Use proper Address constructor in AtomicInfo::getAtomicAddress()

2022-02-10 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2022-02-10T18:29:51-08:00 New Revision: e487ddc5c6d38522b7a2cf2c686539aa74432f1e URL: https://github.com/llvm/llvm-project/commit/e487ddc5c6d38522b7a2cf2c686539aa74432f1e DIFF: https://github.com/llvm/llvm-project/commit/e487ddc5c6d38522b7a2cf2c686539aa74432f1e.diff

[PATCH] D119426: [C++20] [Modules] Check if modulemap exists to avoid crash in implicit used C++ module

2022-02-10 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu accepted this revision. ChuanqiXu added a comment. This revision is now accepted and ready to land. LGTM. It should be always good to avoid crash. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119426/new/ https://reviews.llvm.org/D119426 __

[PATCH] D119479: [clang][extract-api] Add global record support

2022-02-10 Thread Zixu Wang via Phabricator via cfe-commits
zixuw updated this revision to Diff 407716. zixuw added a comment. Fix a Windows build failure where designated initializers are not available Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119479/new/ https://reviews.llvm.org/D119479 Files: clan

[PATCH] D119496: [Clang][OpaquePtr] Remove calls to deprecated Address constructor

2022-02-10 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks accepted this revision. aeubanks added a comment. This revision is now accepted and ready to land. lg, thanks! I was just looking at one of these when trying to build Chrome with opaque pointers Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D118573: [clang][WebAssemmbly] Call TargetInfo::adjust in derived method.

2022-02-10 Thread Sam Clegg 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 rGecbcefd693dd: [clang][WebAssemmbly] Call TargetInfo::adjust in derived method. (authored by sbc100). Repository: rG LLVM Github Monorepo CHANGES

[clang] ecbcefd - [clang][WebAssemmbly] Call TargetInfo::adjust in derived method.

2022-02-10 Thread Sam Clegg via cfe-commits
Author: Sam Clegg Date: 2022-02-10T16:04:06-08:00 New Revision: ecbcefd693dd62f9242618b3cf838565e829cc7f URL: https://github.com/llvm/llvm-project/commit/ecbcefd693dd62f9242618b3cf838565e829cc7f DIFF: https://github.com/llvm/llvm-project/commit/ecbcefd693dd62f9242618b3cf838565e829cc7f.diff LOG

[PATCH] D118573: [clang][WebAssemmbly] Call TargetInfo::adjust in derived method.

2022-02-10 Thread Derek Schuff via Phabricator via cfe-commits
dschuff accepted this revision. dschuff added a comment. This revision is now accepted and ready to land. Looks OK to me. All of these options handle explicit overrides to the ABI which I guess just didn't work before but doesn't change any defaults. We should probably put something in the emscr

[PATCH] D119481: run-clang-tidy: Fix infinite loop on windows

2022-02-10 Thread Fabian Keßler via Phabricator via cfe-commits
Febbe added a comment. I don't think I have commit rights, so someone of you also have to commit this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119481/new/ https://reviews.llvm.org/D119481 ___ cfe-c

[PATCH] D119496: [Clang][OpaquePtr] Remove calls to deprecated Address constructor

2022-02-10 Thread Richard Trieu via Phabricator via cfe-commits
rtrieu created this revision. rtrieu added reviewers: cfe-commits, aeubanks. rtrieu requested review of this revision. Herald added a reviewer: jdoerfert. Herald added a subscriber: sstefan1. Herald added a project: clang. Explicitly specify element type when constructing Address in CGExpr.cpp.

[PATCH] D118573: [clang][WebAssemmbly] Call TargetInfo::adjust in derived method.

2022-02-10 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. Oddly enough and emscripten user just reported an issue that this patch fixes: https://github.com/emscripten-core/emscripten/issues/16241 PTAL Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118573/new/ https://reviews.llvm.

[PATCH] D118855: [modules] Add a flag for TagDecl if it was a definition demoted to a declaration.

2022-02-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Ping. Swift PR testing is happy with this change and I've tested it successfully on >100 swift projects. So looks like this change is safe and does what it intends to do. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D11885

[clang] 26c5cf8 - Fix Windows build that fails if a class has a member with the same naem

2022-02-10 Thread David Blaikie via cfe-commits
Author: David Blaikie Date: 2022-02-10T15:27:31-08:00 New Revision: 26c5cf8fa031f5143fd180fdc8d9dbc26a88e89e URL: https://github.com/llvm/llvm-project/commit/26c5cf8fa031f5143fd180fdc8d9dbc26a88e89e DIFF: https://github.com/llvm/llvm-project/commit/26c5cf8fa031f5143fd180fdc8d9dbc26a88e89e.diff

[PATCH] D119493: Fixing surplus assert condition in EvaluateTemporary

2022-02-10 Thread zhouyizhou via Phabricator via cfe-commits
zhouyizhou created this revision. zhouyizhou added reviewers: rsmith, hokein. zhouyizhou requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. In LLVM/Clang Debug build, following code will trigger the assert to fire: typedef int I; void foo() {

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Shilei Tian via Phabricator via cfe-commits
tianshilei1992 marked an inline comment as done. tianshilei1992 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +//

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Shilei Tian via Phabricator via cfe-commits
tianshilei1992 updated this revision to Diff 407701. tianshilei1992 added a comment. remove the dummy node Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116261/new/ https://reviews.llvm.org/D116261 Files: clang/lib/CodeGen/CGStmtOpenMP.cpp cla

[clang] f927021 - Reland "[clang-cl] Support the /JMC flag"

2022-02-10 Thread Yuanfang Chen via cfe-commits
Author: Yuanfang Chen Date: 2022-02-10T15:16:17-08:00 New Revision: f927021410691bc2612cfb635b1d9cf9b94977e6 URL: https://github.com/llvm/llvm-project/commit/f927021410691bc2612cfb635b1d9cf9b94977e6 DIFF: https://github.com/llvm/llvm-project/commit/f927021410691bc2612cfb635b1d9cf9b94977e6.diff

[PATCH] D119479: [clang][extract-api] Add global record support

2022-02-10 Thread Zixu Wang via Phabricator via cfe-commits
zixuw updated this revision to Diff 407695. zixuw added a comment. Apply clang-format changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119479/new/ https://reviews.llvm.org/D119479 Files: clang/include/clang/AST/RawCommentList.h clang/incl

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Interestly, clang/llvm happily ignores noinline on static functions, gcc does not. https://godbolt.org/z/jr3Wx87rb CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119061/new/ https://reviews.llvm.org/D119061 ___ cfe-

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +// code gen. +unsigned DiagID = Diags.getCustomDiagID(

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Shilei Tian via Phabricator via cfe-commits
tianshilei1992 marked 2 inline comments as done. tianshilei1992 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +//

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. >> It would be good to check with a language expert if this can break some >> code. I'm thinking of situations when someone relies on a function being >> emitted (or not) and ending up with linking issues. I'm not an expert here, >> but this is a past concern I vaguely

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +// code gen. +unsigned DiagID = Diags.getCustomDiagID(

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Shilei Tian via Phabricator via cfe-commits
tianshilei1992 marked an inline comment as done. tianshilei1992 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +//

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-02-10 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D118428#3312440 , @paulkirth wrote: > Hi, > > We have two failing test cases on Fuchsia's clang canary builder on Windows > x64. > > LLVM :: Instrumentation/JustMyCode/jmc-instrument-x86.ll > LLVM :: Instrumentation/JustMyCode/

[clang] b380a31 - Revert "[clang-cl] Support the /JMC flag"

2022-02-10 Thread Yuanfang Chen via cfe-commits
Author: Yuanfang Chen Date: 2022-02-10T14:17:37-08:00 New Revision: b380a31de084a540cfa38b72e609b25ea0569bb7 URL: https://github.com/llvm/llvm-project/commit/b380a31de084a540cfa38b72e609b25ea0569bb7 DIFF: https://github.com/llvm/llvm-project/commit/b380a31de084a540cfa38b72e609b25ea0569bb7.diff

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Jakub Kuderski via Phabricator via cfe-commits
kuhar added a comment. In D119061#3312571 , @xbolva00 wrote: >>> Do you plan to also add inline and flatten? > > You mean always_inline? Yes, after noinline. The flatten call site attribute > - theoretically why not, but it needs to be reworked in LLVM (

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. >> Do you plan to also add inline and flatten? You mean always_inline? Yes, after noinline. The flatten call site attribute - theoretically why not, but it needs to be reworked in LLVM (like always_inline_recursively) before any patch like this one. >> When I worked o

[PATCH] D119366: [clangd] Use `ObjCProtocolLoc` for generalized ObjC protocol support

2022-02-10 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added inline comments. Comment at: clang-tools-extra/clangd/unittests/FindTargetTests.cpp:948 Code = R"cpp( +void test(id p); dgoldman wrote: > sammccall wrote: > > This new test case looks interesting, but can

[PATCH] D119184: [clang] [concepts] Check constrained-auto return types for void-returning functions

2022-02-10 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang/lib/Sema/SemaStmt.cpp:3816 +Context.getTrivialTypeSourceInfo(Context.VoidTy, ReturnLoc), ReturnLoc); +Expr *Dummy = R.get(); +DeduceAutoResult DAR = DeduceAutoType(OrigResultType, Dummy, Deduced); ---

[PATCH] D119481: run-clang-tidy: Fix infinite loop on windows

2022-02-10 Thread Fabian Keßler via Phabricator via cfe-commits
Febbe added a comment. Currently, only tested on Windows. This should also increase performance, since the path is canonicalized only once. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119481/new/ https://reviews.llvm.org/D119481 __

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Jakub Kuderski via Phabricator via cfe-commits
kuhar added a comment. Thanks for working on this, @xbolva00! I don't know this part of the codebase, so won't comment on the patch itself. Just a few questions/suggestions: 1. Do you plan to also add `inline` and `flatten`? 2. When I worked on my implementation, I remember that I also ran into

[PATCH] D119481: run-clang-tidy: Fix infinite loop on windows find_compilation_database checked only for "/" as exit point, but on windows, this root is impossible. Fixes #53642

2022-02-10 Thread Fabian Keßler via Phabricator via cfe-commits
Febbe created this revision. Herald added a subscriber: carlosgalvezp. Febbe requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D119481 Files: clang-tools-extra/cla

[PATCH] D119366: [clangd] Use `ObjCProtocolLoc` for generalized ObjC protocol support

2022-02-10 Thread David Goldman via Phabricator via cfe-commits
dgoldman updated this revision to Diff 407674. dgoldman added a comment. add hover test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119366/new/ https://reviews.llvm.org/D119366 Files: clang-tools-extra/clangd/FindTarget.cpp clang-tools-extra

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 planned changes to this revision. xbolva00 added a comment. Plan: 1. https://reviews.llvm.org/D119451 2. fix inliner in LLVM 3. continue with this patch CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119061/new/ https://reviews.llvm.org/D119061

[PATCH] D119366: [clangd] Use `ObjCProtocolLoc` for generalized ObjC protocol support

2022-02-10 Thread David Goldman via Phabricator via cfe-commits
dgoldman added inline comments. Comment at: clang-tools-extra/clangd/unittests/FindTargetTests.cpp:948 Code = R"cpp( +void test(id p); sammccall wrote: > This new test case looks interesting, but can we keep the old one too? It now fails, I thought this

[PATCH] D119479: [clang][extract-api] Add global record support

2022-02-10 Thread Zixu Wang via Phabricator via cfe-commits
zixuw created this revision. Herald added a subscriber: mgorny. zixuw requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add facilities for extract-api: - Structs/classes to hold collected API information: `APIRecord`, `API` - Structs/classes

[PATCH] D119462: [analyzer][NFCi] Use the correct BugType in CStringChecker.

2022-02-10 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. I would recommend not touching the unrelated lines, unless you have a clear motive. Other than that I think its fair to say that this must have been a bug. Ill check the report diff tomorrow, prior accepting this. Repository: rG LLVM Github Monorepo CHANGES SINCE L

[PATCH] D119165: [clang-tidy] Add processing lambda captures at bugprone-use-after-move check

2022-02-10 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. This is a subtle and complicated check I'm not so familiar with. I have some ideas but I'm not confident in the suggestions or if we're missing something. @mboehme is the expert on this check, he's OOO this week/next week. I'm happy to muddle along or we can wait for

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-02-10 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth added a comment. Hi, We have two failing test cases on Fuchsia's clang canary builder on Windows x64. LLVM :: Instrumentation/JustMyCode/jmc-instrument-x86.ll LLVM :: Instrumentation/JustMyCode/jmc-instrument.ll First seen here: https://luci-milo.appspot.com/ui/p/fuchsia/builders/to

[PATCH] D119476: Generalize and harmonize sub-expression traversal

2022-02-10 Thread Kim Gräsman via Phabricator via cfe-commits
kimgr added inline comments. Comment at: clang/lib/AST/Expr.cpp:1903 +// Skip over implicit nodes produced as part of semantic analysis. +// Designed for use with IgnoreExpreNodes. +Expr *ignoreImplicitSemaNodes(Expr *E) { Typo: IgnoreExpr*e*Nodes Repository:

[PATCH] D119477: Ignore FullExpr when traversing cast sub-expressions

2022-02-10 Thread Kim Gräsman via Phabricator via cfe-commits
kimgr added a subscriber: aaron.ballman. kimgr added a comment. @aaron.ballman This patch replaces https://reviews.llvm.org/D117391 as a potential solution for https://github.com/llvm/llvm-project/issues/53044. I can't swear that the new diagnostics in cxx2a-consteval.cpp are standards-conformi

[PATCH] D119184: [clang] [concepts] Check constrained-auto return types for void-returning functions

2022-02-10 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone marked an inline comment as not done. Quuxplusone added inline comments. Comment at: clang/lib/Sema/SemaStmt.cpp:3816 +Context.getTrivialTypeSourceInfo(Context.VoidTy, ReturnLoc), ReturnLoc); +Expr *Dummy = R.get(); +DeduceAutoResult DAR = DeduceAutoT

[PATCH] D119477: Ignore FullExpr when traversing cast sub-expressions

2022-02-10 Thread Kim Gräsman via Phabricator via cfe-commits
kimgr created this revision. kimgr requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Full-expressions are Sema-generated implicit nodes that cover constant-expressions and expressions-with-cleanup for temporaries. Ignore those as part of imp

[PATCH] D119476: Generalize and harmonize sub-expression traversal

2022-02-10 Thread Kim Gräsman via Phabricator via cfe-commits
kimgr added a subscriber: aaron.ballman. kimgr added a comment. @aaron.ballman First refactor to generalize and harmonize `getSubExprAsWritten` and `getConversionFunction`. As mentioned in the commit message, this is strictly speaking a functional change, but it should have no visible effect.

[PATCH] D119476: Generalize and harmonize sub-expression traversal

2022-02-10 Thread Kim Gräsman via Phabricator via cfe-commits
kimgr created this revision. Herald added a subscriber: kristof.beyls. kimgr requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. CastExpr::getSubExprAsWritten and getConversionFunction used to have disparate implementations to traverse the sub-

[PATCH] D110869: [X86] Implement -fzero-call-used-regs option

2022-02-10 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. @void This buildbot appears to be still broken due to this change: https://lab.llvm.org/buildbot/#/builders/110/builds/10271 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110869/new/ https://reviews.llvm.org/D110869 _

[PATCH] D116261: [Clang][OpenMP] Add support for compare capture in parser

2022-02-10 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11801-11807 + } else if (AtomicKind == OMPC_compare_capture) { +// TODO: For now we emit an error here and in emitOMPAtomicExpr we ignore +// code gen. +unsigned DiagID = Diags.getCustomDiagID(

[PATCH] D119184: [clang] [concepts] Check constrained-auto return types for void-returning functions

2022-02-10 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. This looks right to me, though I think we should spend a few more lines to preserve the nice diagnostics for simple cases. Comment at: clang/lib/Sema/SemaStmt.cpp:3593

[PATCH] D119470: [clang-tidy] Don't check decltype return types in `readability-const-return-type`

2022-02-10 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron added a comment. I think we don't need to update the docs (https://clang.llvm.org/extra/clang-tidy/checks/readability-const-return-type.html) Because a user would expect this behaviour. //If this review is eventually approved, kindly please merge the commit on my behalf =) As I don't have

[PATCH] D119470: [clang-tidy] Don't check decltype return types in `readability-const-return-type`

2022-02-10 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron created this revision. Izaron added reviewers: aaron.ballman, alexfh. Herald added subscribers: carlosgalvezp, xazax.hun. Izaron requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. The checker removes `const`s that are superf

[clang] 4ae83bb - Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS

2022-02-10 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2022-02-10T15:05:23-05:00 New Revision: 4ae83bb2b1e27628f6bd14d746aef964ed776d52 URL: https://github.com/llvm/llvm-project/commit/4ae83bb2b1e27628f6bd14d746aef964ed776d52 DIFF: https://github.com/llvm/llvm-project/commit/4ae83bb2b1e27628f6bd14d746aef964ed776d52.diff

[libunwind] 4ae83bb - Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS

2022-02-10 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2022-02-10T15:05:23-05:00 New Revision: 4ae83bb2b1e27628f6bd14d746aef964ed776d52 URL: https://github.com/llvm/llvm-project/commit/4ae83bb2b1e27628f6bd14d746aef964ed776d52 DIFF: https://github.com/llvm/llvm-project/commit/4ae83bb2b1e27628f6bd14d746aef964ed776d52.diff

[PATCH] D119351: Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS

2022-02-10 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 rG4ae83bb2b1e2: Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS (authored by ldionne). Repository: rG LLVM Github Monorepo

[PATCH] D119351: Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS

2022-02-10 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added inline comments. Comment at: bolt/docs/OptimizingClang.md:228-236 $ CPATH=${TOPLEV}/stage1/install/bin/ -$ cmake -G Ninja ${TOPLEV}/llvm-project/llvm -DLLVM_TARGETS_TO_BUILD=X86 \ +$ cmake -G Ninja -S ${TOPLEV}/llvm-project/llvm -B ${TOPLEV}/stage2-prof-gen \ +

[PATCH] D119351: Update all LLVM documentation mentioning runtimes in LLVM_ENABLE_PROJECTS

2022-02-10 Thread Louis Dionne via Phabricator via cfe-commits
ldionne updated this revision to Diff 407631. ldionne marked 2 inline comments as done. ldionne added a comment. Address review comments. I'm going to commit this and cherry-pick onto release/14.x Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D11935

[PATCH] D119366: [clangd] Use `ObjCProtocolLoc` for generalized ObjC protocol support

2022-02-10 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. LG, thanks! You might want to check out how hover behaves and add a test there. Comment at: clang-tools-extra/clangd/unittests/FindTargetTests.cpp:948 Code = R"cpp

[PATCH] D99134: Lambdas are not necessarily locals. This resolves DR48250.

2022-02-10 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. LGTM. Please also add something like this as a unit test: In D99134#2643441 , @rsmith wrote: > template int x = [](auto){ return T(); }.operator()(T()); > int y = x; Repository: rG LLVM Githu

[PATCH] D119462: resolve the bugtype typo inside emitAdditionOverflowbug function in CStringChecker.cpp.

2022-02-10 Thread Shivam Rajput via Phabricator via cfe-commits
phyBrackets updated this revision to Diff 407623. phyBrackets added a comment. Use the git blame Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119462/new/ https://reviews.llvm.org/D119462 Files: clang/lib/StaticAnalyzer/Checkers/CStringChecker.c

[clang-tools-extra] 100ec80 - [clang-tidy] Add early exit for defaulted FunctionDecls

2022-02-10 Thread Kirill Bobyrev via cfe-commits
Author: Kirill Bobyrev Date: 2022-02-10T20:29:26+01:00 New Revision: 100ec80ab5a6a01071771b67fc2141640d0984da URL: https://github.com/llvm/llvm-project/commit/100ec80ab5a6a01071771b67fc2141640d0984da DIFF: https://github.com/llvm/llvm-project/commit/100ec80ab5a6a01071771b67fc2141640d0984da.diff

[PATCH] D119363: [clang] Add `ObjCProtocolLoc` to represent protocol references

2022-02-10 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a subscriber: akyrtzi. sammccall added a comment. Thanks @akyrtzi @egorzhdan I was going to suggest that I think someone at Apple should probably look at changes here first. The goal here is to ensure that any tokens in the code that reference a decl have some AST node (which ca

[PATCH] D119461: [compiler-rt] Fix endianness in get_sock_peer_name test

2022-02-10 Thread Michał Górny 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 rGc65fb0cdf262: [compiler-rt] Fix endianness in get_sock_peer_name test (authored by mgorny). Herald added a project: Sanitizers. Herald added a subscr

[PATCH] D119461: [compiler-rt] Fix endianness in get_sock_peer_name test

2022-02-10 Thread Michał Górny via Phabricator via cfe-commits
mgorny added a comment. Thanks for the prompt review! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119461/new/ https://reviews.llvm.org/D119461 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D119461: [compiler-rt] Fix endianness in get_sock_peer_name test

2022-02-10 Thread Michał Górny via Phabricator via cfe-commits
mgorny added a comment. @vitalybuka, I suspect this might also fix the test on Android but I don't have an environment to test it. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119461/new/ https://reviews.llvm.org/D119461 ___ cfe-commits mai

[PATCH] D119462: resolve the bugtype typo inside emitAdditionOverflowbug function

2022-02-10 Thread Shivam Rajput via Phabricator via cfe-commits
phyBrackets created this revision. Herald added a subscriber: martong. phyBrackets requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D119462 Files: clang/lib/StaticAnalyzer/Ch

[PATCH] D119461: [compiler-rt] Fix endianness in get_sock_peer_name test

2022-02-10 Thread Michał Górny via Phabricator via cfe-commits
mgorny created this revision. mgorny added reviewers: tamird, vitalybuka. Herald added a subscriber: dberris. mgorny requested review of this revision. Fix passing the port and IP address with the wrong endianness in get_sock_peer_name() that causes the connect() to fail inside without an outgoing

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-02-10 Thread Yuanfang Chen via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. ychen marked an inline comment as done. Closed by commit rGbd3a1de683f8: [clang-cl] Support the /JMC flag (authored by ychen). Changed prior to commit: https://revie

[clang] bd3a1de - [clang-cl] Support the /JMC flag

2022-02-10 Thread Yuanfang Chen via cfe-commits
Author: Yuanfang Chen Date: 2022-02-10T10:26:30-08:00 New Revision: bd3a1de683f80d174ea9c97000db3ec3276bc022 URL: https://github.com/llvm/llvm-project/commit/bd3a1de683f80d174ea9c97000db3ec3276bc022 DIFF: https://github.com/llvm/llvm-project/commit/bd3a1de683f80d174ea9c97000db3ec3276bc022.diff

[PATCH] D119301: [AArch64][ARM] add -Wunaligned-access only for clang

2022-02-10 Thread Yuanfang Chen 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 rGb96106af3f55: [AArch64][ARM] add -Wunaligned-access only for clang (authored by ychen). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[clang] b96106a - [AArch64][ARM] add -Wunaligned-access only for clang

2022-02-10 Thread Yuanfang Chen via cfe-commits
Author: Yuanfang Chen Date: 2022-02-10T10:26:30-08:00 New Revision: b96106af3f557da833b5e3b9ef9194c23ecd1596 URL: https://github.com/llvm/llvm-project/commit/b96106af3f557da833b5e3b9ef9194c23ecd1596 DIFF: https://github.com/llvm/llvm-project/commit/b96106af3f557da833b5e3b9ef9194c23ecd1596.diff

[PATCH] D119419: [clang-format] Do not remove required spaces when aligning tokens.

2022-02-10 Thread Marek Kurdej via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6c7e6fc7b665: [clang-format] Do not remove required spaces when aligning tokens. (authored by curdeius). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119419

[clang] 6c7e6fc - [clang-format] Do not remove required spaces when aligning tokens.

2022-02-10 Thread Marek Kurdej via cfe-commits
Author: Marek Kurdej Date: 2022-02-10T19:15:27+01:00 New Revision: 6c7e6fc7b6654b7ecd364f352f8ffd6dfecbf77b URL: https://github.com/llvm/llvm-project/commit/6c7e6fc7b6654b7ecd364f352f8ffd6dfecbf77b DIFF: https://github.com/llvm/llvm-project/commit/6c7e6fc7b6654b7ecd364f352f8ffd6dfecbf77b.diff

[PATCH] D116514: [clangd] Add code action to generate a constructor for a C++ class

2022-02-10 Thread Adrian Vogelsgesang via Phabricator via cfe-commits
avogelsgesang added a comment. Can we add this tweak as the default "fix-it" action for > Class '...' does not declare any constructor to initialize its non-modifiable > me on structs like struct X { int& a; } ? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION htt

[PATCH] D119257: Revert "Re-land [LLD] Remove global state in lldCommon"

2022-02-10 Thread Krzysztof Drewniak via Phabricator via cfe-commits
krzysz00 abandoned this revision. krzysz00 added a comment. Worked around elsewhere, more permanent fix pending, abandoning Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119257/new/ https://reviews.llvm.org/D119257

[PATCH] D119061: [Clang] noinline call site attribute

2022-02-10 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added inline comments. Comment at: clang/test/Sema/attr-noinline.cpp:14 +} + +[[clang::noinline]] static int i = bar(); // expected-error {{'noinline' attribute only applies to functions and statements}} xbolva00 wrote: > aaron.ballman wrote: > > xbolva

[PATCH] D118755: [clangd] Crash in __memcmp_avx2_movbe

2022-02-10 Thread Ivan Murashko via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG71d7c8d870db: [clangd] Crash in __memcmp_avx2_movbe (authored by ivanmurashko). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118755/new/ https://reviews.ll

[clang] 71d7c8d - [clangd] Crash in __memcmp_avx2_movbe

2022-02-10 Thread Ivan Murashko via cfe-commits
Author: Ivan Murashko Date: 2022-02-10T09:40:44-08:00 New Revision: 71d7c8d870db3b2da1fe1b3f54be77163c55dcd2 URL: https://github.com/llvm/llvm-project/commit/71d7c8d870db3b2da1fe1b3f54be77163c55dcd2 DIFF: https://github.com/llvm/llvm-project/commit/71d7c8d870db3b2da1fe1b3f54be77163c55dcd2.diff

[PATCH] D119446: [clang-cl] Accept the "legacy'"-target flag spelling

2022-02-10 Thread Hans Wennborg 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 rG8baa076dffa3: [clang-cl] Accept the "legacy" -target flag spelling (authored by hans). Changed prior to commit: https://reviews.llvm.org/D119446?v

[clang] 8baa076 - [clang-cl] Accept the "legacy" -target flag spelling

2022-02-10 Thread Hans Wennborg via cfe-commits
Author: Hans Wennborg Date: 2022-02-10T18:27:30+01:00 New Revision: 8baa076dffa381baa1f190356b4be5b0cc3bf13e URL: https://github.com/llvm/llvm-project/commit/8baa076dffa381baa1f190356b4be5b0cc3bf13e DIFF: https://github.com/llvm/llvm-project/commit/8baa076dffa381baa1f190356b4be5b0cc3bf13e.diff

[PATCH] D119301: [AArch64][ARM] add -Wunaligned-access only for clang

2022-02-10 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 407571. ychen added a comment. - Remove `CmdArgs` from `arm::getARMTargetFeatures` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119301/new/ https://reviews.llvm.org/D119301 Files: clang/lib/Driver/ToolChains/

[PATCH] D119271: CGCall: also emit LLVM `allocalign` attribute when handling AllocAlign

2022-02-10 Thread Augie Fackler via Phabricator via cfe-commits
durin42 added inline comments. Comment at: clang/test/CodeGen/alloc-align-attr.c:14 // CHECK-NEXT:[[CASTED_ALIGN:%.*]] = zext i32 [[TMP0]] to i64 // CHECK-NEXT:call void @llvm.assume(i1 true) [ "align"(i32* [[CALL]], i64 [[CASTED_ALIGN]]) ] // CHECK-NEXT:[[TMP1:%.

[PATCH] D117355: [PowerPC] Fix the undef virtual register reading failure for PPC backend trap optimization

2022-02-10 Thread Amy Kwan via Phabricator via cfe-commits
amyk added inline comments. Comment at: llvm/lib/Target/PowerPC/PPCMIPeephole.cpp:432 if (EnableTrapOptimization && TrapOpt) { +bool IsVReg = +(MI.getNumOperands() && MI.getOperand(0).isReg()) amyk wrote: > Might be good to pull out `MI

[PATCH] D119375: [Clang][Sema] Do not evaluate value-dependent immediate invocations

2022-02-10 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron updated this revision to Diff 407564. Izaron added a comment. Add test comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119375/new/ https://reviews.llvm.org/D119375 Files: clang/lib/Sema/SemaExpr.cpp clang/test/SemaCXX/cxx2a-const

[PATCH] D119447: [clang][dataflow] Include terminator statements in buildStmtToBasicBlockMap

2022-02-10 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev created this revision. sgatev added reviewers: ymandel, xazax.hun, gribozavr2. Herald added subscribers: tschuett, steakhal, rnkovacs. sgatev requested review of this revision. Herald added a project: clang. This will be necessary later when we add support for evaluating logic expressions s

[PATCH] D99134: Lambdas are not necessarily locals. This resolves DR48250.

2022-02-10 Thread Joe Loser via Phabricator via cfe-commits
jloser added a comment. Would love to see this cherry-picked into the llvm 14 release branch if possible! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99134/new/ https://reviews.llvm.org/D99134 ___ cfe

  1   2   >