[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Owen Pan via Phabricator via cfe-commits
owenpan added a comment. In D137181#3938913 , @goldstein.w.n wrote: > Anything left for me todo (can't imagine I have push access). See here . We will need your name and email. Repository:

[PATCH] D138350: [scudo] Add loongarch64 support for scudo

2022-11-18 Thread Youling Tang via Phabricator via cfe-commits
tangyouling created this revision. tangyouling added reviewers: cryptoad, eugenis, SixWeining, xen0n, xry111, MaskRay. Herald added subscribers: Enna1, StephenFan. Herald added a project: All. tangyouling requested review of this revision. Herald added projects: clang, Sanitizers. Herald added

[PATCH] D138137: [CodeGen][ARM] Fix ARMABIInfo::EmitVAAarg crash with empty record type variadic arg

2022-11-18 Thread Lin Yurong via Phabricator via cfe-commits
yronglin added a comment. Thank you so much for your review, @rjmccall Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138137/new/ https://reviews.llvm.org/D138137 ___ cfe-commits mailing list

[PATCH] D138137: [CodeGen][ARM] Fix ARMABIInfo::EmitVAAarg crash with empty record type variadic arg

2022-11-18 Thread Gold Cat via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG80f444646c62: [CodeGen][ARM] Fix ARMABIInfo::EmitVAAarg crash with empty record type variadic… (authored by yronglin, committed by objwyh). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[clang] 80f4446 - [CodeGen][ARM] Fix ARMABIInfo::EmitVAAarg crash with empty record type variadic arg

2022-11-18 Thread via cfe-commits
Author: yronglin Date: 2022-11-19T15:14:10+08:00 New Revision: 80f444646c62ccc8b2399d60ac91e62e6e576da6 URL: https://github.com/llvm/llvm-project/commit/80f444646c62ccc8b2399d60ac91e62e6e576da6 DIFF: https://github.com/llvm/llvm-project/commit/80f444646c62ccc8b2399d60ac91e62e6e576da6.diff

[PATCH] D137826: [clang] Allow comparing pointers to string literals

2022-11-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/ExprConstant.cpp:12951-12954 + // ObjC's @encode() + if (isa(E->getLHS()->IgnoreParenImpCasts()) || + isa(E->getRHS()->IgnoreParenImpCasts())) return Error(E); tahonermann

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n marked an inline comment as done. goldstein.w.n added a comment. In D137181#3938904 , @owenpan wrote: > LGTM Awesome! Thanks for sticking with it through all these revisions :) Anything left for me todo (can't imagine I have push access).

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Owen Pan via Phabricator via cfe-commits
owenpan accepted this revision. owenpan 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/D137181/new/ https://reviews.llvm.org/D137181

[PATCH] D137488: [clang][Interp] Array initialization via string literal

2022-11-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/Interp/ByteCodeExprGen.cpp:1098-1099 + +unsigned N = SL->getLength(); +for (size_t I = 0; I != NumElems; ++I) { + uint32_t CodePoint = I < N ? SL->getCodeUnit(I) : 0; tahonermann wrote: >

[PATCH] D137488: [clang][Interp] Array initialization via string literal

2022-11-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder updated this revision to Diff 476660. tbaeder marked 3 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137488/new/ https://reviews.llvm.org/D137488 Files: clang/lib/AST/Interp/ByteCodeExprGen.cpp clang/test/AST/Interp/literals.cpp Index:

[PATCH] D138249: [WebAssembly] Update relaxed-simd instruction names

2022-11-18 Thread Marat Dukhan via Phabricator via cfe-commits
maratyszcza accepted this revision. maratyszcza added a comment. Intrinsic naming LGTM. Not qualified to review the rest. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138249/new/ https://reviews.llvm.org/D138249

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n marked 2 inline comments as done. goldstein.w.n added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:838 + // If this changes PPLevel needs to be used for get correct indentation. + assert(!Line.InMacroBody && !InPPDirective); return

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n marked an inline comment as done. goldstein.w.n added a comment. In D137181#3938771 , @owenpan wrote: > In D137181#3935951 , @owenpan wrote: > >> In D137181#3935856

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n updated this revision to Diff 476654. goldstein.w.n added a comment. 1. Updating D137181 : [clang-format] Don't use 'PPIndentWidth' inside multi-line macros # 2. Enter a brief description of the changes included in this update. 3. The first line

[PATCH] D138278: TableGen: honor LLVM_LINK_LLVM_DYLIB by default

2022-11-18 Thread Stephen Neuendorffer via Phabricator via cfe-commits
stephenneuendorffer added a comment. I think the MLIR parts of this code were written before attempting to create libMLIR.so. Probably these tablegen binaries would have to also avoid linking against libMLIR.so and be statically linked to both llvmSupport and MLIRsupport to work properly.

[PATCH] D137753: [Clang][GNU][AIX][p]Enable -p Functionality

2022-11-18 Thread Michael Francis via Phabricator via cfe-commits
francii updated this revision to Diff 476649. francii added a comment. Remove Linux changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137753/new/ https://reviews.llvm.org/D137753 Files: clang/include/clang/Basic/CodeGenOptions.def

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Owen Pan via Phabricator via cfe-commits
owenpan added a comment. In D137181#3935951 , @owenpan wrote: > In D137181#3935856 , @goldstein.w.n > wrote: > >> I could remove either the `PPDIS_BeforeHash` or `PPDIS_AfterHash` though as >> the they really

[PATCH] D137473: [vfs] Allow root paths relative to the directory of the vfsoverlay YAML file

2022-11-18 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: llvm/lib/Support/VirtualFileSystem.cpp:1933-1935 path_style = sys::path::is_absolute(Name, sys::path::Style::posix) ? sys::path::Style::posix :

[PATCH] D136176: Implement support for option 'fexcess-precision'.

2022-11-18 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. At some point, we're going to have to figure out how this impacts `FLT_EVAL_METHOD`, but we can do that in a separate patch. Comment at: clang/docs/UsersManual.rst:1732 +.. option:: -fexcess-precision: + + By default, Clang uses excess precision to

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 closed this revision. jyu2 added a comment. checked with 9d90cf2fca44 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138312/new/ https://reviews.llvm.org/D138312

[clang] 9d90cf2 - [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Jennifer Yu via cfe-commits
Author: Jennifer Yu Date: 2022-11-18T17:59:23-08:00 New Revision: 9d90cf2fca4446f5c227f6e3217e96c00665cb72 URL: https://github.com/llvm/llvm-project/commit/9d90cf2fca4446f5c227f6e3217e96c00665cb72 DIFF: https://github.com/llvm/llvm-project/commit/9d90cf2fca4446f5c227f6e3217e96c00665cb72.diff

[PATCH] D138088: [clang][docs] Use `option` directive in User's Manual

2022-11-18 Thread KAWASHIMA Takahiro via Phabricator via cfe-commits
kawashima-fj added a comment. In D138088#3937680 , @aaron.ballman wrote: > Thank you for this cleanup! In general, I thin this looks correct. However, I > know we've had to fix a bunch of options that cause the sphinx build to fail > (IIRC, oftentimes

[PATCH] D138329: [-Wunsafe-buffer-usage] Add a new recursive matcher to replace `forEachDescendant` in unsafe buffer check

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 added a comment. In D138329#3938351 , @xazax.hun wrote: > Is the problem `forEachDescendant` matching statements inside blocks and > lambdas? I wonder if this behavior would surprise people, so I think it would > be better to: > > -

[PATCH] D137872: Try to implement lambdas with inalloca parameters by forwarding without use of inallocas.

2022-11-18 Thread Amy Huang via Phabricator via cfe-commits
akhuang added a comment. In D137872#3925723 , @efriedma wrote: > I'm not quite sure I understand what's happening here. Does this actually > avoid generating two copies of the function body if both the call operator > and the conversion are used?

[PATCH] D137872: Try to implement lambdas with inalloca parameters by forwarding without use of inallocas.

2022-11-18 Thread Amy Huang via Phabricator via cfe-commits
akhuang updated this revision to Diff 476634. akhuang added a comment. cleanup Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137872/new/ https://reviews.llvm.org/D137872 Files: clang/include/clang/CodeGen/CGFunctionInfo.h

[PATCH] D138263: [clang-format] Supress aligning of trailing namespace comments

2022-11-18 Thread Owen Pan via Phabricator via cfe-commits
owenpan added a comment. Something like the following: diff --git a/clang/lib/Format/FormatToken.h b/clang/lib/Format/FormatToken.h index 87515372046d..3dc5e411df55 100644 --- a/clang/lib/Format/FormatToken.h +++ b/clang/lib/Format/FormatToken.h @@ -98,6 +98,8 @@ namespace format {

[PATCH] D138073: [clang-doc] Move file layout to the generators.

2022-11-18 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth accepted this revision. paulkirth added a comment. This revision is now accepted and ready to land. This is mostly LGTM, modulo the small change to the test that I've suggested. Assuming the presubmit tests still pass with that small edit, you're good on my end.

[PATCH] D137872: Try to implement lambdas with inalloca parameters by forwarding without use of inallocas.

2022-11-18 Thread Amy Huang via Phabricator via cfe-commits
akhuang updated this revision to Diff 476633. akhuang added a comment. Clean up existing code and add code to make the call operator also call the new function. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137872/new/

[PATCH] D138328: [OpenMP] Initial parsing and semantic analysis support for 'strict' modifier with 'num_tasks' clause on 'taskloop' construct

2022-11-18 Thread Mike Rice via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG56c166017055: [OpenMP] Initial parsing/sema for strict modifier with num_tasks clause (authored by mdfazlay, committed by mikerice). Herald added a project: clang. Herald added a subscriber: cfe-commits.

[clang] 56c1660 - [OpenMP] Initial parsing/sema for 'strict' modifier with 'num_tasks' clause

2022-11-18 Thread Mike Rice via cfe-commits
Author: Fazlay Rabbi Date: 2022-11-18T16:26:47-08:00 New Revision: 56c166017055595a9f26933e85bfd89e30c528d0 URL: https://github.com/llvm/llvm-project/commit/56c166017055595a9f26933e85bfd89e30c528d0 DIFF: https://github.com/llvm/llvm-project/commit/56c166017055595a9f26933e85bfd89e30c528d0.diff

[PATCH] D137826: [clang] Allow comparing pointers to string literals

2022-11-18 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added inline comments. Comment at: clang/lib/AST/ExprConstant.cpp:12951-12954 + // ObjC's @encode() + if (isa(E->getLHS()->IgnoreParenImpCasts()) || + isa(E->getRHS()->IgnoreParenImpCasts())) return Error(E); tbaeder

[PATCH] D138337: Add support for kcfi-seal optimization with LTO

2022-11-18 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen added reviewers: nickdesaulniers, pcc, MaskRay, kees, joaomoreira. samitolvanen added a comment. Herald added a subscriber: StephenFan. ClangBuiltLinux issue: https://github.com/ClangBuiltLinux/linux/issues/1737 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D138337: Add support for kcfi-seal optimization with LTO

2022-11-18 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen created this revision. Herald added subscribers: pengfei, hiraditya, inglorion. Herald added a project: All. samitolvanen requested review of this revision. Herald added subscribers: llvm-commits, cfe-commits, MaskRay. Herald added projects: clang, LLVM. With -fsanitize=kcfi, Clang

[PATCH] D129531: [clang][C++20] P0960R3 and P1975R0: Allow initializing aggregates from a parenthesized list of values

2022-11-18 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao added inline comments. Comment at: clang/lib/AST/JSONNodeDumper.cpp:852 case VarDecl::ListInit: JOS.attribute("init", "list"); break; +case VarDecl::ParenListInit: + JOS.attribute("init", "paren-list"); ilya-biryukov wrote: > NIT: maybe use

[PATCH] D129531: [clang][C++20] P0960R3 and P1975R0: Allow initializing aggregates from a parenthesized list of values

2022-11-18 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao updated this revision to Diff 476625. ayzhao marked 9 inline comments as done. ayzhao added a comment. address code review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129531/new/ https://reviews.llvm.org/D129531 Files:

[PATCH] D138326: [CodeView] Don't generate dummy unnamed strcut/class/union type.

2022-11-18 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added a comment. In D138326#3938128 , @rnk wrote: > Since Clang creates the member list and only adds types for the benefit of > codeview, should we change clang instead? Yes, that's something clang does only for codeview, changed in clang

[PATCH] D137753: [Clang][GNU][AIX][p]Enable -p Functionality

2022-11-18 Thread Michael Francis via Phabricator via cfe-commits
francii added a comment. In D137753#3935391 , @MaskRay wrote: > In D137753#3935305 , @francii wrote: > >> Recall that the goal with `-p` is to create parity with GCC (at least with >> Linux and AIX), as per the

[PATCH] D138326: [CodeView] Don't generate dummy unnamed strcut/class/union type.

2022-11-18 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 476621. zequanwu added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. Reverted previous change and change clang side so that it doesn't emit nested anonymous record type when emitting code-view. Repository: rG LLVM

[PATCH] D137488: [clang][Interp] Array initialization via string literal

2022-11-18 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added inline comments. Comment at: clang/lib/AST/Interp/ByteCodeExprGen.cpp:1098-1099 + +unsigned N = SL->getLength(); +for (size_t I = 0; I != NumElems; ++I) { + uint32_t CodePoint = I < N ? SL->getCodeUnit(I) : 0; tahonermann wrote: >

[PATCH] D135411: Add generic KCFI operand bundle lowering

2022-11-18 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen updated this revision to Diff 476615. samitolvanen added a comment. Fixed clang-format warnings. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135411/new/ https://reviews.llvm.org/D135411 Files: clang/lib/CodeGen/BackendUtil.cpp

[PATCH] D138322: [Index] Add various missing USR generation

2022-11-18 Thread Ben Barham via Phabricator via cfe-commits
bnbarham updated this revision to Diff 476614. bnbarham added a comment. Add missing --target Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138322/new/ https://reviews.llvm.org/D138322 Files: clang/lib/Index/USRGeneration.cpp

[PATCH] D138073: [clang-doc] Move file layout to the generators.

2022-11-18 Thread Brett Wilson via Phabricator via cfe-commits
brettw added inline comments. Comment at: clang-tools-extra/clang-doc/HTMLGenerator.cpp:890-892 +// TODO If there are multiple Infos for this file name (for example, +// template specializations), this will generate multiple complete web pages +// (with and , etc.)

[PATCH] D138073: [clang-doc] Move file layout to the generators.

2022-11-18 Thread Brett Wilson via Phabricator via cfe-commits
brettw updated this revision to Diff 476612. brettw marked an inline comment as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138073/new/ https://reviews.llvm.org/D138073 Files: clang-tools-extra/clang-doc/Generators.h clang-tools-extra/clang-doc/HTMLGenerator.cpp

[PATCH] D138329: [-Wunsafe-buffer-usage] Add a new recursive matcher to replace `forEachDescendant` in unsafe buffer check

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Is the problem `forEachDescendant` matching statements inside blocks and lambdas? I wonder if this behavior would surprise people, so I think it would be better to: - Potentially add a template bool parameter to `forEachDescendant` controlling this behavior. -

[PATCH] D138321: [-Wunsafe-buffer-usage] Ignore array subscript on literal zero

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:219 +arraySubscriptExpr(hasBase(ignoringParenImpCasts(hasPointerType())), + unless(hasIndex(integerLiteral(equals(0) .bind("arraySubscr"));

[PATCH] D138318: [-Wunsafe-buffer-usage] Improve pointer match pattern

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:31-39 +hasType(pointerType()), +hasType(autoType( +hasDeducedType(hasUnqualifiedDesugaredType(pointerType(), +// DecayedType, e.g., array type in formal parameter

[PATCH] D138253: [-Wunsafe-buffer-usage] NFC: Implement fix-strategies and variable-use-claiming.

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:236 + using UseSetTy = SmallSet; + using DefMapTy = DenseMap; + NoQ wrote: > NoQ wrote: > > This extra payload wasn't advertised but it's very useful because it's hard > >

[PATCH] D137473: [vfs] Allow root paths relative to the directory of the vfsoverlay YAML file

2022-11-18 Thread Haowei Wu via Phabricator via cfe-commits
haowei added inline comments. Comment at: llvm/lib/Support/VirtualFileSystem.cpp:1922 + EC = FS->makeAbsolute(FullPath, Name); + Name = canonicalize(Name); +} else { bnbarham wrote: > Why the canonicalization? If the Name here somehow

[PATCH] D137379: [-Wunsafe-buffer-usage] Add warnings for unsafe buffer accesses by array subscript operations

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:168-169 + static Matcher matcher() { +// FIXME: What if the index is integer literal 0? Should this be +// a safe gadget in this case? +return stmt( As per some of

[PATCH] D137348: [-Wunsafe-buffer-usage] Introduce an abstraction for fixable code patterns.

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:70 + + virtual ~Gadget() {} + Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:107 +/// out of bounds. +class IncrementGadget : public UnsafeGadget { +

[PATCH] D138322: [Index] Add various missing USR generation

2022-11-18 Thread Ben Langmuir via Phabricator via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM once the test failure is fixed Comment at: clang/test/Index/index-builtin-sve.cpp:7 + +// RUN: c-index-test -index-file %s -target-feature +bf16

[PATCH] D136811: [-Wunsafe-buffer-usage] WIP: RFC: NFC: User documentation.

2022-11-18 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added a comment. This revision is now accepted and ready to land. Overall, the document looks good to me, I like the general direction. I still see some pending comments (mostly small wording fixes) from Aaron. Repository: rC Clang CHANGES SINCE

[PATCH] D138297: [Clang][OpenMP] Add default map type for target enter/exit data

2022-11-18 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 closed this revision. doru1004 added a comment. Commit: 9e595e911eb539caad99fd8642328007d47c6f4e CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138297/new/ https://reviews.llvm.org/D138297

[PATCH] D137473: [vfs] Allow root paths relative to the directory of the vfsoverlay YAML file

2022-11-18 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added subscribers: hans, compnerd, Bigcheese. rnk added inline comments. Comment at: llvm/unittests/Support/VirtualFileSystemTest.cpp:1878 + // with native path seperator, regardless of the actual path seperator + // used in YAMLFilePath field. +#ifndef _WIN32

[clang] 9e595e9 - [Clang][OpenMP] Add support for default to/from map types on target enter/exit data

2022-11-18 Thread Doru Bercea via cfe-commits
Author: Doru Bercea Date: 2022-11-18T16:12:35-06:00 New Revision: 9e595e911eb539caad99fd8642328007d47c6f4e URL: https://github.com/llvm/llvm-project/commit/9e595e911eb539caad99fd8642328007d47c6f4e DIFF: https://github.com/llvm/llvm-project/commit/9e595e911eb539caad99fd8642328007d47c6f4e.diff

[PATCH] D137996: Add support for a backdoor driver option that enables emitting header usage information in JSON to a file

2022-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Frontend/HeaderIncludeGen.cpp:289-290 +SrcMgr::CharacteristicKind NewFileType, FileID PrevFID) { + if (!shouldRecordNewFile(NewFileType, SM.getLocForStartOfFile(PrevFID), SM)) +return; + Hmm,

[PATCH] D138274: Add version to all LLVM cmake package

2022-11-18 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm accepted this revision. arsenm added a comment. This revision is now accepted and ready to land. I thought we had this already. The amount of boiler plate required repeated in each component is depressing, but I wouldn't be surprised if it's really needed Repository: rG LLVM Github

[PATCH] D138329: [-Wunsafe-buffer-usage] Add a new recursive matcher to replace `forEachDescendant` in unsafe buffer check

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 created this revision. ziqingluo-90 added reviewers: NoQ, jkorous, t-rasmud, malavikasamak, aaron.ballman, xazax.hun, gribozavr. Herald added a subscriber: rnkovacs. Herald added a project: All. ziqingluo-90 requested review of this revision. Herald added a project: clang. Herald

[PATCH] D136176: Implement support for option 'fexcess-precision'.

2022-11-18 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam updated this revision to Diff 476587. zahiraam marked 2 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D136176/new/ https://reviews.llvm.org/D136176 Files: clang/docs/UsersManual.rst clang/include/clang/Basic/FPOptions.def

[PATCH] D137473: [vfs] Allow root paths relative to the directory of the vfsoverlay YAML file

2022-11-18 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a subscriber: rnk. dexonsmith added inline comments. Comment at: llvm/unittests/Support/VirtualFileSystemTest.cpp:1878 + // with native path seperator, regardless of the actual path seperator + // used in YAMLFilePath field. +#ifndef _WIN32

[PATCH] D138321: [-Wunsafe-buffer-usage] Ignore array subscript on literal zero

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 updated this revision to Diff 476581. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138321/new/ https://reviews.llvm.org/D138321 Files: clang/lib/Analysis/UnsafeBufferUsage.cpp clang/test/SemaCXX/warn-unsafe-buffer-usage.cpp Index:

[PATCH] D138219: [include-cleaner] Show includes matched by refs in HTML report. Demo: https://htmlpreview.github.io/?https://gist.githubusercontent.com/sam-mccall/ecee6869e37af3db28089b64d8dce806/ra

2022-11-18 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D138219#3936279 , @hokein wrote: > Thanks, I like the idea of marking missing-include refs. > > I haven't read the code yet, and below are all my findings when I played with > the demo html (some of them are unrelated to

[PATCH] D138318: [-Wunsafe-buffer-usage] Improve pointer match pattern

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 updated this revision to Diff 476578. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138318/new/ https://reviews.llvm.org/D138318 Files: clang/lib/Analysis/UnsafeBufferUsage.cpp clang/test/SemaCXX/warn-unsafe-buffer-usage.cpp Index:

[PATCH] D137473: [vfs] Allow root paths relative to the directory of the vfsoverlay YAML file

2022-11-18 Thread Ben Barham via Phabricator via cfe-commits
bnbarham added inline comments. Comment at: llvm/lib/Support/VirtualFileSystem.cpp:1922 + EC = FS->makeAbsolute(FullPath, Name); + Name = canonicalize(Name); +} else { Why the canonicalization? Comment at:

[PATCH] D138322: [Index] Add various missing USR generation

2022-11-18 Thread Ben Barham via Phabricator via cfe-commits
bnbarham created this revision. bnbarham added a reviewer: arphaman. Herald added subscribers: frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar,

[PATCH] D138321: [-Wunsafe-buffer-usage] Ignore array subscript on literal zero

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 created this revision. ziqingluo-90 added reviewers: NoQ, jkorous, t-rasmud, malavikasamak, aaron.ballman, gribozavr, xazax.hun. Herald added a subscriber: rnkovacs. Herald added a project: All. ziqingluo-90 requested review of this revision. Herald added a project: clang. Herald

[PATCH] D138319: [analyzer] Prepare structures for integral cast feature introducing

2022-11-18 Thread Denys Petrov via Phabricator via cfe-commits
ASDenysPetrov created this revision. ASDenysPetrov added reviewers: NoQ, MaskRay, martong, steakhal. ASDenysPetrov added a project: clang. Herald added subscribers: manas, StephenFan, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun.

[PATCH] D138297: [Clang][OpenMP] Add default map type for target enter/exit data

2022-11-18 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138297/new/ https://reviews.llvm.org/D138297 ___ cfe-commits mailing list

[PATCH] D138297: [Clang][OpenMP] Add default map type for target enter/exit data

2022-11-18 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 marked an inline comment as done. doru1004 added inline comments. Comment at: clang/lib/Parse/ParseOpenMP.cpp:4367-4371 + if (getLangOpts().OpenMP >= 52) +if (DKind == OMPD_target_enter_data) + Data.ExtraModifier = OMPC_MAP_to; +else if

[PATCH] D138297: [Clang][OpenMP] Add default map type for target enter/exit data

2022-11-18 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 updated this revision to Diff 476560. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138297/new/ https://reviews.llvm.org/D138297 Files: clang/lib/Parse/ParseOpenMP.cpp clang/lib/Sema/SemaOpenMP.cpp clang/test/OpenMP/target_enter_data_ast_print.cpp

[PATCH] D138318: [-Wunsafe-buffer-usage] Improve pointer match pattern

2022-11-18 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 created this revision. ziqingluo-90 added reviewers: NoQ, jkorous, t-rasmud, malavikasamak, aaron.ballman, gribozavr, xazax.hun. Herald added a subscriber: rnkovacs. Herald added a project: All. ziqingluo-90 requested review of this revision. Herald added a project: clang. Herald

[PATCH] D138263: [clang-format] Supress aligning of trailing namespace comments

2022-11-18 Thread Owen Pan via Phabricator via cfe-commits
owenpan added a comment. In D138263#3937223 , @HazardyKnusperkeks wrote: > In D138263#3936536 , > @HazardyKnusperkeks wrote: > >> In D138263#3936007 , @owenpan >>

[PATCH] D138263: [clang-format] Supress aligning of trailing namespace comments

2022-11-18 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks planned changes to this revision. HazardyKnusperkeks added a comment. Working on the annotation. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138263/new/ https://reviews.llvm.org/D138263

[PATCH] D137944: [ObjC][ARC] Teach the OptimizeSequences step of ObjCARCOpts about WinEH funclet tokens

2022-11-18 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. I can't say I'm familiar with ARC, but this seems right to me. Comment at: llvm/lib/Transforms/ObjCARC/ObjCARCOpts.cpp:767 +const ColorVector = BlockColors.find(BB)->second; +assert(CV.size() == 1 && "non-unique color for block!"); +BasicBlock

[PATCH] D138316: [ASTContext] Avoid duplicating address space map. NFCI

2022-11-18 Thread Alexander Richardson via Phabricator via cfe-commits
arichardson created this revision. arichardson added reviewers: clang, pcc. Herald added a project: All. arichardson requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. ASTContext was holding onto a pointer to the Clang->LLVM address space map

[PATCH] D138081: [IR] Split out IR printing passes into IRPrinter

2022-11-18 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexander-shaposhnikov added inline comments. Comment at: utils/bazel/llvm-project-overlay/llvm/BUILD.bazel:918 ":Core", +":IRPrinter", ":IRReader", tejohnson wrote: > Per the follow on fix to D137768, I guess this one was unnecessary.

[PATCH] D137818: Add support for querying SubstTemplateTypeParm types

2022-11-18 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, thank you! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137818/new/ https://reviews.llvm.org/D137818

[PATCH] D138088: [clang][docs] Use `option` directive in User's Manual

2022-11-18 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thank you for this cleanup! In general, I thin this looks correct. However, I know we've had to fix a bunch of options that cause the sphinx build to fail (IIRC, oftentimes due to duplicate options) and our precommit CI doesn't test the documentation build. Did

[PATCH] D137885: [modules] Support zstd in .pcm file

2022-11-18 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:1457 + const llvm::compression::Format F = + Blob.size() >= 2 && memcmp(Blob.data(), "\x1f\x8b", 2) == 0 + ? llvm::compression::Format::Zlib MaskRay

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138312/new/ https://reviews.llvm.org/D138312

[PATCH] D138091: [Clang] Fix Sema::ClassifyName so that it classifies EnumConstantDecl as NonType when they are brought into scope via using enum

2022-11-18 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. Adding some more reviewers to get more eyes who may be familiar with this corner for the code. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138091/new/ https://reviews.llvm.org/D138091 ___ cfe-commits mailing list

[PATCH] D137885: [modules] Support zstd in .pcm file

2022-11-18 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay marked 2 inline comments as done. MaskRay added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:1457 + const llvm::compression::Format F = + Blob.size() >= 2 && memcmp(Blob.data(), "\x1f\x8b", 2) == 0 + ?

[clang] 7fc57d7 - Add more tests for C DRs and update the status page

2022-11-18 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2022-11-18T14:15:41-05:00 New Revision: 7fc57d7c97c64b64ef865d71343867ab30cfcf15 URL: https://github.com/llvm/llvm-project/commit/7fc57d7c97c64b64ef865d71343867ab30cfcf15 DIFF: https://github.com/llvm/llvm-project/commit/7fc57d7c97c64b64ef865d71343867ab30cfcf15.diff

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11048 SeverityClauses.empty() ? nullptr : (*SeverityClauses.begin()); + auto MessageClauses = + OMPExecutableDirective::getClausesOfKind(Clauses); ABataev wrote: > Use real type

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 476534. jyu2 added a comment. Thanks Alexey for the review. Address his comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138312/new/ https://reviews.llvm.org/D138312 Files:

[clang] f01b68e - [Hexagon] Add checks for immediate arguments for remaining builtins

2022-11-18 Thread Krzysztof Parzyszek via cfe-commits
Author: Krzysztof Parzyszek Date: 2022-11-18T11:09:41-08:00 New Revision: f01b68e4bee7ccf92f125b1100367804b43f6a7e URL: https://github.com/llvm/llvm-project/commit/f01b68e4bee7ccf92f125b1100367804b43f6a7e DIFF:

[PATCH] D138078: [SelectionDAGISel] split critical indirect edges from callbr w/ outputs

2022-11-18 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers updated this revision to Diff 476530. nickdesaulniers retitled this revision from "[CodeGenPrepare] split critical indirect edges from callbr w/ outputs" to "[SelectionDAGISel] split critical indirect edges from callbr w/ outputs". nickdesaulniers edited the summary of this

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:11048 SeverityClauses.empty() ? nullptr : (*SeverityClauses.begin()); + auto MessageClauses = + OMPExecutableDirective::getClausesOfKind(Clauses); Use real type instead of auto

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n added a comment. In D137181#3935951 , @owenpan wrote: > In D137181#3935856 , @goldstein.w.n > wrote: > >> In D137181#3935752 , @owenpan >> wrote: >> >>>

[PATCH] D137181: [clang-format] Don't use 'PPIndentWidth' inside multi-line macros

2022-11-18 Thread Noah Goldstein via Phabricator via cfe-commits
goldstein.w.n updated this revision to Diff 476528. goldstein.w.n added a comment. 1. Updating D137181 : [clang-format] Don't use 'PPIndentWidth' inside multi-line macros # 2. Enter a brief description of the changes included in this update. 3. The first line

[PATCH] D138296: [clang] Avoid duplicating ProgramAddressSpace in TargetInfo. NFCI

2022-11-18 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D138296#3937486 , @arichardson wrote: > In D138296#3937224 , @eandrews > wrote: > >> Functionally this looks ok to me. However I am not sure if CodeGenTypes is >> the 'right' place

[PATCH] D138312: [OPENMP5.1] Initial support for message clause.

2022-11-18 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: ABataev, jdoerfert, mikerice. jyu2 added a project: OpenMP. Herald added subscribers: arphaman, guansong, yaxunl. Herald added projects: Flang, All. jyu2 requested review of this revision. Herald added subscribers: llvm-commits, cfe-commits,

[PATCH] D137885: [modules] Support zstd in .pcm file

2022-11-18 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:1457 + const llvm::compression::Format F = + Blob.size() >= 2 && memcmp(Blob.data(), "\x1f\x8b", 2) == 0 + ? llvm::compression::Format::Zlib tschuett

[PATCH] D138247: PR58819: Correct linkage and mangling of lambdas in inline static member initializers

2022-11-18 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. In D138247#3936928 , @probinson wrote: > If this is specifically for C++17, I believe Sony doesn't officially support > that yet although I am checking. Cool, thanks! > It looks like this is only part of the fix for #58819?

[PATCH] D138137: [CodeGen][ARM] Fix ARMABIInfo::EmitVAAarg crash with empty record type variadic arg

2022-11-18 Thread Lin Yurong via Phabricator via cfe-commits
yronglin added a comment. Thank you so much for your review, @rjmccall , can you land this patch for me? Please use 'yronglin ' to commit the change. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138137/new/ https://reviews.llvm.org/D138137

[PATCH] D138296: [clang] Avoid duplicating ProgramAddressSpace in TargetInfo. NFCI

2022-11-18 Thread Alexander Richardson via Phabricator via cfe-commits
arichardson added a comment. In D138296#3937224 , @eandrews wrote: > Functionally this looks ok to me. However I am not sure if CodeGenTypes is > the 'right' place for this function to live, considering that other functions > with similar functionality

[clang] 7c47669 - [Hexagon] Add clang flags for v71, v71t, v73

2022-11-18 Thread Krzysztof Parzyszek via cfe-commits
Author: Krzysztof Parzyszek Date: 2022-11-18T09:39:47-08:00 New Revision: 7c476697e29988adcd25036d4e187cd2efcf0c6a URL: https://github.com/llvm/llvm-project/commit/7c476697e29988adcd25036d4e187cd2efcf0c6a DIFF:

[PATCH] D138258: clang/cmake: Fix incorrectly disabling tests when LLVM_EXTERNAL_LIT is used

2022-11-18 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added inline comments. Comment at: clang/CMakeLists.txt:97 # Seek installed Lit. -find_program(LLVM_LIT - NAMES llvm-lit lit.py lit - PATHS "${LLVM_MAIN_SRC_DIR}/utils/lit" - DOC "Path to lit.py") +if (NOT

[PATCH] D138258: clang/cmake: Fix incorrectly disabling tests when LLVM_EXTERNAL_LIT is used

2022-11-18 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. In D138258#3936260 , @kwk wrote: > As much as I would like this to be fixed. I vote against this patch because > in `lld/CMakeLists.txt` there's an almost (if not entirely) identical piece > of code >

[PATCH] D137205: [clang-tidy] Add performance-unnecessary-copy-on-last-use check

2022-11-18 Thread Oliver Stöneberg via Phabricator via cfe-commits
firewave added a comment. In D137205#3937298 , @Febbe wrote: > Does only a warning appear? Or also a fix? Currently, only a warning should > appear, but this is not fixable in c++11. There's no fix-it. I didn't realize that before. Maybe this should

  1   2   >