[clang] 68dd514 - [Driver] Simplify handling of -mabi=vec-default -mabi=vec-extabi

2023-04-25 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-04-24T22:59:54-07:00 New Revision: 68dd51421f16f1e17cd453cb1730fcca99a6cfb7 URL: https://github.com/llvm/llvm-project/commit/68dd51421f16f1e17cd453cb1730fcca99a6cfb7 DIFF: https://github.com/llvm/llvm-project/commit/68dd51421f16f1e17cd453cb1730fcca99a6cfb7.diff

[PATCH] D148981: [clang][Interp] PointerToBoolean casts

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG7766648c3aff: [clang][Interp] PointerToBoolean casts (authored by tbaeder). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148981/new/

[clang] 7766648 - [clang][Interp] PointerToBoolean casts

2023-04-25 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2023-04-25T08:04:08+02:00 New Revision: 7766648c3aff43408b5d17214fc67c8521952558 URL: https://github.com/llvm/llvm-project/commit/7766648c3aff43408b5d17214fc67c8521952558 DIFF: https://github.com/llvm/llvm-project/commit/7766648c3aff43408b5d17214fc67c8521952558.diff

[clang] dc72e8f - [RISCV][NFC] skip non-RISCV target test riscv32-zihintntl.c

2023-04-25 Thread Piyou Chen via cfe-commits
Author: Piyou Chen Date: 2023-04-24T23:14:56-07:00 New Revision: dc72e8fe675866b93748d54bc5e04b14c675f476 URL: https://github.com/llvm/llvm-project/commit/dc72e8fe675866b93748d54bc5e04b14c675f476 DIFF: https://github.com/llvm/llvm-project/commit/dc72e8fe675866b93748d54bc5e04b14c675f476.diff

[clang] a1e9b71 - [clang] Modernize SkipBodyInfo (NFC)

2023-04-25 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2023-04-24T23:15:55-07:00 New Revision: a1e9b718a53ce41ae11b3cf904f212223b537fca URL: https://github.com/llvm/llvm-project/commit/a1e9b718a53ce41ae11b3cf904f212223b537fca DIFF: https://github.com/llvm/llvm-project/commit/a1e9b718a53ce41ae11b3cf904f212223b537fca.diff

[PATCH] D149126: [RISCV][NFC] skip non-RISCV target test riscv32-zihintntl.c

2023-04-25 Thread Piyou Chen via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGdc72e8fe6758: [RISCV][NFC] skip non-RISCV target test riscv32-zihintntl.c (authored by BeMg). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D149123: [AArch64][InlineAsm]Add Clang support for flag output constraints

2023-04-25 Thread Mingming Liu via Phabricator via cfe-commits
mingmingl updated this revision to Diff 516640. mingmingl edited the summary of this revision. mingmingl added reviewers: dmgreen, nickdesaulniers, efriedma. mingmingl added a comment. remove 'No newline at end of file' CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149123/new/

[clang] c9e403d - [clang][Interp] Fix zero-init of float and pointer arrays

2023-04-25 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2023-04-25T09:00:47+02:00 New Revision: c9e403d1992b064e9cd5b94749fb3f00fa0c0910 URL: https://github.com/llvm/llvm-project/commit/c9e403d1992b064e9cd5b94749fb3f00fa0c0910 DIFF: https://github.com/llvm/llvm-project/commit/c9e403d1992b064e9cd5b94749fb3f00fa0c0910.diff

[PATCH] D149059: [clang][Interp] Fix zero-init of float and pointer arrays

2023-04-25 Thread Timm Bäder 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 rGc9e403d1992b: [clang][Interp] Fix zero-init of float and pointer arrays (authored by tbaeder). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D147610: [RISCV][MC] Add support for experimental Zfbfmin extension

2023-04-25 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. In D147610#4294322 , @joshua-arch1 wrote: > In D147610#4294260 , @craig.topper > wrote: > >> In D147610#4294247 , @joshua-arch1 >> wrote:

[PATCH] D148355: [analyzer] Fix comparison logic in ArrayBoundCheckerV2

2023-04-25 Thread Donát Nagy via Phabricator via cfe-commits
donat.nagy marked 4 inline comments as done. donat.nagy added a comment. @steakhal I marked a few comments as Done (I accidentally missed some when I was creating the most recent patch) and now the only not-Done thing is the followup commit for refactoring the optionalness of RegionRawOffsetV2.

[PATCH] D148355: [analyzer] Fix comparison logic in ArrayBoundCheckerV2

2023-04-25 Thread Donát Nagy via Phabricator via cfe-commits
donat.nagy added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/ArrayBoundCheckerV2.cpp:173 + const MemSpaceRegion *SR = rawOffset.getRegion()->getMemorySpace(); + if (SR->getKind() != MemRegion::UnknownSpaceRegionKind) { +// a pointer to

[clang] 5cda0d1 - [clang] Add test for CWG1821

2023-04-25 Thread Vlad Serebrennikov via cfe-commits
Author: Vlad Serebrennikov Date: 2023-04-25T09:03:46+03:00 New Revision: 5cda0d165a752c8041e8da4d39632c001463fa30 URL: https://github.com/llvm/llvm-project/commit/5cda0d165a752c8041e8da4d39632c001463fa30 DIFF:

[PATCH] D149003: [clang] Add test for CWG1821

2023-04-25 Thread Vlad Serebrennikov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG5cda0d165a75: [clang] Add test for CWG1821 (authored by Endill). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149003/new/ https://reviews.llvm.org/D149003

[PATCH] D149126: [RISCV][NFC] skip non-RISCV target test riscv32-zihintntl.c

2023-04-25 Thread Piyou Chen via Phabricator via cfe-commits
BeMg created this revision. Herald added subscribers: jobnoorman, luke, VincentWu, vkmr, frasercrmck, evandro, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng,

[clang] 7f59dba - [Driver] Remove no-op -frewrite-map-file=

2023-04-25 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-04-24T23:18:59-07:00 New Revision: 7f59dba564cac9868111e7b5631bd54f9c959fca URL: https://github.com/llvm/llvm-project/commit/7f59dba564cac9868111e7b5631bd54f9c959fca DIFF: https://github.com/llvm/llvm-project/commit/7f59dba564cac9868111e7b5631bd54f9c959fca.diff

[PATCH] D148962: [RISCV] Make Zicntr and Zihpm imply Zicsr.

2023-04-25 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. Forgot to make this dependent on @reames patch D144215 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148962/new/ https://reviews.llvm.org/D148962

[PATCH] D149123: [AArch64][InlineAsm]Add Clang support for flag output constraints

2023-04-25 Thread Mingming Liu via Phabricator via cfe-commits
mingmingl added a comment. While testing this patch with `./bin/clang -cc1 -S -triple=aarch64 inline-asm-aarch64-flag-output.c` (which invokes global-isel for instruction selection according to `print-after-all` output), turns out GlobalISel doesn't support flag output yet (for x86 or

[PATCH] D143364: [RISCV] Support scalar/fix-length vector NTLH intrinsic with different domain

2023-04-25 Thread NAKAMURA Takumi via Phabricator via cfe-commits
chapuni added inline comments. Comment at: clang/lib/Headers/CMakeLists.txt:360 endif() if(RISCV IN_LIST LLVM_TARGETS_TO_BUILD) # Generate riscv_vector.h Here Comment at: clang/test/CodeGen/RISCV/ntlh-intrinsics/riscv32-zihintntl.c:5

[PATCH] D147989: [clang] Fix Attribute Placement

2023-04-25 Thread Priyanshi Agarwal via Phabricator via cfe-commits
ipriyanshi1708 marked an inline comment as done. ipriyanshi1708 added a comment. In D147989#4293278 , @aaron.ballman wrote: > Oops, I spoke too soon -- it looks like the precommit CI failure is related > to this patch. This is what I get when I tested

[PATCH] D134821: [flang][driver] Allow main program to be in an archive

2023-04-25 Thread Shao-Ce SUN via Phabricator via cfe-commits
sunshaoce updated this revision to Diff 516651. sunshaoce added a comment. Address @awarzynski's comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134821/new/ https://reviews.llvm.org/D134821 Files: clang/lib/Driver/ToolChains/Gnu.cpp

[PATCH] D148723: [clang] Enforce external linkage for inline builtin original declaration

2023-04-25 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 516645. serge-sans-paille retitled this revision from "[clang] Enforce internal linkage for inline builtin" to "[clang] Enforce external linkage for inline builtin original declaration". serge-sans-paille edited the summary of this revision.

[PATCH] D148949: [dataflow] HTMLLogger - show the value of the current expr

2023-04-25 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/HTMLLogger.cpp:96 +for (const auto& Prop : V.properties()) + JOS.attributeObject(Prop.first(), [&] { dump(*Prop.second); }); + sammccall wrote: > mboehme wrote: > > IIUC, this

[PATCH] D146418: Support for OpenMP 5.0 sec 2.12.7 - Declare Target initializer expressions

2023-04-25 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:14467-14468 + // directive and has static storage duration. + if (D && D->hasAttr() && isa(D)) { +if ((cast(D))->hasGlobalStorage()) + ActOnOpenMPImplicitDeclareTarget(D);

[PATCH] D148601: [Clang] Handle Error message to output proper Prefix

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. In D148601#4279604 , @Unique_Usman wrote: > In D148601#4279334 , @tbaeder wrote: > >> I am not 100% sure about the semantics of passing multiple prefixes, i.e. if >> the error is

[PATCH] D149160: [clang][analyzer] Handle special value AT_FDCWD in affected standard functions

2023-04-25 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 516818. balazske added a comment. Fixed formatting problems. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149160/new/ https://reviews.llvm.org/D149160 Files:

[PATCH] D148987: [clang][Interp] Check Neg ops for errors

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/Interp/Interp.h:438-441 + // FIXME: This code Just Works[tm] for floats, but it's probably not doing + // the right thing. At least the diagnostic could be better without + // the conversion to an APInt. +

[PATCH] D148723: [clang] Enforce external linkage for inline builtin original declaration

2023-04-25 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Really, I'd prefer to keep isInlineBuiltinDeclaration() targeted as narrowly as possible; part of that is making it not trigger for C++ inline functions (which it never did in the past). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148723/new/

[PATCH] D142401: [Clang] Fix a crash when recursively callig a default member initializer.

2023-04-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik accepted this revision. shafik 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/D142401/new/ https://reviews.llvm.org/D142401

[PATCH] D72538: [ThinLTO] Add additional ThinLTO pipeline testing with new PM

2023-04-25 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. In D72538#4291552 , @nikic wrote: > Would it be possible to cut down the Clang side tests to only check parts > that Clang controls in some way, e.g. that SLPVectorizer is enabled? This > test is something of a PITA because it

[PATCH] D103930: [clang][HeaderSearch] Fix implicit module when using header maps

2023-04-25 Thread Andrew Gallagher via Phabricator via cfe-commits
andrewjcg added a comment. @ivanmurashko: Sorry for the delay getting back to you here. Feel free to commandeer, as I don't have plans to get to this soon. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103930/new/

[PATCH] D147281: Stop modifying trailing return types.

2023-04-25 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Looks like this caused a change in behavior: https://github.com/llvm/llvm-project/issues/62361 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147281/new/ https://reviews.llvm.org/D147281

[PATCH] D149123: [AArch64][InlineAsm]Add Clang support for flag output constraints

2023-04-25 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/lib/Basic/Targets/AArch64.cpp:1216 +// Returns the length of cc constraint. +static unsigned matchAsmCCConstraint(const char *) { + constexpr unsigned len = 5; davidxl wrote: > Name is not modified in

[PATCH] D149144: [clang][dataflow] Eliminate intermediate `ReferenceValue`s from `Environment::DeclToLoc`.

2023-04-25 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added subscribers: martong, xazax.hun, inglorion. 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. For the wider context of this

[PATCH] D146418: Support for OpenMP 5.0 sec 2.12.7 - Declare Target initializer expressions

2023-04-25 Thread Ritanya via Phabricator via cfe-commits
RitanyaB updated this revision to Diff 516733. RitanyaB added a comment. Adding the support in SemaOpenMP.cpp. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146418/new/ https://reviews.llvm.org/D146418 Files: clang/include/clang/Sema/Sema.h clang/lib/Sema/SemaDecl.cpp

[PATCH] D149165: [clangd] Deduplicate missing-include findings

2023-04-25 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: VitaNuo. Herald added a subscriber: arphaman. Herald added a project: All. kadircet requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. Repository:

[PATCH] D149163: [NFC][CLANG] Fix coverity remarks about large copy by values

2023-04-25 Thread Soumi Manna via Phabricator via cfe-commits
Manna updated this revision to Diff 516834. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149163/new/ https://reviews.llvm.org/D149163 Files: clang/include/clang/Sema/CodeCompleteConsumer.h clang/lib/CodeGen/CGGPUBuiltin.cpp clang/lib/CodeGen/CGNonTrivialStruct.cpp

[PATCH] D141451: [clang] report inlining decisions with -Wattribute-{warning|error}

2023-04-25 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. Herald added a subscriber: hoy. Ping for review Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141451/new/ https://reviews.llvm.org/D141451 ___ cfe-commits mailing list

[PATCH] D115907: [misexpect] Re-implement MisExpect Diagnostics

2023-04-25 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D115907#4295923 , @paulkirth wrote: >> 2. Due to inlining etc., it often gets the source locations wrong, which >> means it points at code where again there were no expectations -- but >> perhaps that code got inlined into an

[PATCH] D148967: Disable atexit()-based lowering when LTO'ing kernel/kext code

2023-04-25 Thread Ahmed Bougacha via Phabricator via cfe-commits
ab accepted this revision. ab added a comment. This revision is now accepted and ready to land. A comment inline, but LGTM otherwise, thanks! Comment at: llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp:1208 + // -disable-atexit-based-global-dtor-lowering CodeGen flag. + //

[PATCH] D147989: [clang] Fix Attribute Placement

2023-04-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. The issue is that `GetDiagnosticTypeSpecifierID()` is called for more diagnostics than just `warn_declspec_attribute_ignored`. You need to also update the `err_constexpr_tag` and `err_standalone_class_nested_name_specifier` to add `enum class` and `enum struct`

[PATCH] D149163: [NFC][CLANG] Fix coverity remarks about large copy by values

2023-04-25 Thread Soumi Manna via Phabricator via cfe-commits
Manna created this revision. Manna added a reviewer: tahonermann. Herald added a subscriber: arphaman. Herald added a project: All. Manna requested review of this revision. Herald added a project: clang. Reported By Static Analyzer Tool, Coverity: Big parameter passed by value Copying large

[PATCH] D149098: [Clang] Add tests and mark as implemented WG14 N2728 (char16_t & char32_t string literals shall be UTF-16 & UTF-32)

2023-04-25 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann updated this revision to Diff 516835. tahonermann added a comment. Thank you @cor3ntin, that was an excellent suggestion; this is much more readable now! I updated the new code to use custom verify tags (I left the existing code alone). Repository: rG LLVM Github Monorepo

[PATCH] D142907: LangRef: Add "dynamic" option to "denormal-fp-math"

2023-04-25 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. Oh, sorry, I missed that the new code specifically runs on functions imported using -mlink-builtin-bitcode. I somehow thought it was running on all functions. LGTM CHANGES SINCE LAST

[PATCH] D149123: [AArch64][InlineAsm]Add Clang support for flag output constraints

2023-04-25 Thread David Li via Phabricator via cfe-commits
davidxl added inline comments. Comment at: clang/lib/Basic/Targets/AArch64.cpp:1216 +// Returns the length of cc constraint. +static unsigned matchAsmCCConstraint(const char *) { + constexpr unsigned len = 5; Name is not modified in this method, so perhaps

[PATCH] D149172: [clang][Interp] Emit proper diagnostic when comparing unrelated pointers

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, erichkeane, tahonermann, shafik. Herald added a project: All. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Also adds `toDiagnosticString()` to `Pointer` so

[PATCH] D148757: [clang] Apply last -fcoverage-prefix-map option

2023-04-25 Thread Gulfem Savrun Yeniceri via Phabricator via cfe-commits
gulfem updated this revision to Diff 516853. gulfem added a comment. Updated the text. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148757/new/ https://reviews.llvm.org/D148757 Files: clang/include/clang/Basic/CodeGenOptions.h

[PATCH] D103930: [clang][HeaderSearch] Fix implicit module when using header maps

2023-04-25 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Looks like this patch causes a number of issues for us, I will work with > @jansvoboda11 to see if there's some way to resolve them. If you can share a reproducer I'm pretty sure @ivanmurashko can help make it work for y'all too. Thanks! Repository: rG LLVM

[PATCH] D146386: [MS ABI] Fix mangling references to declarations.

2023-04-25 Thread Andrey Ali Khan Bolshakov via Phabricator via cfe-commits
bolshakov-a added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146386/new/ https://reviews.llvm.org/D146386 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D148730: [C11] Allow initialization of an atomic-qualified pointer from a null pointer constant

2023-04-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D148730#4294781 , @bgraur wrote: > We see the same compilation error as the one reported by @sbc100 in several > other C libraries. > > Here's a short reproducer: https://godbolt.org/z/Y8eds47na > > The tests imply that

[PATCH] D149154: [clang][Interp] Emit diagnostic when comparing function pointers

2023-04-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/AST/Interp/Interp.h:652-653 + const SourceInfo = S.Current->getSource(OpPC); + S.FFDiag(Loc, diag::note_constexpr_pointer_comparison_unspecified) + << LS << RS; + return false; Can we pass in

[PATCH] D115907: [misexpect] Re-implement MisExpect Diagnostics

2023-04-25 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth added a comment. Thanks for the report Hans. In D115907#4295363 , @hans wrote: > We gave this a try in Chromium: > https://bugs.chromium.org/p/chromium/issues/detail?id=1434989 > > While the diagnostics are interesting, two things make this

[PATCH] D148987: [clang][Interp] Check Neg ops for errors

2023-04-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/AST/Interp/Interp.h:438-441 + // FIXME: This code Just Works[tm] for floats, but it's probably not doing + // the right thing. At least the diagnostic could be better without + // the conversion to an APInt. +

[clang] 1395cde - Fix codegen for initialization of global atomics

2023-04-25 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2023-04-25T11:37:06-04:00 New Revision: 1395cde24b3641e284bb1daae7d56c189a2635e3 URL: https://github.com/llvm/llvm-project/commit/1395cde24b3641e284bb1daae7d56c189a2635e3 DIFF: https://github.com/llvm/llvm-project/commit/1395cde24b3641e284bb1daae7d56c189a2635e3.diff

[PATCH] D149098: [Clang] Add tests and mark as implemented WG14 N2728 (char16_t & char32_t string literals shall be UTF-16 & UTF-32)

2023-04-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM! Comment at: clang/test/Lexer/char-literal.cpp:49 +#ifndef __cplusplus +// expected-error@-2 {{universal character name refers to a control character}} +#endif cor3ntin wrote: > I think

[PATCH] D148372: [clang] add diagnose when member function contains invalid default argument

2023-04-25 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Are there any calls to `Sema::ActOnParamDefaultArgumentError` left? If not, can you also remove the function? Otherwise this LGTM, thanks! Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D148869: [Driver][BareMetal] Support --emit-static-lib in BareMetal driver

2023-04-25 Thread Alex Brachet via Phabricator via cfe-commits
abrachet accepted this revision. abrachet added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Driver/ToolChains/BareMetal.cpp:170 bool BareMetal::handlesTarget(const llvm::Triple ) { return isARMBareMetal(Triple) ||

[PATCH] D141451: [clang] report inlining decisions with -Wattribute-{warning|error}

2023-04-25 Thread Erich Keane via Phabricator via cfe-commits
erichkeane accepted this revision. erichkeane added a comment. This revision is now accepted and ready to land. Sorry, I didn't see your updates I guess! Thanks for the yak-shave btw, I realize that has turned into a heck of a mess :/ CFE LGTM. I don't believe I can approve the LLVM

[PATCH] D148723: [clang] Enforce external linkage for inline builtin original declaration

2023-04-25 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. I'm a little concerned that this will explode in unexpected ways... in particular, it'll fail to link if the function doesn't actually exist externally. Which it probably doesn't if it would otherwise be linkonce_odr. CHANGES SINCE LAST ACTION

[PATCH] D149154: [clang][Interp] Emit diagnostic when comparing function pointers

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/Interp/Interp.h:652-653 + const SourceInfo = S.Current->getSource(OpPC); + S.FFDiag(Loc, diag::note_constexpr_pointer_comparison_unspecified) + << LS << RS; + return false; aaron.ballman wrote: >

[PATCH] D148975: -fdebug-prefix-map=: make the last win when multiple prefixes match

2023-04-25 Thread Scott Linder via Phabricator via cfe-commits
scott.linder added inline comments. Comment at: clang/include/clang/Basic/CodeGenOptions.h:209 - std::map DebugPrefixMap; + llvm::SmallVector, 0> DebugPrefixMap; std::map CoveragePrefixMap; MaskRay wrote: > scott.linder wrote: > > What benefit does

[PATCH] D149000: Update with warning message for comparison to NULL pointer

2023-04-25 Thread Krishna Narayanan via Phabricator via cfe-commits
Krishna-13-cyber updated this revision to Diff 516857. Krishna-13-cyber added a comment. - Updated with reviewed changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149000/new/ https://reviews.llvm.org/D149000 Files:

[PATCH] D115907: [misexpect] Re-implement MisExpect Diagnostics

2023-04-25 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth added a comment. In D115907#4296154 , @hans wrote: > In D115907#4295923 , @paulkirth > wrote: > >>> 2. Due to inlining etc., it often gets the source locations wrong, which >>> means it points at code

[clang-tools-extra] 67e02b2 - [clangd] Add support TextDocumentEdit.

2023-04-25 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2023-04-25T13:07:42+02:00 New Revision: 67e02b282b70c05b10e4862fdeae4de45de39844 URL: https://github.com/llvm/llvm-project/commit/67e02b282b70c05b10e4862fdeae4de45de39844 DIFF: https://github.com/llvm/llvm-project/commit/67e02b282b70c05b10e4862fdeae4de45de39844.diff

[PATCH] D148783: [clangd] Add support TextDocumentEdit.

2023-04-25 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 rG67e02b282b70: [clangd] Add support TextDocumentEdit. (authored by hokein). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D115907: [misexpect] Re-implement MisExpect Diagnostics

2023-04-25 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Herald added subscribers: hoy, Enna1, StephenFan. We gave this a try in Chromium: https://bugs.chromium.org/p/chromium/issues/detail?id=1434989 While the diagnostics are interesting, two things make this less useful for our developers: 1. It also fires in situations

[PATCH] D149151: [clang][dataflow][NFC] Remove `SkipPast` parameter from `getStorageLocation(const ValueDecl &).

2023-04-25 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. This parameter was already a no-op, so removing

[PATCH] D149009: [Sema]Select correct lexical context during template instantiate

2023-04-25 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: clang/lib/Sema/SemaTemplateDeduction.cpp:3598 + FD->isDefined(FDFriend, true) && + FDFriend->getFriendObjectKind() != Decl::FriendObjectKind::FOK_None) { +// if Function defined by inline friend, use inline fried as

[PATCH] D149154: [clang][Interp] Emit diagnostic when comparing function pointers

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, erichkeane, tahonermann, shafik. Herald added a project: All. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Function pointers can be compared for

[PATCH] D149088: [clang-format] Add run-clang-format.py script.

2023-04-25 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/tools/run-clang-format.py:63 +default="c,cc,cpp,cxx,c++,h,hh,hpp,hxx,h++") +parser.add_argument('-style', +help='formatting style', what about ```

[PATCH] D149149: [clang][Interp] Check one-past-the-end pointers in GetPtrField

2023-04-25 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder created this revision. tbaeder added reviewers: aaron.ballman, erichkeane, tahonermann, shafik. Herald added a project: All. tbaeder requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Rename CheckBaseDerived to something more

[PATCH] D148601: [Clang] Handle Error message to output proper Prefix

2023-04-25 Thread Usman Akinyemi via Phabricator via cfe-commits
Unique_Usman updated this revision to Diff 516762. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148601/new/ https://reviews.llvm.org/D148601 Files: clang/include/clang/Basic/DiagnosticFrontendKinds.td clang/lib/Frontend/VerifyDiagnosticConsumer.cpp Index:

[PATCH] D146557: [MLIR][OpenMP] Refactoring how map clause is processed

2023-04-25 Thread Kiran Chandramohan via Phabricator via cfe-commits
kiranchandramohan added a comment. In D146557#4292223 , @TIFitis wrote: > Cleaned up how IsBegin argument is passed for createTargetData call. Please submit this directly as an NFC patch. We should always work towards simple patches that are easy to

[PATCH] D149160: [clang][analyzer] Handle special value AT_FDCWD in affected standard functions

2023-04-25 Thread Balázs Kéri via Phabricator via cfe-commits
balazske created this revision. Herald added subscribers: steakhal, manas, ASDenysPetrov, martong, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a reviewer: NoQ. Herald added a

[PATCH] D147218: [OpenMP][Flang][MLIR] Lowering of OpenMP requires directive from parse tree to MLIR

2023-04-25 Thread Sergio Afonso via Phabricator via cfe-commits
skatrak updated this revision to Diff 516730. skatrak added a comment. Try undoing last change. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147218/new/ https://reviews.llvm.org/D147218 Files: flang/include/flang/Lower/OpenMP.h

[PATCH] D149144: [clang][dataflow] Eliminate intermediate `ReferenceValue`s from `Environment::DeclToLoc`.

2023-04-25 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/TypeErasedDataflowAnalysis.cpp:43 +namespace { + There were a number of pre-existing declarations that were ODR violation risks. I'm adding a new file-local function below, so instead

[PATCH] D148783: [clangd] Add support TextDocumentEdit.

2023-04-25 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 516734. hokein marked an inline comment as done. hokein added a comment. update and rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148783/new/ https://reviews.llvm.org/D148783 Files:

[PATCH] D148355: [analyzer] Fix comparison logic in ArrayBoundCheckerV2

2023-04-25 Thread Balázs Benics via Phabricator via cfe-commits
steakhal accepted this revision. steakhal added a comment. This revision is now accepted and ready to land. In D148355#4294798 , @steakhal wrote: > In D148355#4294738 , @donat.nagy > wrote: > >> @steakhal I

[PATCH] D142907: LangRef: Add "dynamic" option to "denormal-fp-math"

2023-04-25 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. In D142907#4288555 , @efriedma wrote: > If you have a library function that's built with > "denormal-fp-math"="dynamic,dynamic", you can link it into code built in any > mode, and LTO should be able to propagate that mode from

[PATCH] D149148: [Sema] Fix _Alignas/isCXX11Attribute() FIXME

2023-04-25 Thread Richard Sandiford via Phabricator via cfe-commits
rsandifo-arm created this revision. rsandifo-arm added a reviewer: erichkeane. Herald added a reviewer: aaron.ballman. Herald added a project: All. rsandifo-arm requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When doing

[PATCH] D149158: [clang][analyzer] Cleanup tests of StdCLibraryFunctionsChecker (NFC)

2023-04-25 Thread Balázs Kéri via Phabricator via cfe-commits
balazske created this revision. Herald added subscribers: steakhal, manas, ASDenysPetrov, martong, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All. balazske requested

[PATCH] D149151: [clang][dataflow][NFC] Remove `SkipPast` parameter from `getStorageLocation(const ValueDecl &).

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

[PATCH] D149162: [Clang][OpenMP][IRBuilder] Move registerTargetGlobalVariable & getAddrOfDeclareTargetVar into the OMPIRBuilder

2023-04-25 Thread Andrew Gozillon via Phabricator via cfe-commits
agozillon created this revision. Herald added subscribers: sunshaoce, bzcheeseman, rriddle, rogfer01, guansong, hiraditya, yaxunl. Herald added a reviewer: sscalpone. Herald added a project: All. agozillon requested review of this revision. Herald added a reviewer: jdoerfert. Herald added

[PATCH] D149162: [Clang][OpenMP][IRBuilder] Move registerTargetGlobalVariable & getAddrOfDeclareTargetVar into the OMPIRBuilder

2023-04-25 Thread Andrew Gozillon via Phabricator via cfe-commits
agozillon added a comment. I've tested this with the two following combinations, x86/AMDGPU and x86/NVPTX (newer plugin I think, not old, a little unsure on the runtime segment) and it passes the Clang test suites, if there is anything else I can do to make sure this is tested nicely and due

[PATCH] D148992: [clang-repl] Fix dynamic library test to avoid cstdio and linker

2023-04-25 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz accepted this revision. sgraenitz added a comment. Thanks. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148992/new/ https://reviews.llvm.org/D148992 ___ cfe-commits mailing list

[PATCH] D149144: [clang][dataflow] Eliminate intermediate `ReferenceValue`s from `Environment::DeclToLoc`.

2023-04-25 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 516745. mboehme added a comment. Add two assertions that I forgot to add in the first upload. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149144/new/ https://reviews.llvm.org/D149144 Files:

[PATCH] D125272: [clang] Add -fcheck-new support

2023-04-25 Thread Pedro Falcato via Phabricator via cfe-commits
heatd added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:4117 + if (const Arg *A = Args.getLastArg(OPT_fcheck_new)) +Opts.CheckNew = true; + MaskRay wrote: > Use `CodeGenOpts<"CheckNew">` and avoid change to this file. CodeGenOpts

[PATCH] D149088: [clang-format] Add run-clang-format.py script.

2023-04-25 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. is it possible to pass other arguments like `-n` if not running in place is there any protection from prevent stdout/stderr from overlapping..? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149088/new/

[PATCH] D148094: [DRAFT][clang][CodeGen] Break up TargetInfo.cpp [6/6]

2023-04-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. This refactoring looks reasonable to me as well. In `clang/lib/Driver`, we have D30372 that splits some huge files into target-specific files. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D129700: [clang] Don't emit type tests for dllexport/import classes

2023-04-25 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. Herald added a subscriber: bd1976llvm. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129700/new/ https://reviews.llvm.org/D129700 ___ cfe-commits mailing list

[clang] f34ecb5 - [clang] Don't emit type tests for dllexport/import classes

2023-04-25 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2023-04-25T14:00:57-07:00 New Revision: f34ecb50e2c03e27b5785576545aab07b3b19a94 URL: https://github.com/llvm/llvm-project/commit/f34ecb50e2c03e27b5785576545aab07b3b19a94 DIFF:

[PATCH] D129700: [clang] Don't emit type tests for dllexport/import classes

2023-04-25 Thread Arthur Eubanks 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 rGf34ecb50e2c0: [clang] Dont emit type tests for dllexport/import classes (authored by aeubanks). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D148967: Disable atexit()-based lowering when LTO'ing kernel/kext code

2023-04-25 Thread Julian Lettner via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc3f0153ec27a: [MachO] Disable atexit()-based lowering when LTOing kernel/kext code (authored by yln). Changed prior to commit: https://reviews.llvm.org/D148967?vs=515929=516862#toc Repository: rG

[clang] c3f0153 - [MachO] Disable atexit()-based lowering when LTO'ing kernel/kext code

2023-04-25 Thread Julian Lettner via cfe-commits
Author: Julian Lettner Date: 2023-04-25T12:13:40-07:00 New Revision: c3f0153ec27a5e2cff97179d319ab99651c4c539 URL: https://github.com/llvm/llvm-project/commit/c3f0153ec27a5e2cff97179d319ab99651c4c539 DIFF:

[PATCH] D148975: -fdebug-prefix-map=: make the last win when multiple prefixes match

2023-04-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay marked an inline comment as done. MaskRay added inline comments. Comment at: clang/include/clang/Basic/CodeGenOptions.h:209 - std::map DebugPrefixMap; + llvm::SmallVector, 0> DebugPrefixMap; std::map CoveragePrefixMap; scott.linder wrote: >

[PATCH] D148216: Add support for annotations in UpdateTestChecks (NFC)

2023-04-25 Thread Henrik G Olsson via Phabricator via cfe-commits
hnrklssn added a comment. In D148216#4266201 , @nikic wrote: > We should probably just use the `META` fallback for all metadata not already > explicitly handled. I think there's pretty little value in adding a special > name for each metadata kind. I

[PATCH] D148975: -fdebug-prefix-map=: make the last win when multiple prefixes match

2023-04-25 Thread Scott Linder via Phabricator via cfe-commits
scott.linder accepted this revision. scott.linder added a comment. This revision is now accepted and ready to land. LGTM, thank you! Does this warrant a release note, as it is changing the behavior in a backwards-incompatible manner? I do think changing to match GCC is worthwhile, even if it

[PATCH] D148372: [clang] add diagnose when member function contains invalid default argument

2023-04-25 Thread Congcong Cai 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 rGe12753ed: [clang] add diagnose when member function contains invalid default argument (authored by HerrCai0907). Repository: rG LLVM Github

[PATCH] D125272: [clang] Add -fcheck-new support

2023-04-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:4117 + if (const Arg *A = Args.getLastArg(OPT_fcheck_new)) +Opts.CheckNew = true; + heatd wrote: > MaskRay wrote: > > Use `CodeGenOpts<"CheckNew">` and avoid change to this

[PATCH] D149193: [Driver] -gsplit-dwarf: derive .dwo names from -o for link actions

2023-04-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D149193#4297043 , @scott.linder wrote: > I'm a bit confused after trying to work out the rules for the GCC version of > `-dumpdir` over at > https://gcc.gnu.org/onlinedocs/gcc/Overall-Options.html#index-dumpdir but it > at

  1   2   >