[PATCH] D138651: [CUDA][HIP] Don't diagnose use for __bf16

2022-11-29 Thread Pierre van Houtryve via Phabricator via cfe-commits
Pierre-vh updated this revision to Diff 478823. Pierre-vh marked 5 inline comments as done. Pierre-vh added a comment. - Recentering the patch around HIP only. - I was using too much from D57369 and was involving OpenMP when there's no reason to. Just checking

[PATCH] D136848: [clang][AST] Compare UnresolvedLookupExpr in structural equivalence.

2022-11-29 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D136848/new/ https://reviews.llvm.org/D136848 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[PATCH] D134410: [clang][CodeGen] Add noundef metadata to load instructions (preliminary 1 or 2)

2022-11-29 Thread John McIver via Phabricator via cfe-commits
jmciver updated this revision to Diff 478821. jmciver added a comment. Updating D134410 : [clang][CodeGen] Add noundef metadata to load instructions (preliminary 1 or 2) Refactor test matrix-type-operators.c to contain the noundef attribute. This test will be fu

[PATCH] D138930: [RISCV] Add macro to imply compiler availability on RISC-V Vector intrinsics version

2022-11-29 Thread Kito Cheng via Phabricator via cfe-commits
kito-cheng accepted this revision. kito-cheng added a comment. This revision is now accepted and ready to land. LGTM. I am thinking that we should use same way to define both `__riscv_v_intrinsic_overloading`[1] and `__riscv_v_intrinsic`, `__riscv_v_intrinsic_overloading` is defined in `riscv_v

[PATCH] D138914: Make evaluation of nested requirement consistent with requires expr.

2022-11-29 Thread Utkarsh Saxena via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 478819. usaxena95 added a comment. Remove unintended whitespaces and new lines. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138914/new/ https://reviews.llvm.org/D138914 Files: clang/include/clang/AST/AST

[PATCH] D138914: Make evaluation of nested requirement consistent with requires expr.

2022-11-29 Thread Utkarsh Saxena via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 478818. usaxena95 added a comment. Removed extraneous colons from diagnostic. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138914/new/ https://reviews.llvm.org/D138914 Files: clang/include/clang/AST/ASTCo

[PATCH] D138914: Make evaluation of nested requirement consistent with requires expr.

2022-11-29 Thread Utkarsh Saxena via Phabricator via cfe-commits
usaxena95 added inline comments. Comment at: clang/include/clang/AST/ExprConcepts.h:428 + : Requirement(RK_Nested, +Constraint && Constraint->isInstantiationDependent(), +Constraint && Constraint->containsUnexpandedParameterPack(), --

[PATCH] D138914: Make evaluation of nested requirement consistent with requires expr.

2022-11-29 Thread Utkarsh Saxena via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 478814. usaxena95 marked 4 inline comments as done. usaxena95 added a comment. Addressed comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138914/new/ https://reviews.llvm.org/D138914 Files: clang/in

[PATCH] D137340: [clang-tidy] Add misc-use-anonymous-namespace check

2022-11-29 Thread Dave Brown via Phabricator via cfe-commits
bigdavedev added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/misc/use-anonymous-namespace.rst:7-9 +that could instead be moved into an anonymous namespace. It also detects +instances moved to an anonymous namespace that still keep the redundant +``stati

[PATCH] D138964: Fixed a few spelling errors in clang/include/clang/StaticAnalyzer/Checkers/CheckerBase.td

2022-11-29 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/include/clang/StaticAnalyzer/Checkers/CheckerBase.td:102 +/// Note that a checker has a name (e.g.: 'NullDereference'), and a full name, +/// that is auto-generated with the help of the ParentPackage field, that also /// includes

[PATCH] D138028: [clangd] Fix action `RemoveUsingNamespace` for inline namespace

2022-11-29 Thread Tom Praschan via Phabricator via cfe-commits
tom-anders added inline comments. Comment at: clang-tools-extra/clangd/refactor/tweaks/RemoveUsingNamespace.cpp:93 +// Return true if `LHS` is declared in `RHS` +bool declareIn(const NamedDecl *LHS, const DeclContext *RHS) { + const auto *D = LHS->getDeclContext(); -

[PATCH] D138974: [CMake] Support injecting extra dependencies for perf-training

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdabd23917651: [CMake] Support injecting extra dependencies for perf-training (authored by phosek). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https:/

[clang] dabd239 - [CMake] Support injecting extra dependencies for perf-training

2022-11-29 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2022-11-30T06:13:33Z New Revision: dabd2391765154848d35f172fbbeb68c88ff9dd4 URL: https://github.com/llvm/llvm-project/commit/dabd2391765154848d35f172fbbeb68c88ff9dd4 DIFF: https://github.com/llvm/llvm-project/commit/dabd2391765154848d35f172fbbeb68c88ff9dd4.diff LOG: [C

[PATCH] D117836: Fix obvious typo

2022-11-29 Thread Phoebe Wang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG862c3d4fbe18: Fix obvious typo (authored by gftg, committed by pengfei). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117836/new/ https://reviews.llvm.org/

[clang] 862c3d4 - Fix obvious typo

2022-11-29 Thread Phoebe Wang via cfe-commits
Author: Gabriel F. T. Gomes Date: 2022-11-30T14:01:08+08:00 New Revision: 862c3d4fbe185c3d77c067e6e6ad1f07082a31e1 URL: https://github.com/llvm/llvm-project/commit/862c3d4fbe185c3d77c067e6e6ad1f07082a31e1 DIFF: https://github.com/llvm/llvm-project/commit/862c3d4fbe185c3d77c067e6e6ad1f07082a31e1

[PATCH] D138028: [clangd] Fix action `RemoveUsingNamespace` for inline namespace

2022-11-29 Thread v1nh1shungry via Phabricator via cfe-commits
v1nh1shungry added a comment. Oops! Thank you for your thoughtful consideration. You're right, but I currently get stuck there and need more time. And I prefer to clear the existing patches simultaneously if you don't mind. Or do you think I should merge the modification of this patch into ther

[PATCH] D138975: [perf-training] Support additional test suffixes

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG78acf911eddd: [perf-training] Support additional test suffixes (authored by phosek). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138975/new/ https://revie

[clang] 78acf91 - [perf-training] Support additional test suffixes

2022-11-29 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2022-11-30T05:36:46Z New Revision: 78acf911ee2c40f8d5e78603e446710d35bd URL: https://github.com/llvm/llvm-project/commit/78acf911ee2c40f8d5e78603e446710d35bd DIFF: https://github.com/llvm/llvm-project/commit/78acf911ee2c40f8d5e78603e446710d35bd.diff LOG: [p

[PATCH] D138979: [NFC] Cleanup: Replaces BB->getInstList().splice() with BB->splice().

2022-11-29 Thread Vasileios Porpodas via Phabricator via cfe-commits
vporpo created this revision. vporpo added reviewers: asbirlea, aeubanks. Herald added subscribers: ChuanqiXu, hiraditya. Herald added a project: All. vporpo requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. This is part of

[PATCH] D138964: Fixed a few spelling errors in clang/include/clang/StaticAnalyzer/Checkers/CheckerBase.td

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > So how would I move forward from here? There's the "Update Diff" button on the right! You can use it to address review comments until everyone's happy. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138964/new/ https://revie

[PATCH] D138964: Fixed a few spelling errors in clang/include/clang/StaticAnalyzer/Checkers/CheckerBase.td

2022-11-29 Thread Gianni Crivello via Phabricator via cfe-commits
giannicrivello added a comment. In D138964#3958986 , @NoQ wrote: > Nice, thanks! > > For non-trivial patches it's recommended to include full diff context via > `-U99` > (https://llvm.org/docs/Phabricator.html#requesting-a-review-via-the-web-interfa

[PATCH] D138975: [perf-training] Support additional test suffixes

2022-11-29 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai accepted this revision. smeenai 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/D138975/new/ https://reviews.llvm.org/D138975 _

[PATCH] D138859: [ODRHash] Drive attribute hashing through TableGen. NFC intended.

2022-11-29 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a comment. In D138859#3958958 , @vsapsai wrote: > In D138859#3955806 , @ChuanqiXu > wrote: > >> And I think we should add tests for this. e.g., in the ASTImporterTests.cpp. > > I'm not sure which

[PATCH] D138975: [perf-training] Support additional test suffixes

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. phosek added a reviewer: smeenai. Herald added a project: All. phosek requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. .cc and .test are commonly used and supported by other lit test suites. Repository: rG L

[PATCH] D138974: [CMake] Support injecting extra dependencies for perf-training

2022-11-29 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai accepted this revision. smeenai added a comment. This revision is now accepted and ready to land. Might be worth a mention in either https://llvm.org/docs/AdvancedBuilds.html#multi-stage-pgo, to make it a bit more discoverable. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D138974: [CMake] Support injecting extra dependencies for perf-training

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. phosek added a reviewer: smeenai. Herald added a project: All. phosek requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. It may be necessary to build additional targets before running perf-training, the typical us

[PATCH] D138930: [RISCV] Add macro to imply compiler availability on RISC-V Vector intrinsics version

2022-11-29 Thread Yueh-Ting (eop) Chen via Phabricator via cfe-commits
eopXD updated this revision to Diff 478784. eopXD added a comment. Add check for end-line. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138930/new/ https://reviews.llvm.org/D138930 Files: clang/lib/Basic/Targets/RISCV.cpp clang/test/Preproces

[PATCH] D138900: [X86] include cmpccxaddintrin.h from immintrin.h to x86gprintrin.h

2022-11-29 Thread Freddy, Ye 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 rG51679dc1c9d5: [X86] include cmpccxaddintrin.h from immintrin.h to x86gprintrin.h (authored by FreddyYe). Repository: rG LLVM Github Monorepo CHAN

[clang] 51679dc - [X86] include cmpccxaddintrin.h from immintrin.h to x86gprintrin.h

2022-11-29 Thread Freddy Ye via cfe-commits
Author: Freddy Ye Date: 2022-11-30T10:40:42+08:00 New Revision: 51679dc1c9d52ca906a739bafdd7be0041d7b3ce URL: https://github.com/llvm/llvm-project/commit/51679dc1c9d52ca906a739bafdd7be0041d7b3ce DIFF: https://github.com/llvm/llvm-project/commit/51679dc1c9d52ca906a739bafdd7be0041d7b3ce.diff LOG

[PATCH] D138900: [X86] include cmpccxaddintrin.h from immintrin.h to x86gprintrin.h

2022-11-29 Thread Freddy, Ye via Phabricator via cfe-commits
FreddyYe updated this revision to Diff 478781. FreddyYe added a comment. minor fix. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138900/new/ https://reviews.llvm.org/D138900 Files: clang/lib/Headers/cmpccxaddintrin.h clang/lib/Headers/immintr

[PATCH] D138964: Fixed a few spelling errors in clang/include/clang/StaticAnalyzer/Checkers/CheckerBase.td

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Nice, thanks! For non-trivial patches it's recommended to include full diff context via `-U99` (https://llvm.org/docs/Phabricator.html#requesting-a-review-via-the-web-interface) so that reviewers could easily see what does the surrounding code do. C

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

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/docs/SafeBuffers.rst:40-41 + - Finally, in order to avoid bugs in newly converted code, the +Clang static analyzer provides a checker to find misconstructed +``std::span`` objects. + aaron.ballman wrote: > NoQ

[PATCH] D138859: [ODRHash] Drive attribute hashing through TableGen. NFC intended.

2022-11-29 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. In D138859#3955806 , @ChuanqiXu wrote: > And I think we should add tests for this. e.g., in the ASTImporterTests.cpp. I'm not sure which test would be useful in this case. We kinda already test that different modules agree which

[PATCH] D138947: [Clang] Remove invalid assert from Sema::BuildCXXTypeConstructExpr

2022-11-29 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:1464 - (Exprs.size() == 1 && isa(Exprs[0]))) && - "List initialization must have initializer list as expression."); SourceRange FullRange = SourceRange(TyBeginLoc, RParenOrBraceLoc);

[PATCH] D138961: [clang-doc] Fix warnings about lock_guard.

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
phosek added a comment. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138961/new/ https://reviews.llvm.org/D138961 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-

[PATCH] D138961: [clang-doc] Fix warnings about lock_guard.

2022-11-29 Thread Petr Hosek via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rGc99512096899: [clang-doc] Fix warnings about lock_guard (authored by phosek). Repository: rG LLVM Github Monorepo CHAN

[clang-tools-extra] c995120 - [clang-doc] Fix warnings about lock_guard

2022-11-29 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2022-11-30T02:30:40Z New Revision: c995120968993b09aeb138868b30348d6724efe2 URL: https://github.com/llvm/llvm-project/commit/c995120968993b09aeb138868b30348d6724efe2 DIFF: https://github.com/llvm/llvm-project/commit/c995120968993b09aeb138868b30348d6724efe2.diff LOG: [c

[PATCH] D138970: [clang][Driver] Don't overwrite `DiagnosticsEngine::IgnoreAllWarnings`, rely on `DiagnosticOptions::IgnoreWarnings` value.

2022-11-29 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. To help folks digging up the history, the code in driver was introduced in https://reviews.llvm.org/D11322 and the test case added in "test/Index/warning-flags.c" requires the change in "clang/tools/libclang/CIndex.cpp", that's why I don't have any extra test changes.

[PATCH] D138252: [clang][deps] During scanning don't emit warnings-as-errors that are ignored with diagnostic pragmas.

2022-11-29 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Ok, I was able to reproduce the error on macOS by adding `-target x86_64-sie-ps5` to one of commands in "clang/test/ClangScanDeps/Inputs/no-werror.json" (wouldn't mind receiving PS5 DevKit, by the way). The problem is that `Driver::BuildCompilation` overwrites `Diagnos

[PATCH] D138970: [clang][Driver] Don't overwrite `DiagnosticsEngine::IgnoreAllWarnings`, rely on `DiagnosticOptions::IgnoreWarnings` value.

2022-11-29 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai created this revision. vsapsai added reviewers: bnbarham, dyung, MaskRay. Herald added subscribers: StephenFan, ributzka, arphaman. Herald added a project: All. vsapsai requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Driver overwrit

[PATCH] D137213: [clang][modules] NFCI: Pragma diagnostic mappings: write/read FileID instead of SourceLocation

2022-11-29 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:6343 "Invalid data, missing pragma diagnostic states"); - SourceLocation Loc = ReadSourceLocation(F, Record[Idx++]); - auto IDAndOffset = SourceMgr.getDecomposedLoc(Loc); -

[PATCH] D137770: [docs] Introduce clangd part in StandardCPlusPlusModules

2022-11-29 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a subscriber: v.g.vassilev. ChuanqiXu added a comment. @sammccall @nridge in a chat, @v.g.vassilev mentioned that it may be possible to make clangd for modules a GSoC project. I feel it is pretty good idea. How do you think about it? Repository: rG LLVM Github Monorepo CHANG

[PATCH] D137213: [clang][modules] NFCI: Pragma diagnostic mappings: write/read FileID instead of SourceLocation

2022-11-29 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:6343 "Invalid data, missing pragma diagnostic states"); - SourceLocation Loc = ReadSourceLocation(F, Record[Idx++]); - auto IDAndOffset = SourceMgr.getDecomposedLoc(Loc); -

[PATCH] D137995: [Flang][Driver] Handle target CPU and features

2022-11-29 Thread Usman Nadeem via Phabricator via cfe-commits
mnadeem added inline comments. Comment at: clang/lib/Driver/ToolChains/Flang.cpp:99 + default: +// Untested for other targets but should work generally. +break; mnadeem wrote: > kiranchandramohan wrote: > > I get a segfault in ` > > Fortran::frontend::C

[PATCH] D137995: [Flang][Driver] Handle target CPU and features

2022-11-29 Thread Usman Nadeem via Phabricator via cfe-commits
mnadeem added inline comments. Comment at: clang/lib/Driver/ToolChains/Flang.cpp:99 + default: +// Untested for other targets but should work generally. +break; kiranchandramohan wrote: > I get a segfault in ` Fortran::frontend::CodeGenAction::setUpTarge

[PATCH] D137995: [Flang][Driver] Handle target CPU and features

2022-11-29 Thread Usman Nadeem via Phabricator via cfe-commits
mnadeem added a comment. In D137995#3931005 , @kiranchandramohan wrote: > We might need `-fc1` tests as well. What kind of tests do you think would be appropriate here? Can you point me to any examples, maybe from clang? CHANGES SINCE LAST ACTION h

[PATCH] D137995: [Flang][Driver] Handle target CPU and features

2022-11-29 Thread Usman Nadeem via Phabricator via cfe-commits
mnadeem added a comment. In D137995#3944145 , @awarzynski wrote: > Thanks for implementing this! > >> Processes target cpu and features in the flang driver. Right now features >> are only added for AArch64 because I only did basic testing on AArch64 but

[PATCH] D137995: [Flang][Driver] Handle target CPU and features

2022-11-29 Thread Usman Nadeem via Phabricator via cfe-commits
mnadeem updated this revision to Diff 478766. mnadeem marked 4 inline comments as done. mnadeem edited the summary of this revision. Herald added a subscriber: pengfei. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137995/new/ https://reviews.llvm.org/D137995 Files: clang/include/clang

[PATCH] D138963: Fixed a few spelling errors.

2022-11-29 Thread Gianni Crivello via Phabricator via cfe-commits
giannicrivello created this revision. Herald added a subscriber: steakhal. Herald added a reviewer: NoQ. Herald added a project: All. giannicrivello requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo http

[PATCH] D138947: [Clang] Remove invalid assert from Sema::BuildCXXTypeConstructExpr

2022-11-29 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:1464 - (Exprs.size() == 1 && isa(Exprs[0]))) && - "List initialization must have initializer list as expression."); SourceRange FullRange = SourceRange(TyBeginLoc, RParenOrBraceLoc); --

[PATCH] D138295: [clang][TargetInfo] Use LangAS for getPointer{Width,Align}()

2022-11-29 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. This looks great, thanks! Skimmed through the changes pretty quickly. Comment at: clang/lib/AST/Mangle.cpp:237 } - Out << ((TI.getPointerWidth(0) / 8) * ArgWords); + Out << ((TI.getPointerWidth(LangAS::Default) / 8) * ArgWords); } --

[PATCH] D138961: [clang-doc] Fix warnings about lock_guard.

2022-11-29 Thread Brett Wilson via Phabricator via cfe-commits
brettw created this revision. brettw added a project: clang-tools-extra. Herald added a subscriber: arphaman. Herald added a project: All. brettw requested review of this revision. Herald added a subscriber: cfe-commits. Fixes a warning about a potentially unsupported template argument deduction b

[PATCH] D138947: [Clang] Remove invalid assert from Sema::BuildCXXTypeConstructExpr

2022-11-29 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. The windows failure happened on the build before as well so not related to this change: https://buildkite.com/llvm-project/premerge-checks/builds/123890 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138947/new/ https://reviews.llvm.org/D138947 _

[PATCH] D137107: Allow MS extension: support of constexpr with __declspec(dllimport).

2022-11-29 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:4822 Init = Initializer; + if (Initializer->isDLLImportDependent()) +NeedsGlobalCtor = true; This check probably needs to be inside tryEmitForInitializer, so other

[PATCH] D137107: Allow MS extension: support of constexpr with __declspec(dllimport).

2022-11-29 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. That's roughly what I was thinking, yes. The one missing piece is the code to modify the constructor priorities to make sure that "constant" variables get initialized first. (This ensures we honor the C++ rules for "constant initialization".) Comme

[PATCH] D137213: [clang][modules] NFCI: Pragma diagnostic mappings: write/read FileID instead of SourceLocation

2022-11-29 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:6343 "Invalid data, missing pragma diagnostic states"); - SourceLocation Loc = ReadSourceLocation(F, Record[Idx++]); - auto IDAndOffset = SourceMgr.getDecomposedLoc(Loc); -

[PATCH] D138930: [RISCV] Add macro to imply compiler availability on RISC-V Vector intrinsics version

2022-11-29 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: clang/test/Preprocessor/riscv-target-features.c:266 // CHECK-ZVE64D-EXT: __riscv_v_elen_fp 64 +// CHECK-ZVE64D-EXT: __riscv_v_intrinsic 1 // CHECK-ZVE64D-EXT: __riscv_v_min_vlen 64 Check to end of line like th

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

2022-11-29 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/include/clang/Basic/LangOptions.h:301 + enum Float16ExcessPrecisionKind { FPP_Standard, FPP_Fast, FPP_None }; + zahiraam wrote: > rjmccall wrote: > > rjmccall wrote: > > > You can leave this named `ExcessPrecis

[PATCH] D138958: [clang] Better UX for Clang’s unwind-affecting attributes

2022-11-29 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri created this revision. lebedev.ri added reviewers: aaron.ballman, erichkeane, rjmccall. lebedev.ri added a project: LLVM. Herald added subscribers: carlosgalvezp, jdoerfert. Herald added a reviewer: NoQ. Herald added a reviewer: njames93. Herald added a project: All. lebedev.ri requested

[PATCH] D138861: [Clang] Implement CWG2640 Allow more characters in an n-char sequence

2022-11-29 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/test/CXX/drs/dr26xx.cpp:41 +#define a z( +int x = a\N{abc}); // expected-error 2{{'abc' is not a valid Unicode character name}} + aaron.ballman wrote: > Why do we get two errors here? > > Also, can you add this

[PATCH] D137051: [Clang] Allow additional mathematical symbols in identifiers.

2022-11-29 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added a comment. I apologize for the delay Corentin, I hope to get through a number of my outstanding code reviews tomorrow. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137051/new/ https://reviews.llvm.org/D137051 __

[PATCH] D137107: Allow MS extension: support of constexpr with __declspec(dllimport).

2022-11-29 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam added a comment. In D137107#3931259 , @efriedma wrote: > There are multiple notions of "constant" here: > > - Whether a value is invariant at runtime. > - Whether a value is legal in a "constexpr" expression. > - Whether we can emit a constant wi

[PATCH] D137107: Allow MS extension: support of constexpr with __declspec(dllimport).

2022-11-29 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam updated this revision to Diff 478624. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137107/new/ https://reviews.llvm.org/D137107 Files: clang/lib/AST/ExprConstant.cpp clang/lib/CodeGen/CodeGenModule.cpp clang/lib/Sema/SemaDecl.cpp clang/test/CodeGenCXX/PR19955.cpp clan

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

2022-11-29 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam updated this revision to Diff 478738. 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 clang/include/clang/Basic/L

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

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:54-55 + bool TraverseDecl(Decl *Node) { +if (!Node) + return true; +if (!match(*Node)) ziqingluo-90 wrote: > steakhal wrote: > > Can `Node` be ever null if the visitor i

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

2022-11-29 Thread Brett Wilson via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG7b8c7e02122a: [clang-doc] Move file layout to the generators. (authored by brettw). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138073/new/ https://review

[clang-tools-extra] 7b8c7e0 - [clang-doc] Move file layout to the generators.

2022-11-29 Thread Brett Wilson via cfe-commits
Author: Brett Wilson Date: 2022-11-29T14:40:58-08:00 New Revision: 7b8c7e02122a2ea392b371e3e39b405bc98146de URL: https://github.com/llvm/llvm-project/commit/7b8c7e02122a2ea392b371e3e39b405bc98146de DIFF: https://github.com/llvm/llvm-project/commit/7b8c7e02122a2ea392b371e3e39b405bc98146de.diff

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

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:107 +/// out of bounds. +class IncrementGadget : public UnsafeGadget { + const UnaryOperator *Op; xazax.hun wrote: > How deep will the `Gadget` Hierarchy be? Using inheritance only t

[clang] 60a33de - [clang][darwin] Use consistent version define stringifying logic for different Darwin OSes

2022-11-29 Thread Alex Lorenz via cfe-commits
Author: Alex Lorenz Date: 2022-11-29T14:22:34-08:00 New Revision: 60a33ded751c86fff9ac1c4bdd2b341fbe4b0649 URL: https://github.com/llvm/llvm-project/commit/60a33ded751c86fff9ac1c4bdd2b341fbe4b0649 DIFF: https://github.com/llvm/llvm-project/commit/60a33ded751c86fff9ac1c4bdd2b341fbe4b0649.diff L

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

2022-11-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def:1 +//=- UnsafeBufferUsageGadgets.def - List of ways to use a buffer --*- C++ -*-=// +// aaron.ballman wrote: > Is this file named properly if it is also goi

[PATCH] D138597: DebugInfo: Add/support new DW_LANG codes for recent C and C++ versions

2022-11-29 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. > @aprantl do you have an opinion on this? I tend to lean to the pedantic side > on this kind of thing, but I'm persuadable. As long as LLDB can deal with it I'm fine either way. Emitting the separated DWARF 6 attribute as an extension sounds fine to me. =

[clang] 3a37c11 - [clang] [test] Fix recently pushed mingw tests in some environments

2022-11-29 Thread Martin Storsjö via cfe-commits
Author: Martin Storsjö Date: 2022-11-30T00:01:01+02:00 New Revision: 3a37c112b173b7d66e6562cc12c441e996d895f2 URL: https://github.com/llvm/llvm-project/commit/3a37c112b173b7d66e6562cc12c441e996d895f2 DIFF: https://github.com/llvm/llvm-project/commit/3a37c112b173b7d66e6562cc12c441e996d895f2.diff

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2022-11-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. > though I find myself wondering if the "FormatDiagnostic" call should stay the > same, and choose the legacy-reason only when a sarif reason doesn't exist? Or > for some level of command line control? Hmm... isn't this the point of the diagnostic consumers? Repository:

[PATCH] D138947: [Clang] Remove invalid assert from Sema::BuildCXXTypeConstructExpr

2022-11-29 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik created this revision. shafik added reviewers: aaron.ballman, erichkeane, davide, rsmith. Herald added a project: All. shafik requested review of this revision. Currently `Sema::BuildCXXTypeConstructExpr` asserts that list initialization must mean we have an `InitListExpr` as well. We have

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2022-11-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. > The clang-side interface to this seems a touch clunky, and I fear it'll make > continuing its use/generalizing its use less likely. Is this w.r.t. the `FormatDiagnostic` being split up, or is it something else? If it's the former: I'll be changing that to `FormatLegacyDi

[PATCH] D138614: [Clang][OpenMP][AMDGPU] Fix capture of variably modified type alias in teams distribute

2022-11-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 updated this revision to Diff 478707. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138614/new/ https://reviews.llvm.org/D138614 Files: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp clang/test/OpenMP/target_teams_distribute_with_alias.c Index: clang/test/OpenMP/target_teams_dist

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2022-11-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I don't understand why `test_demangle.pass.cpp` was considered too big to upload. Here's the diff: diff --git a/libcxxabi/test/test_demangle.pass.cpp b/libcxxabi/test/test_demangle.pass.cpp index dce8e6c3..9da6fb7d2ad9 100644 --- a/libcxxabi/test/test_demangle.pa

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

2022-11-29 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:54-55 + bool TraverseDecl(Decl *Node) { +if (!Node) + return true; +if (!match(*Node)) steakhal wrote: > Can `Node` be ever null if the visitor is initiated onl

[PATCH] D138614: [Clang][OpenMP][AMDGPU] Fix capture of variably modified type alias in teams distribute

2022-11-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp:243 if (!FD->getType()->isReferenceType()) { - assert(!VD->getType()->isVariablyModifiedType() && + bool isVMTTy = VD->getType()->isVariablyModifiedType(); + as

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2022-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Herald added subscribers: Michael137, JDevlieghere. A few comments. I don't mind the approach, though I find myself wondering if the "FormatDiagnostic" call should stay the same, and choose the legacy-reason only when a sarif reason doesn't exist? Or for some level

[clang] 2a67014 - [clang][driver][darwin] Enforce consistent major version limit for any Darwin OS

2022-11-29 Thread Alex Lorenz via cfe-commits
Author: Alex Lorenz Date: 2022-11-29T13:18:56-08:00 New Revision: 2a6701444af816f9048c788513abf4d2e9fa785d URL: https://github.com/llvm/llvm-project/commit/2a6701444af816f9048c788513abf4d2e9fa785d DIFF: https://github.com/llvm/llvm-project/commit/2a6701444af816f9048c788513abf4d2e9fa785d.diff L

[PATCH] D138861: [Clang] Implement CWG2640 Allow more characters in an n-char sequence

2022-11-29 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 478706. cor3ntin added a comment. Avoid duplicating errors in macros. Because of that we cannot alays recover nicely with a loose matching. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138861/new/ https://rev

[PATCH] D138693: [clang] [MinGW] Improve detection of libstdc++ headers on Fedora

2022-11-29 Thread Martin Storsjö 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 rG98454e388500: [clang] [MinGW] Improve detection of libstdc++ headers on Fedora (authored by mstorsjo). Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D138692: [clang] [MinGW] Improve/extend the gcc/sysroot detection logic

2022-11-29 Thread Martin Storsjö 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 rG02b25bd904b5: [clang] [MinGW] Improve/extend the gcc/sysroot detection logic (authored by mstorsjo). Repository: rG LLVM Github Monorepo CHANGES

[clang] 98454e3 - [clang] [MinGW] Improve detection of libstdc++ headers on Fedora

2022-11-29 Thread Martin Storsjö via cfe-commits
Author: Martin Storsjö Date: 2022-11-29T23:16:09+02:00 New Revision: 98454e388500de2f264c06b555d6009614f8f56e URL: https://github.com/llvm/llvm-project/commit/98454e388500de2f264c06b555d6009614f8f56e DIFF: https://github.com/llvm/llvm-project/commit/98454e388500de2f264c06b555d6009614f8f56e.diff

[clang] 02b25bd - [clang] [MinGW] Improve/extend the gcc/sysroot detection logic

2022-11-29 Thread Martin Storsjö via cfe-commits
Author: Martin Storsjö Date: 2022-11-29T23:16:09+02:00 New Revision: 02b25bd904b51184b579b7f0bac816bdd11eb757 URL: https://github.com/llvm/llvm-project/commit/02b25bd904b51184b579b7f0bac816bdd11eb757 DIFF: https://github.com/llvm/llvm-project/commit/02b25bd904b51184b579b7f0bac816bdd11eb757.diff

[PATCH] D138028: [clangd] Fix action `RemoveUsingNamespace` for inline namespace

2022-11-29 Thread Tom Praschan via Phabricator via cfe-commits
tom-anders added a comment. In D138028#3957139 , @v1nh1shungry wrote: > A gentle ping? Sorry if it bothers you. Sorry! I thought you’d probably first wanted to address the remaining comments in https://reviews.llvm.org/D137817 because they might also a

[PATCH] D138614: [Clang][OpenMP][AMDGPU] Fix capture of variably modified type alias in teams distribute

2022-11-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 updated this revision to Diff 478693. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138614/new/ https://reviews.llvm.org/D138614 Files: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp clang/test/OpenMP/target_teams_distribute_with_alias.c Index: clang/test/OpenMP/target_teams_dist

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

2022-11-29 Thread Brett Wilson via Phabricator via cfe-commits
brettw updated this revision to Diff 478683. 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 clang-tools-extra/clang-doc/MDGenerator.cpp clang-

[PATCH] D128372: [Clang-Tidy] Empty Check

2022-11-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. @njames93 if you don't have any further concerns, I am going to merge this on Friday afternoon, as it will have been four months since there has been a maintainer's input. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128372/

[PATCH] D138861: [Clang] Implement CWG2640 Allow more characters in an n-char sequence

2022-11-29 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 478679. cor3ntin added a comment. Slightly improve error recovery Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138861/new/ https://reviews.llvm.org/D138861 Files: clang/docs/ReleaseNotes.rst clang/lib/Le

[PATCH] D138614: [Clang][OpenMP][AMDGPU] Fix capture of variably modified type alias in teams distribute

2022-11-29 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp:243 if (!FD->getType()->isReferenceType()) { - assert(!VD->getType()->isVariablyModifiedType() && + bool isVMT = VD->getType()->isVariablyModifiedType(); + ass

[PATCH] D138597: DebugInfo: Add/support new DW_LANG codes for recent C and C++ versions

2022-11-29 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. > They're published on the website too: https://dwarfstd.org/LanguagesV6.php (sigh) sorry, distracted by other things today. Yeah, using the v6 codes with the v6 attributes for the new ones WFM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2022-11-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, erichkeane, shafik. Herald added subscribers: carlosgalvezp, kadircet, arphaman. Herald added a reviewer: njames93. Herald added projects: Flang, All. cjdb requested review of this revision. Herald added subscribers: cfe-commits, libc

[clang] f2c0c72 - [Windows] Convert clang/test/Modules tests to check 'target='

2022-11-29 Thread Paul Robinson via cfe-commits
Author: Paul Robinson Date: 2022-11-29T12:17:36-08:00 New Revision: f2c0c7299b18448ac3ae04891b53fd8cac4af178 URL: https://github.com/llvm/llvm-project/commit/f2c0c7299b18448ac3ae04891b53fd8cac4af178 DIFF: https://github.com/llvm/llvm-project/commit/f2c0c7299b18448ac3ae04891b53fd8cac4af178.diff

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

2022-11-29 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam added inline comments. Comment at: clang/include/clang/Basic/LangOptions.h:301 + enum Float16ExcessPrecisionKind { FPP_Standard, FPP_Fast, FPP_None }; + rjmccall wrote: > rjmccall wrote: > > You can leave this named `ExcessPrecisionKind` — if we intro

[PATCH] D138861: [Clang] Implement CWG2640 Allow more characters in an n-char sequence

2022-11-29 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 478673. cor3ntin added a comment. Add test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D138861/new/ https://reviews.llvm.org/D138861 Files: clang/docs/ReleaseNotes.rst clang/lib/Lex/Lexer.cpp clang/lib

[clang] c52053b - [clang] Fix buildbot failure in delayed-template-with-pragma.cpp

2022-11-29 Thread Mike Rice via cfe-commits
Author: Mike Rice Date: 2022-11-29T11:53:37-08:00 New Revision: c52053bd9961cc1854e86958ffb0f89e2cfe4e5f URL: https://github.com/llvm/llvm-project/commit/c52053bd9961cc1854e86958ffb0f89e2cfe4e5f DIFF: https://github.com/llvm/llvm-project/commit/c52053bd9961cc1854e86958ffb0f89e2cfe4e5f.diff LOG

[PATCH] D137020: [clang][AST] Handle variable declaration with unknown typedef in C

2022-11-29 Thread Dilshod Urazov via Phabricator via cfe-commits
urazoff updated this revision to Diff 478667. urazoff added a comment. Reasoning about invalid code is made now in specific parsing path not in general decision-making method. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137020/new/ https://reviews.llvm.org/D137020 Files: clang/lib

[clang] 2fc5a34 - Add test coverage for more C DRs

2022-11-29 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2022-11-29T14:44:37-05:00 New Revision: 2fc5a3410087c209567c7e4a2c457b6896c127a3 URL: https://github.com/llvm/llvm-project/commit/2fc5a3410087c209567c7e4a2c457b6896c127a3 DIFF: https://github.com/llvm/llvm-project/commit/2fc5a3410087c209567c7e4a2c457b6896c127a3.diff

  1   2   3   >