[PATCH] D128059: [Clang] Add a warning on invalid UTF-8 in comments.

2022-06-22 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 439177. cor3ntin added a comment. - Add a comment referencing the (to be) C++ wording and unicode discussion on replacemet characters - Do not try to skip utf8 checks when the warning is not enabled as checking whether the warning is enabled is more expensi

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 439195. jyu2 marked 7 inline comments as done. jyu2 retitled this revision from "Generate the capture for field when the field is used with implicit default." to "Generate the capture for field when the field is used in openmp region with implicit default in the

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaExprMember.cpp:1873-1877 +if (auto *PrivateCopy = +isOpenMPFDCaptureDecl(Field, Base.get(), IsArrow, OpLoc, &SS, + /*TemplateKWLoc=*/SourceLocation(), Field, +

[PATCH] D116203: [clang] adds unary type transformations as compiler built-ins

2022-06-22 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:5863 // FIXME: derive from "Target" ? - return WCharTy; + return IntTy; } rsmith wrote: > This change seems surprising. Can you explain what's going on here? Motivated by `__make_signed(wc

[PATCH] D128056: [clang][dataflow] Singleton pointer values for null pointers.

2022-06-22 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Analysis/FlowSensitive/DataflowAnalysisContext.cpp:69 +Res.first->second = +&takeOwnership(std::make_unique(PointeeLoc)); + } ---

[PATCH] D127901: [LinkerWrapper] Add PTX output to CUDA fatbinary in LTO-mode

2022-06-22 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D127901#3603118 , @jhuber6 wrote: > In D127901#3603006 , @tra wrote: > >> Then we do need a knob controlling whether we do want to embed PTX or not. >> The default should be "off" IMO. >>

[PATCH] D128401: [Clang-tidy] Fixing a bug raising false alarms on static local variables in the Infinite Loop Checker

2022-06-22 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 created this revision. ziqingluo-90 added reviewers: NoQ, t-rasmud, usama54321, rsundahl, yln, kubamracek, krispy1994, jkorous, delcypher, chrisdangelo, thetruestblue, aaron.ballman, alexfh, gribozavr, njames93, LegalizeAdulthood. Herald added subscribers: carlosgalvezp, kristof.beyl

[PATCH] D128363: [clang][dataflow] Implement functionality for flow condition variable substitution.

2022-06-22 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/include/clang/Analysis/FlowSensitive/DataflowAnalysisContext.h:197 + /// `Substitutions`, it will be substituted with the value it maps to. + BoolValue &buildAndSubstituteFlowCondition( + AtomicBoolValue &Token, -

[PATCH] D127901: [LinkerWrapper] Add PTX output to CUDA fatbinary in LTO-mode

2022-06-22 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 added a comment. In D127901#3603467 , @tra wrote: > I'm not sure I follow. WDYM by "go inside the binary itself" ? I assume you > mean the per-GPU offload binaries inside per-TU .o. so that it could be used > when that GPU object gets linked int

[PATCH] D127898: [clang][dataflow] Add API to separate analysis from diagnosis

2022-06-22 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/Models/UncheckedOptionalAccessModel.cpp:546 +void diagnoseUnwrapCall(const Expr *UnwrapExpr, const Expr *ObjectExpr, +DiagnoseState> &State) { I think this sh

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi created this revision. Herald added subscribers: carlosgalvezp, xazax.hun. Herald added a project: All. ishaangandhi requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. The clang-tidy check `bugprone-branch-clone` has a

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi updated this revision to Diff 439221. ishaangandhi added a comment. Rebased CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 Files: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp clang-tools-extra/docs/ReleaseNotes.

[clang] a35141d - [OpenMP] Add handling cases when filter(tid) appears with default(none)

2022-06-22 Thread Mike Rice via cfe-commits
Author: Fazlay Rabbi Date: 2022-06-22T17:45:43-07:00 New Revision: a35141d395019c837d16419c6ef57662a6efefc5 URL: https://github.com/llvm/llvm-project/commit/a35141d395019c837d16419c6ef57662a6efefc5 DIFF: https://github.com/llvm/llvm-project/commit/a35141d395019c837d16419c6ef57662a6efefc5.diff

[PATCH] D128397: Add handling cases when filter(tid) appears with deafult(none)

2022-06-22 Thread Mike Rice 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 rGa35141d39501: [OpenMP] Add handling cases when filter(tid) appears with default(none) (authored by mdfazlay, committed by mikerice). Herald added a p

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi updated this revision to Diff 439226. ishaangandhi added a comment. Move test to new file with `-fix-errors` flag CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 Files: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp

[PATCH] D112579: Allow non-variadic functions to be attributed with `__attribute__((format))`

2022-06-22 Thread Félix Cloutier via Phabricator via cfe-commits
fcloutier added a comment. Would it be better if I asked a colleague to finish the review? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112579/new/ https://reviews.llvm.org/D112579 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi updated this revision to Diff 439228. ishaangandhi added a comment. Check for error messages in test case CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 Files: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp clang-

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi updated this revision to Diff 439239. ishaangandhi added a comment. Include `error: ` in error line CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 Files: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp clang-tools-

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Ishaan Gandhi via Phabricator via cfe-commits
ishaangandhi updated this revision to Diff 439240. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 Files: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp clang-tools-extra/docs/ReleaseNotes.rst clang-tools-extra/test/clang-tidy

[PATCH] D127351: clang: fix early substitution of alias templates

2022-06-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 439241. mizvekov added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127351/new/ https://reviews.llvm.org/D127351 Files: clang/include/clang/Sema/Template.h clang/lib/Sema/SemaTemplateIn

[PATCH] D128095: clang: fix checking parameter packs for expansion

2022-06-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 439244. mizvekov added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128095/new/ https://reviews.llvm.org/D128095 Files: clang/include/clang/Sema/Sema.h clang/include/clang/Sema/SemaInte

[PATCH] D128276: clang: perform deduction at the right depth on Sema::AddMethodTemplateCandidate

2022-06-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 439245. mizvekov added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128276/new/ https://reviews.llvm.org/D128276 Files: clang/lib/Sema/SemaOverload.cpp clang/test/CXX/temp/temp.decls/te

[PATCH] D127690: [NFC] clang/Parser: remove dead code

2022-06-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 439246. mizvekov added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127690/new/ https://reviews.llvm.org/D127690 Files: clang/lib/Parse/Parser.cpp Index: clang/lib/Parse/Parser.cpp

[PATCH] D113107: Support of expression granularity for _Float16.

2022-06-22 Thread Phoebe Wang via Phabricator via cfe-commits
pengfei added a comment. > Supporting the lowering in the backend is sensible in order to support > -fexcess-precision=16, because I agree that the most reasonable IR output in > that configuration is to simply generate half operations. But under > -fexcess-precision=32, I do not want the front

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-06-22 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:11155 +def err_export_inline_not_defined : Error< + "exported inline functions must be defined within the module purview" + " and before any private module fragment">;

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-06-22 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. From the perspective of handling `err_export_inline_not_defined` error as a developer what about the following option? export inline void fn_e(); // note: function 'fn_e' exported as 'inline' here // ... module :private; void fn_e() {} // error: definition of

[PATCH] D128351: [clang] missing outer template levels when checking template constraints

2022-06-22 Thread Sirui Mu via Phabricator via cfe-commits
Lancern updated this revision to Diff 439253. Lancern added a comment. Fix some regression issues Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128351/new/ https://reviews.llvm.org/D128351 Files: clang/lib/Sema/SemaConcept.cpp clang/test/SemaC

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-06-22 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a comment. In D128328#3603781 , @vsapsai wrote: > From the perspective of handling `err_export_inline_not_defined` error as a > developer what about the following option? > > export inline void fn_e(); // note: function 'fn_e' exported

[PATCH] D128406: clang: Tweak behaviour of warn_empty_while_body and warn_empty_if_body

2022-06-22 Thread Brad Moody via Phabricator via cfe-commits
bmoody created this revision. bmoody added reviewers: rnk, gribozavr. Herald added a project: All. bmoody requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Use the if/while statement right paren location instead of the end of the condition ex

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp:26 +// of the left and right statements. +const Expr *LHSExpr = llvm::dyn_cast(LHS); +const Expr *RHSExpr = llvm::dyn_cast(RHS); `auto` could

[PATCH] D128372: Clang-Tidy Empty Check

2022-06-22 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please add documentation for check. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:121 +- New :doc:`bugprone-standalone-empty + ` check. + Path to documentation was changed recently. Comment at: clang-too

[PATCH] D128372: Clang-Tidy Empty Check

2022-06-22 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Tests locations were changed recently too. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128372/new/ https://reviews.llvm.org/D128372 ___ cfe-commits mailing list cfe-comm

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-22 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/BranchCloneCheck.cpp:26 +// of the left and right statements. +const Expr *LHSExpr = llvm::dyn_cast(LHS); +const Expr *RHSExpr = llvm::dyn_cast(RHS); Eugene.Zelenko wrot

[PATCH] D118743: [clang-tidy] Add `modernize-use-inline-const-variables-in-headers` check

2022-06-22 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/UseInlineConstVariablesInHeadersCheck.cpp:64-68 + unless(hasType(isVolatileQualified())), // non-volatile + unless(isTemplateVariable()), // non-templat

<    1   2   3