[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Christian Walther via Phabricator via cfe-commits
cwalther added a comment. Thanks for the comments. Yes, `powerpc-*-eabi` should be valid (sorry if I was unclear about that – my parenthetical was only about AArch64). There is a PowerPC EABI: https://www.nxp.com/docs/en/application-note/PPCEABI.pdf . I wouldn’t know if Clang/LLD obey it, but i

[PATCH] D154861: [clang][AST] Propagate the contains-errors bit to DeclRefExpr from VarDecl's initializer.

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 538929. hokein marked 2 inline comments as done. hokein added a comment. address comments and add release note. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154861/new/ https://reviews.llvm.org/D154861 Files:

[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D154357#4487896 , @cwalther wrote: > Thanks for the comments. Yes, `powerpc-*-eabi` should be valid (sorry if I > was unclear about that – my parenthetical was only about AArch64). There is a > PowerPC EABI: https://www.nxp.c

[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D154357#4487896 , @cwalther wrote: > [...] There is a PowerPC EABI: > https://www.nxp.com/docs/en/application-note/PPCEABI.pdf . I wouldn’t know if > Clang/LLD obey it, but it works for us… Good to know! I read a newer ABI n

[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Christian Walther via Phabricator via cfe-commits
cwalther added a comment. > I think `&&` is cleaner: `return Triple.getOS() == llvm::Triple::UnknownOS && > ...`; Totally agree. I was just following precedent there. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154357/new/ https://reviews.llvm.

[clang] 9ca395b - [clang][AST] Propagate the contains-errors bit to DeclRefExpr from VarDecl's initializer.

2023-07-11 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2023-07-11T09:14:27+02:00 New Revision: 9ca395b5ade105aee63db20534d49a1c58ac76c7 URL: https://github.com/llvm/llvm-project/commit/9ca395b5ade105aee63db20534d49a1c58ac76c7 DIFF: https://github.com/llvm/llvm-project/commit/9ca395b5ade105aee63db20534d49a1c58ac76c7.diff LO

[PATCH] D154861: [clang][AST] Propagate the contains-errors bit to DeclRefExpr from VarDecl's initializer.

2023-07-11 Thread Haojian Wu 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 rG9ca395b5ade1: [clang][AST] Propagate the contains-errors bit to DeclRefExpr from VarDecl's… (authored by hokein). Changed prior to commit: https:/

[PATCH] D153989: [compiler-rt] Move crt into builtins

2023-07-11 Thread Petr Hosek via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. phosek marked an inline comment as done. Closed by commit rGdae9d1b52469: [compiler-rt] Move crt into builtins (authored by phosek). Changed prior to commit: https:/

[PATCH] D154884: [clang-tidy] Make MatchesAnyListedNameMatcher cope with unnamed Decl

2023-07-11 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 538940. mikecrowe marked an inline comment as done. mikecrowe added a comment. Remove unnecessary init-statement and test case in commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154884/new/ https

[PATCH] D153114: [clangd] [C++20] [Modules] Support C++20 modules for clangd

2023-07-11 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a comment. @sammccall @nridge gentle ping~ CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153114/new/ https://reviews.llvm.org/D153114 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailm

[PATCH] D154884: [clang-tidy] Make MatchesAnyListedNameMatcher cope with unnamed Decl

2023-07-11 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe added a comment. Thanks for the review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154884/new/ https://reviews.llvm.org/D154884 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:

[clang] f82df0b - [C++20] [Modules] Use CanonicalType for base classes

2023-07-11 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2023-07-11T15:59:03+08:00 New Revision: f82df0b285acd8a7115f0bfc55ce44474251c2d1 URL: https://github.com/llvm/llvm-project/commit/f82df0b285acd8a7115f0bfc55ce44474251c2d1 DIFF: https://github.com/llvm/llvm-project/commit/f82df0b285acd8a7115f0bfc55ce44474251c2d1.diff LO

[PATCH] D140727: [XRay] Add initial support for loongarch64

2023-07-11 Thread Limin Zhang via Phabricator via cfe-commits
Ami-zhang added inline comments. Comment at: compiler-rt/lib/xray/xray_loongarch64.cpp:22-25 + RN_T0 = 0xC, + RN_T1 = 0xD, + RN_RA = 0x1, + RN_SP = 0x3, xen0n wrote: > I think people usually just declare the register ABI names with decimal > numbers for read

[PATCH] D154324: [C++20] [Modules] [ODRHash] Use CanonicalType for base classes

2023-07-11 Thread Chuanqi Xu via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Changes Planned". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGf82df0b285ac: [C++20] [Modules] Use CanonicalType for base clas

[PATCH] D140727: [XRay] Add initial support for loongarch64

2023-07-11 Thread Limin Zhang via Phabricator via cfe-commits
Ami-zhang updated this revision to Diff 538948. Ami-zhang added a comment. Addressed @xen0n's comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140727/new/ https://reviews.llvm.org/D140727 Files: clang/lib/Driver/XRayArgs.cpp compiler-rt

[PATCH] D154853: [clangd][c++20]Consider the constraint of a constrained auto in FindTarget.

2023-07-11 Thread Jens Massberg via Phabricator via cfe-commits
massberg updated this revision to Diff 538952. massberg added a comment. clang-format code Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154853/new/ https://reviews.llvm.org/D154853 Files: clang-tools-extra/clangd/FindTarget.cpp clang-tools-ex

[PATCH] D154928: [clang][Interp] Call dtor or Floating values

2023-07-11 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, erichkeane, shafik, cor3ntin. Herald added a project: All. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The APFloat might heap-allocate some memory, so we n

[clang] 74258f4 - [C++20] [Modules] Allow Stmt::Profile to treat lambdas as equal conditionally

2023-07-11 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2023-07-11T16:13:06+08:00 New Revision: 74258f4189e2b6bacabd40ee6f588fd9d1b37741 URL: https://github.com/llvm/llvm-project/commit/74258f4189e2b6bacabd40ee6f588fd9d1b37741 DIFF: https://github.com/llvm/llvm-project/commit/74258f4189e2b6bacabd40ee6f588fd9d1b37741.diff LO

[PATCH] D153957: [C++20] [Modules] Allow Stmt::Profile to treat lambdas as equal conditionally

2023-07-11 Thread Chuanqi Xu via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG74258f4189e2: [C++20] [Modules] Allow Stmt::Profile to treat lambd

[PATCH] D140727: [XRay] Add initial support for loongarch64

2023-07-11 Thread WÁNG Xuěruì via Phabricator via cfe-commits
xen0n accepted this revision. xen0n added a comment. This revision is now accepted and ready to land. Thanks for following up with the suggestions. This now looks mostly okay to me; let's wait for more people to chip in! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:/

[PATCH] D140727: [XRay] Add initial support for loongarch64

2023-07-11 Thread WÁNG Xuěruì via Phabricator via cfe-commits
xen0n added a comment. Ah, the patch summary probably needs some update as well. We no longer care about version 0 and the backend changes for `R_LARCH_64_PCREL` are already in, for example. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140727/new

[PATCH] D154709: [clang][ASTImporter] Add a 'Message' member to ASTImportError and use it throughout ASTImporter

2023-07-11 Thread Michael Buch via Phabricator via cfe-commits
Michael137 added a comment. In D154709#4487776 , @balazske wrote: > The goal is to have a message always in `ASTImportError`? Then probably the > constructor without message can be removed, at least to check if really the > message is added at all place

[PATCH] D154910: [ARM][AArch64] Make ACLE __clzl/__clzll return unsigned int instead of unsigned long/uint64_t.

2023-07-11 Thread Tomas Matheson via Phabricator via cfe-commits
tmatheson accepted this revision. tmatheson added a comment. This revision is now accepted and ready to land. LGTM, thanks. Seems odd that the ACLE mixes `uint32_t` and `unsigned int`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154910/new/ https

[PATCH] D154856: [MemProf] Use new option/pass for profile feedback and matching

2023-07-11 Thread Jan-Patrick Lehr via Phabricator via cfe-commits
jplehr added a comment. The preparation patch (https://reviews.llvm.org/D154872) caused the AMD GPU OpenMP buildbot to fail. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154856/new/ https://reviews.llvm.org/D154856 __

[clang] 133b2fc - [clang][Interp][NFC] Use template types instead of auto

2023-07-11 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2023-07-11T11:25:00+02:00 New Revision: 133b2fc9cc27d03f3f5f922ec7f058c3b617a1ea URL: https://github.com/llvm/llvm-project/commit/133b2fc9cc27d03f3f5f922ec7f058c3b617a1ea DIFF: https://github.com/llvm/llvm-project/commit/133b2fc9cc27d03f3f5f922ec7f058c3b617a1ea.diff LO

[PATCH] D154934: [clang][dataflow] Use `IntegerValue` instead of `StructValue` in `ValueTest`.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a project: All. mboehme requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Soon, it will no longer be possible to default-construct `StructValue`. For de

[PATCH] D154935: [clang][dataflow] Introduce `getFieldValue()` test helpers.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a project: All. mboehme requested review of this revision. Herald added subscribers: cfe-commits, wangpc. Herald added a project: clang. These insulate tests against changes to the `getChild()` functions of `

[PATCH] D154471: [clang] Add serialization support for the DynamicAllocLValue variant of APValue::LValueBase::Ptr

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. I believe the fix is correct. Though the fix has been verified by a real-world example, I think it would be nice to get a reproducible testcase. Looking at the stacktrace: - the crash occurs during the pch deserialization - and we miss handling the case where LValue base

[PATCH] D146054: [RISCV] Add --print-supported-extensions support

2023-07-11 Thread Brandon Wu via Phabricator via cfe-commits
4vtomat marked an inline comment as done. 4vtomat added a comment. @MaskRay if you are available, please help me to check the revision, thanks!! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146054/new/ https://reviews.llvm.org/D146054 ___

[PATCH] D154935: [clang][dataflow] Introduce `getFieldValue()` test helpers.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added inline comments. Comment at: clang/unittests/Analysis/FlowSensitive/DataflowEnvironmentTest.cpp:95 - StructValue *SVal = clang::dyn_cast(Val); - ASSERT_NE(SVal, nullptr); - Val = SVal->getChild(*R); Using the opportunity to simplify the code her

[clang] 3ab7ef2 - Revert "[MemProf] Use new option/pass for profile feedback and matching"

2023-07-11 Thread JP Lehr via cfe-commits
Author: JP Lehr Date: 2023-07-11T05:44:42-04:00 New Revision: 3ab7ef28eebf9019eb3d3c4efd7ebfd160106bb1 URL: https://github.com/llvm/llvm-project/commit/3ab7ef28eebf9019eb3d3c4efd7ebfd160106bb1 DIFF: https://github.com/llvm/llvm-project/commit/3ab7ef28eebf9019eb3d3c4efd7ebfd160106bb1.diff LOG:

[PATCH] D144943: [clang][Interp] Implement bitcasts (WIP)

2023-07-11 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder abandoned this revision. tbaeder added a comment. I'm gonna close this, since the new approach is too different. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D144943/new/ https://reviews.llvm.org/D144943 ___ cfe-commits mailing list c

[PATCH] D149013: [clang][Interp] Check pointers when accessing base class

2023-07-11 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149013/new/ https://reviews.llvm.org/D149013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D154471: [clang] Add serialization support for the DynamicAllocLValue variant of APValue::LValueBase::Ptr

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. I gave it a try, here is a testcase that triggers the crash // clang -cc1 -emit-pch -o /tmp/t.pch /tmp/t.cpp #ifndef HEADER #define HEADER struct A { int *p; }; const A &w = A{ new int(10) }; #endif Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D41416: [modules] [pch] Do not deserialize all lazy template specializations when looking for one.

2023-07-11 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In D41416#4487516 , @ChuanqiXu wrote: > But some local in tree tests got failed. I took some time to investigate them > but I didn't get insights : ( If the failures involve template template parameters, please note that you ne

[PATCH] D154931: [LoongArch] Support InlineAsm for LSX and LASX

2023-07-11 Thread 陈荔 via Phabricator via cfe-commits
leecheechen created this revision. Herald added a subscriber: hiraditya. Herald added a project: All. leecheechen added reviewers: xen0n, xry111, hev, gonglingqin, SixWeining, wangleiat. leecheechen published this revision for review. Herald added projects: clang, LLVM. Herald added subscribers: l

[PATCH] D154893: [Clang] Fix some triviality computations

2023-07-11 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin accepted this revision. cor3ntin added a comment. This revision is now accepted and ready to land. This is a bit confusing but I think it is correct. LGTM modulo typos. Comment at: clang/docs/ReleaseNotes.rst:70 --- -- A bug in evaluating the i

[PATCH] D154948: [dataflow] improve determinism of generated SAT system

2023-07-11 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: ymandel, xazax.hun. Herald added subscribers: ChuanqiXu, martong, mgrang. Herald added a reviewer: NoQ. Herald added a project: All. sammccall requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe

[PATCH] D154784: [clang] Fix crash caused by PseudoObjectExprBitfields::NumSubExprs overflow

2023-07-11 Thread Yurong via Phabricator via cfe-commits
yronglin added a comment. In D154784#4486721 , @rjmccall wrote: > We had that discussion in the bug report. Let's just increase the widths > unconditionally; this is not such a common expression class that we need to > worry about using an extra word.

[PATCH] D154949: [clang][dataflow] Use `getFieldValue()` in TransferTest.cpp.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a project: All. mboehme requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. For context, see https://reviews.llvm.org/D154935. Depends On D154935

[PATCH] D41416: [modules] [pch] Do not deserialize all lazy template specializations when looking for one.

2023-07-11 Thread Shreyas via Phabricator via cfe-commits
SAtacker added inline comments. Comment at: clang/lib/Serialization/ASTWriterDecl.cpp:288 + } + for (auto &SpecInfo : LazySpecializations) { +Record.push_back(SpecInfo.DeclID); ChuanqiXu wrote: > v.g.vassilev wrote: > > We should not store the l

[PATCH] D144634: [Clang][OpenMP] Support for Code Generation of loop bind clause

2023-07-11 Thread Sunil K via Phabricator via cfe-commits
koops updated this revision to Diff 539017. koops added a comment. 1. Taking care of Alexy & David suggestions: a) Using update_cc_test_checks.py to generate CHECK statements. b) Change in error message from "handled" to "allowed". c) Adding comments for the bind clause. d) Mangled names of the

[PATCH] D153989: [compiler-rt] Move crt into builtins

2023-07-11 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru added a comment. Seems that it caused: https://github.com/llvm/llvm-project/issues/63799 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153989/new/ https://reviews.llvm.org/D153989 ___ cfe

[PATCH] D154935: [clang][dataflow] Introduce `getFieldValue()` test helpers.

2023-07-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. This revision is now accepted and ready to land. Comment at: clang/unittests/Analysis/FlowSensitive/DataflowEnvironmentTest.cpp:27 using namespace dataflow; +using test::getFieldValue; using ::testing::Elemen

[PATCH] D154948: [dataflow] improve determinism of generated SAT system

2023-07-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. This revision is now accepted and ready to land. Comment at: clang/unittests/Analysis/FlowSensitive/DeterminismTest.cpp:62 +}; +struct Tree{ + int height(); Repository: rG LLVM

[PATCH] D154950: [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: kadircet. Herald added a project: All. hokein requested review of this revision. Herald added a project: clang-tools-extra. The fixIncludes was using the `input` as the main file path, this will results in inserting header at wrong places. We

[PATCH] D154951: [clang][Interp] __builtin_bit_cast, Take 2

2023-07-11 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, erichkeane, shafik, cor3ntin. Herald added a project: All. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This implements `__builtin_bit_cast()`. The new opcod

[PATCH] D154948: [dataflow] improve determinism of generated SAT system

2023-07-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel accepted this revision. ymandel added a comment. Thank you, Sam! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154948/new/ https://reviews.llvm.org/D154948 ___ cfe-commits mailing list cfe-commit

[PATCH] D154950: [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/include-cleaner/unittests/AnalysisTest.cpp:303 - EXPECT_EQ(fixIncludes(Results, Code, format::getLLVMStyle()), R"cpp( + EXPECT_EQ(fi

[PATCH] D154952: [clang][dataflow] Various refactorings in TypeErasedDataflowAnalysisTest.cpp

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a project: All. mboehme requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. These simplify the code in their own right, but they are also useful in that t

[PATCH] D154952: [clang][dataflow] Various refactorings in TypeErasedDataflowAnalysisTest.cpp

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added inline comments. Comment at: clang/unittests/Analysis/FlowSensitive/TypeErasedDataflowAnalysisTest.cpp:400 getASTContext( { - auto &ConstructorVal = *Env.createValue(E->getType()); - ConstructorVal.setProperty("is_set", Env.

[PATCH] D154786: [Clang][Driver] Pass through the --be8 endian flag to linker in BareMetal driver For Arm.

2023-07-11 Thread Simi Pallipurath via Phabricator via cfe-commits
simpal01 updated this revision to Diff 539031. simpal01 added a comment. Addressing Review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154786/new/ https://reviews.llvm.org/D154786 Files: clang/lib/Driver/ToolChains/Arch/ARM.cpp cla

[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Christian Walther via Phabricator via cfe-commits
cwalther updated this revision to Diff 539033. cwalther added a comment. Updated patch according to current discussion: - remove check for vendor, any vendor is accepted - replace cascaded `if` by `&&` - rebase on main a3f9ce6

[PATCH] D154357: [Driver] Recognize powerpc-unknown-eabi as a bare-metal toolchain

2023-07-11 Thread Nemanja Ivanovic via Phabricator via cfe-commits
nemanjai accepted this revision. nemanjai added a comment. No concerns from the perspective of PowerPC here. Of course, my focus is primarily on the server side of things but I am not aware of any other group that could be adversely affected. CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D154950: [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 539045. hokein added a comment. add a testcase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154950/new/ https://reviews.llvm.org/D154950 Files: clang-tools-extra/include-cleaner/include/clang-include-cleane

[PATCH] D154950: [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/include-cleaner/unittests/AnalysisTest.cpp:303 - EXPECT_EQ(fixIncludes(Results, Code, format::getLLVMStyle()), R"cpp( + EXPECT_EQ(fixIncludes(Results, "d.cc", Code, format::getLLVMStyle()), +R"cpp(#include "d.h"

[clang-tools-extra] 7f3d2cd - [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2023-07-11T15:02:26+02:00 New Revision: 7f3d2cd7ec254cda659c5e5a19a42105e370e04c URL: https://github.com/llvm/llvm-project/commit/7f3d2cd7ec254cda659c5e5a19a42105e370e04c DIFF: https://github.com/llvm/llvm-project/commit/7f3d2cd7ec254cda659c5e5a19a42105e370e04c.diff LO

[PATCH] D154950: [include-cleaner] Fix the `fixIncludes` API not respect main-file header.

2023-07-11 Thread Haojian Wu 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 rG7f3d2cd7ec25: [include-cleaner] Fix the `fixIncludes` API not respect main-file header. (authored by hokein). Repository: rG LLVM Github Monorepo

[PATCH] D153339: [clang] Support vectors in __builtin_isfpclass

2023-07-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. This seems reasonable to me, but I do wonder if changing the return type from int to bool will cause surprises for anyone. I see why it's done, but this seems more like a C interface (to me) which would return an `int`; returning a `bool` gets promoted to `int` wh

[PATCH] D153612: [clang][analyzer] Add and change NoteTags in StdLibraryFunctionsChecker.

2023-07-11 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp:1305 + std::string Note = + llvm::formatv(Case.getNote().str().c_str(), +cast(Call.getDecl())->getDeclName()); dona

[PATCH] D153659: [RISCV] Fix name mangling for LMUL!=1 vector types with attribute(rvv_vector_bits)

2023-07-11 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 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153659/new/ https://reviews.llvm.org/D153659 _

[PATCH] D152632: [Clang] Add warnings for CWG2521

2023-07-11 Thread Vlad Serebrennikov via Phabricator via cfe-commits
Endill accepted this revision as: Endill. Endill added a comment. DR testing side looks good, but you should wait for more approvals. Thank you for addressing all the issues there! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D152632/new/ https://reviews.llvm.org/D152632 __

[PATCH] D153156: [Clang] CWG1473: do not err on the lack of space after operator""

2023-07-11 Thread Vlad Serebrennikov via Phabricator via cfe-commits
Endill added inline comments. Comment at: clang/test/CXX/drs/dr14xx.cpp:491 + float operator ""_E(const char *); + // expected-warning@+1 {{user-defined literal suffixes not starting with '_' are reserved; no literal will invoke this operator}} + float operator ""E(const char

[PATCH] D144634: [Clang][OpenMP] Support for Code Generation of loop bind clause

2023-07-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:9838 +def err_omp_loop_reduction_clause : Error< + "reduction clause not allowed with '#pragma omp loop bind(teams)'">; def warn_break_binds_to_switch : Warning< 'reduct

[PATCH] D154675: [Clang] Fix crash when emitting diagnostic for out of order designated initializers in C++

2023-07-11 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 but please land with a release note. Comment at: clang/test/SemaCXX/cxx2a-initializer-aggregates.cpp:66 .y = 1, // override-note {{previous}} - .y = 1,

[clang] 1bbaabb - [clang] Add test for CWG1710 and related issues

2023-07-11 Thread Vlad Serebrennikov via cfe-commits
Author: Vlad Serebrennikov Date: 2023-07-11T16:24:39+03:00 New Revision: 1bbaabb90dd72f78ea290b71dfe3bf2689ad7403 URL: https://github.com/llvm/llvm-project/commit/1bbaabb90dd72f78ea290b71dfe3bf2689ad7403 DIFF: https://github.com/llvm/llvm-project/commit/1bbaabb90dd72f78ea290b71dfe3bf2689ad7403.

[PATCH] D151697: [clang] Add test for CWG1710 and related issues

2023-07-11 Thread Vlad Serebrennikov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1bbaabb90dd7: [clang] Add test for CWG1710 and related issues (authored by Endill). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151697/new/ https://review

[PATCH] D154961: [clang][dataflow] Include fields initialized in an `InitListExpr` in `getModeledFields()`.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. mboehme requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Previously, we were including these fields only

[PATCH] D154962: [clangd] Use canonical path as resolved path for includes.

2023-07-11 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo created this revision. Herald added subscribers: kadircet, arphaman. Herald added a project: All. VitaNuo requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. Repository: rG LLVM Github Monorepo http

[PATCH] D154963: [Format][Tooling] Fix HeaderIncludes::insert not respect the main-file header.

2023-07-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added reviewers: sammccall, kadircet. Herald added a project: All. hokein requested review of this revision. Herald added projects: clang, clang-tools-extra. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D154963 Files: clang-tools-extra/inc

[PATCH] D154186: [clang][DeclPrinter] Fix AST print of delegating constructors

2023-07-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thank you for the fix! This generally LGTM, but I did find some extra test cases to add. Comment at: clang/test/AST/ast-print-method-decl.cpp:1 +// RUN: %clang_cc1 -ast-print %s -o - | FileCheck %s + I think the file should be na

[PATCH] D154503: [Sema] Fix handling of functions that hide classes

2023-07-11 Thread John Brawn via Phabricator via cfe-commits
john.brawn added inline comments. Comment at: clang/lib/Sema/SemaLookup.cpp:507 + // C++ [basic.scope.hiding]p2: + // A class name or enumeration name can be hidden by the name of shafik wrote: > This section does not exist anymore, it was replaced in > [p

[PATCH] D154962: [clangd] Use canonical path as resolved path for includes.

2023-07-11 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clangd/Headers.cpp:57-61 + auto CanonicalPath = + File ? getCanonicalPath(File->getFileEntry().getLastRef(), +

[PATCH] D154903: clangd: Provide the resource dir via environment variable

2023-07-11 Thread Paul Smith via Phabricator via cfe-commits
madscientist added a comment. Thanks for adding Sam. I tried to do this but failed: his Phabricator handle isn't available in CODE_OWNERS.txt and my attempts to add him via his email address failed. I have no Phabricator fu! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D154295: [Driver][MSVC] Support DWARF fission when using LTO on Windows

2023-07-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D154295#4482818 , @HaohaiWen wrote: > In D154295#4477203 , @hans wrote: > >> In D154295#4477165 , @HaohaiWen >> wrote: >> It would be nice t

[PATCH] D154965: [clang][dataflow] Fix initializaing a reference field with an `InitListExpr`.

2023-07-11 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. mboehme requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. I added a test for this as the ongoing migration

[PATCH] D154935: [clang][dataflow] Introduce `getFieldValue()` test helpers.

2023-07-11 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added inline comments. Comment at: clang/unittests/Analysis/FlowSensitive/DataflowEnvironmentTest.cpp:94 Environment Env(DAContext, *Fun); - Value *Val = Env.createValue(Ty); - ASSERT_NE(Val, nullptr); - StructValue *SVal = clang

[PATCH] D154503: [Sema] Fix handling of functions that hide classes

2023-07-11 Thread John Brawn via Phabricator via cfe-commits
john.brawn added inline comments. Comment at: clang/lib/Sema/SemaLookup.cpp:542 +N = Decls.size(); + } + rjmccall wrote: > john.brawn wrote: > > rjmccall wrote: > > > This is going to fire on every single ordinary lookup that finds multiple > > > declaratio

[PATCH] D154969: [dataflow] document flow condition

2023-07-11 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: ymandel. Herald added subscribers: martong, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. sammccall requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. There's

[PATCH] D154905: [clang] Implement `PointerLikeTraits` for `{File,Directory}EntryRef`

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 539089. jansvoboda11 added a comment. Forward `NumLowBitsAvailable` to `PointerLikeTypeTraits` of the underlying pointer. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154905/new/ https://reviews.llvm.org

[PATCH] D154503: [Sema] Fix handling of functions that hide classes

2023-07-11 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: clang/lib/Sema/SemaLookup.cpp:542 +N = Decls.size(); + } + john.brawn wrote: > rjmccall wrote: > > john.brawn wrote: > > > rjmccall wrote: > > > > This is going to fire on every single ordinary lookup that finds

[PATCH] D154905: [clang] Implement `PointerLikeTraits` for `{File,Directory}EntryRef`

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked an inline comment as done. jansvoboda11 added inline comments. Comment at: clang/include/clang/Basic/DirectoryEntry.h:211 + + static constexpr int NumLowBitsAvailable = 3; +}; benlangmuir wrote: > I suggest not hard-coding it if you can get a

[PATCH] D154701: [clang] Overridden CXXMethodDecl::isVirtual() assertion failed before fully imported.

2023-07-11 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. It is possible to reproduce the same problem with this test added to ASTImporterTest.cpp: TEST_P(ASTImporterOptionSpecificTestBase, ImportVirtualOverriddenMethodTest) { const char *Code = R"( void f1(); class A { virtual void f(){

[clang] 7d6c2e1 - [clang] Use llvm.is_fpclass to implement FP classification functions

2023-07-11 Thread Serge Pavlov via cfe-commits
Author: Serge Pavlov Date: 2023-07-11T21:34:53+07:00 New Revision: 7d6c2e18114de9900d1b012cf9c219803b183f63 URL: https://github.com/llvm/llvm-project/commit/7d6c2e18114de9900d1b012cf9c219803b183f63 DIFF: https://github.com/llvm/llvm-project/commit/7d6c2e18114de9900d1b012cf9c219803b183f63.diff

[PATCH] D112932: Use llvm.is_fpclass to implement FP classification functions

2023-07-11 Thread Serge Pavlov 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 rG7d6c2e18114d: [clang] Use llvm.is_fpclass to implement FP classification functions (authored by sepavloff). Changed prior to commit: https://revie

[PATCH] D154965: [clang][dataflow] Fix initializaing a reference field with an `InitListExpr`.

2023-07-11 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/Transfer.cpp:720-725 for (auto It : llvm::zip(Fields, S->inits())) { const FieldDecl *Field = std::get<

[PATCH] D154915: [ARM][AArch64] Add ARM specific builtin for clz that is not undefined for 0 in ubsan.

2023-07-11 Thread Tomas Matheson via Phabricator via cfe-commits
tmatheson added a comment. I would prefer the simplicity of adding a check in the intrinsic itself, rather than adding the target-specific builtins. Slightly worse codegen at -O0 doesn't matter imho. However I don't feel very strongly about it, so if others are happy with this then LGTM. Repo

[PATCH] D154915: [ARM][AArch64] Add ARM specific builtin for clz that is not undefined for 0 in ubsan.

2023-07-11 Thread Tomas Matheson via Phabricator via cfe-commits
tmatheson added a comment. Also thanks for fixing this! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154915/new/ https://reviews.llvm.org/D154915 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D154969: [dataflow] document flow condition

2023-07-11 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/include/clang/Analysis/FlowSensitive/DataflowEnvironment.h:528 - /// Returns the token that identifies the flow condition of the environment. +

[PATCH] D153892: [NFC] Initialize class member pointers to nullptr.

2023-07-11 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann accepted this revision. tahonermann added a comment. This revision is now accepted and ready to land. Thanks, Sindhu! This looks good to me! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153892/new/ https://reviews.llvm.org/D153892 __

[PATCH] D152658: [InstCombine] Change SimplifyDemandedVectorElts to use PoisonElts instead of UndefElts

2023-07-11 Thread Manuel Brito via Phabricator via cfe-commits
ManuelJBrito added a comment. Herald added a subscriber: wangpc. ping :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D152658/new/ https://reviews.llvm.org/D152658 ___ cfe-commits mailing list cfe-commit

[PATCH] D152021: [clang][AIX] Fix Overly Strict LTO Option Checking against `data-sections` when `mxcoff-roptr` is in Effect

2023-07-11 Thread Qiongsi Wu via Phabricator via cfe-commits
qiongsiwu1 updated this revision to Diff 539105. qiongsiwu1 added a comment. Fixing inconsistent braces. Thanks for the feedback @hubert.reinterpretcast ! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D152021/new/ https://reviews.llvm.org/D152021 F

[PATCH] D154969: [dataflow] document flow condition

2023-07-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. Nice! Definitely should have been defined earlier... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154969/new/ https://reviews.llvm.org/D154969 ___ cfe-commits mailing list cfe-c

[PATCH] D154869: [Flang] [FlangRT] Implement FlangRT library as solution to Flang's runtime LLVM integration

2023-07-11 Thread Paul Scoropan via Phabricator via cfe-commits
pscoro updated this revision to Diff 539113. pscoro added a comment. Some small changes, still non functional Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154869/new/ https://reviews.llvm.org/D154869 Files: clang/lib/Driver/ToolChains/CommonArg

[PATCH] D145302: [clangd] Add library for clangd main function

2023-07-11 Thread Ivan Murashko via Phabricator via cfe-commits
ivanmurashko updated this revision to Diff 539119. ivanmurashko added a comment. rebase before the final push Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D145302/new/ https://reviews.llvm.org/D145302 Files: clang-tools-extra/clangd/tool/CMakeLi

[PATCH] D150292: [clang][modules] Serialize `Module::DefinitionLoc`

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 539120. jansvoboda11 added a comment. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150292/new/ https://reviews.llvm.org/D150292 Files: clang/include/clang/Serialization/ASTBitCodes.h clang/li

[PATCH] D154962: [clangd] Use canonical path as resolved path for includes.

2023-07-11 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo updated this revision to Diff 539121. VitaNuo added a comment. Address comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154962/new/ https://reviews.llvm.org/D154962 Files: clang-tools-extra/clangd/Headers.cpp Index: clang-tools-e

[PATCH] D150320: [clang][modules][deps] Avoid checks for relocated modules

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 539122. jansvoboda11 added a comment. Rename the new preprocessor option, fix failing test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150320/new/ https://reviews.llvm.org/D150320 Files: clang/include

[PATCH] D154962: [clangd] Use canonical path as resolved path for includes.

2023-07-11 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo marked an inline comment as done. VitaNuo added a comment. Thanks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154962/new/ https://reviews.llvm.org/D154962 ___ cfe-commits mailing list cfe-comm

[PATCH] D41416: [modules] [pch] Do not deserialize all lazy template specializations when looking for one.

2023-07-11 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: clang/lib/AST/DeclTemplate.cpp:337 +void RedeclarableTemplateDecl::loadLazySpecializationsImpl( + bool OnlyPartial/*=false*/) const { // Grab the most recent declaration to ensure we've load

  1   2   3   >