[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-08-03 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic added a comment. > BTW, can you continue working on the lowering of the convert argument of open > statement? I will take a look at this! Comment at: flang/lib/Lower/Bridge.cpp:2757 +if (funit.isMainProgram()) { + auto conversion =

[PATCH] D130726: [clang][dataflow] Handle multiple context-sensitive calls to the same function

2022-08-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/DataflowEnvironment.cpp:250 + // scope, we do not propagate the maps. + this->LocToVal = std::move(CalleeEnv.LocToVal); + this->MemberLocToStruct = std::move(CalleeEnv.MemberLocToStruct);

[PATCH] D130600: [clang][dataflow] Handle return statements

2022-08-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/Transfer.cpp:345 +// FIXME: Support reference-type returns. +assert(Val->getKind() != Value::Kind::Reference); + Let's do `if (Val->getKind() == Value::Kind::Reference) return;`.

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-08-03 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic updated this revision to Diff 449875. jpenix-quic added a comment. Herald added subscribers: bzcheeseman, sdasgup3, wenzhicui, wrengr, cota, teijeong, rdzhabarov, tatianashp, msifontes, jurahul, Kayjukh, grosul1, Joonsoo, stephenneuendorffer, liufengdb, aartbik, mgester,

[PATCH] D131109: [clang][dataflow][NFC] Fix outdated comment on getStableStorageLocation

2022-08-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev accepted this revision. sgatev added a comment. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131109/new/ https://reviews.llvm.org/D131109 ___ cfe-commits mailing list

[PATCH] D130894: [clang] Print more information about failed static assertions

2022-08-03 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder updated this revision to Diff 449874. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130894/new/ https://reviews.llvm.org/D130894 Files: clang/docs/ReleaseNotes.rst clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h

[PATCH] D130894: [clang] Print more information about failed static assertions

2022-08-03 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder marked 4 inline comments as done. tbaeder added a comment. > +1 to the suggestion to use quotes for a bit of visual distinction between > the diagnostic message and the code embedded within it. One problem is that both the integer value `0` and the character constant `'0'` are printed

[PATCH] D130510: Missing tautological compare warnings due to unary operators

2022-08-03 Thread Muhammad Usman Shahid via Phabricator via cfe-commits
Codesbyusman added a comment. In D130510#3698415 , @rtrieu wrote: > Can you add my earlier test case or something like it to > SemaCXX/warn-bitwise-compare.cpp ? > > template > void foo(int x) { > bool b1 = (x & sizeof(T)) == 8; > bool

[PATCH] D128777: clang/cmake: Drop use of llvm-config for LLVM install discovery

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added inline comments. Comment at: clang/CMakeLists.txt:21-23 + set(INCLUDE_DIRS "${LLVM_BINARY_DIR}/include" "${MAIN_INCLUDE_DIR}") + # Pull values from LLVMConfig.cmake. + set(MAIN_INCLUDE_DIR "${LLVM_INCLUDE_DIR}") tstellar wrote: > This doesn't

[PATCH] D128777: clang/cmake: Drop use of llvm-config for LLVM install discovery

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar updated this revision to Diff 449857. tstellar added a comment. Remove more of the existing code. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128777/new/ https://reviews.llvm.org/D128777 Files: clang/CMakeLists.txt Index:

[PATCH] D130510: Missing tautological compare warnings due to unary operators

2022-08-03 Thread Richard Trieu via Phabricator via cfe-commits
rtrieu added a comment. Can you add my earlier test case or something like it to SemaCXX/warn-bitwise-compare.cpp ? template void foo(int x) { bool b1 = (x & sizeof(T)) == 8; bool b2 = (x & I) == 8; bool b3 = (x & 4) == 8; // only warn here } void run(int x) {

[PATCH] D130123: Extend ptr32 support to be applied on typedef

2022-08-03 Thread Ariel Burton via Phabricator via cfe-commits
Ariel-Burton added a comment. In D130123#3696786 , @rnk wrote: > In D130123#3696752 , @Ariel-Burton > wrote: > >> What is your expectation for your template code fragment? MSVC does not >> accept it. > > Yes,

[PATCH] D131070: [clang][sema] Fix collectConjunctionTerms()

2022-08-03 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. That's just because of the note that https://reviews.llvm.org/D130894 adds, which the patch expects. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131070/new/ https://reviews.llvm.org/D131070

[PATCH] D63329: Allow static linking of libc++ on Linux, just like -static-libstdc++

2022-08-03 Thread Zixuan Wu via Phabricator via cfe-commits
zixuan-wu added a comment. Herald added a subscriber: MaskRay. Herald added a project: All. Is this going to continue? And also if we use libunwind to handle EH, then it uses dladdr function which need link libdl. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D131124: [Serialization] Remove `ORIGINAL_PCH_DIR` record

2022-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 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/D131124/new/ https://reviews.llvm.org/D131124

[PATCH] D131134: [X86] Report error if the amx enabled on the non-64-bits target

2022-08-03 Thread LiuChen via Phabricator via cfe-commits
LiuChen3 created this revision. Herald added a project: All. LiuChen3 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. For now we check if the amx intrinsics used on 64-bits target. This check is not accurate. Repository: rG LLVM Github

[PATCH] D130964: [X86][BF16] Enable __bf16 for x86 targets.

2022-08-03 Thread Freddy, Ye via Phabricator via cfe-commits
FreddyYe added a comment. > Right, but this patch is adding x86 support whenever SSE2 is available. > AVX512BF16 is available on a *very* small slice of processors. In contrast, > e.g. F16C is relatively broadly available, although I understand that we > formally support `_Float16` all the

[PATCH] D130800: [clang][Headers] Avoid compiler warnings in builtin headers

2022-08-03 Thread Dominic 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 rGbbf19005714b: [clang][Headers] Avoid compiler warnings in builtin headers (authored by ddcc). Changed prior to commit:

[clang] bbf1900 - [clang][Headers] Avoid compiler warnings in builtin headers

2022-08-03 Thread Dominic Chen via cfe-commits
Author: Dominic Chen Date: 2022-08-03T17:56:17-07:00 New Revision: bbf19005714b2f6f957cac25e44d381167843732 URL: https://github.com/llvm/llvm-project/commit/bbf19005714b2f6f957cac25e44d381167843732 DIFF: https://github.com/llvm/llvm-project/commit/bbf19005714b2f6f957cac25e44d381167843732.diff

[PATCH] D130058: [Clang] Diagnose ill-formed constant expression when setting a non fixed enum to a value outside the range of the enumeration values

2022-08-03 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. > Given that we have a non-obvious (at least to me) issue in a widely used > third-party library, would we consider giving users some way to opt out of > this error, at least as a transition tool? Thank your feedback, this is very helpful. I won't have time to dig into

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-08-03 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak added a comment. Pointing out the recent changes at the corresponding source locations. Comment at: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp:1570 + {llvm::ConstantInt::get(CGM.SizeTy, AllocSize)}); +

[PATCH] D130754: [X86] Support ``-mindirect-branch-cs-prefix`` for call and jmp to indirect thunk

2022-08-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay accepted this revision. MaskRay added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:6350 + if (Args.hasArg(options::OPT_mindirect_branch_cs_prefix)) +

[PATCH] D131020: Reland "[lldb/Fuzzer] Add fuzzer for expression evaluator"

2022-08-03 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere accepted this revision. JDevlieghere added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131020/new/ https://reviews.llvm.org/D131020 ___ cfe-commits mailing list

[PATCH] D131124: [Serialization] Remove `ORIGINAL_PCH_DIR` record

2022-08-03 Thread Argyrios Kyrtzidis via Phabricator via cfe-commits
akyrtzi created this revision. Herald added a project: All. akyrtzi requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Use of `ORIGINAL_PCH_DIR` record has been superseeded by making PCH/PCM files with relocatable paths at write time.

[PATCH] D130058: [Clang] Diagnose ill-formed constant expression when setting a non fixed enum to a value outside the range of the enumeration values

2022-08-03 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. Sorry for chiming in a bit late here. I'm working on getting a large internal codebase to compile after this change. Most of the issues are easy enough to deal with, but there's one Boost error I'd like to highlight: P8289 . (We might be

[PATCH] D130553: [clang][lld][cmake] Simplify header dirs

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. > When LLVM is being built, the list is two elements long: generated headers > and headers from source. All these changes are guarded by if (CLANG_BUILT_STANDALONE), which means LLVM should already be built. What build configuration are you using where you needed

[PATCH] D128777: clang/cmake: Drop use of llvm-config for LLVM install discovery

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added inline comments. Comment at: clang/CMakeLists.txt:21-23 + set(INCLUDE_DIRS "${LLVM_BINARY_DIR}/include" "${MAIN_INCLUDE_DIR}") + # Pull values from LLVMConfig.cmake. + set(MAIN_INCLUDE_DIR "${LLVM_INCLUDE_DIR}") This doesn't look right (even

[PATCH] D128777: clang/cmake: Drop use of llvm-config for LLVM install discovery

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar updated this revision to Diff 449783. tstellar added a comment. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128777/new/ https://reviews.llvm.org/D128777 Files: clang/CMakeLists.txt Index: clang/CMakeLists.txt

[PATCH] D131076: [clang][modules] Don't depend on sharing FileManager during module build

2022-08-03 Thread Ben Langmuir via Phabricator via cfe-commits
benlangmuir updated this revision to Diff 449781. benlangmuir added a comment. - Updates for review feedback - Attempt to fix one of the Windows path issues - I'm just guessing based on what other VFS tests are doing. I don't know what the other windows failure is about, and probably need to

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 449780. cor3ntin added a comment. Fix self-build - The way we tested for unions was broken - It was also redundant, as we do that before in the same function (`isVariableCapturable`). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

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

2022-08-03 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/StandaloneEmptyCheck.cpp:23 +#include "llvm/ADT/SmallVector.h" +#include + Comment at: clang-tools-extra/clang-tidy/bugprone/StandaloneEmptyCheck.cpp:149 +

[PATCH] D130510: Missing tautological compare warnings due to unary operators

2022-08-03 Thread Muhammad Usman Shahid via Phabricator via cfe-commits
Codesbyusman updated this revision to Diff 449778. Codesbyusman added a comment. Adopted another approach working for the error caught. Kindly review this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130510/new/ https://reviews.llvm.org/D130510

[PATCH] D130516: [llvm] compression classes

2022-08-03 Thread Cole Kissane via Phabricator via cfe-commits
ckissane updated this revision to Diff 449772. ckissane added a comment. - remove uppercase Compress, Decompress Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130516/new/ https://reviews.llvm.org/D130516 Files:

[PATCH] D131084: Add support for specifying the severity of a SARIF Result.

2022-08-03 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. It seems I got confused and conflated the two this morning. In D131084#3697525 , @vaibhav.y wrote: >> Hmm, we can probably use "informational" for notes, warnings, and remarks, >> but I'm kinda partial to proposing the latter two

[PATCH] D131109: [clang][dataflow][NFC] Fix outdated comment on getStableStorageLocation

2022-08-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel accepted this revision. ymandel added a comment. This revision is now accepted and ready to land. thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131109/new/ https://reviews.llvm.org/D131109

[PATCH] D131109: [clang][dataflow][NFC] Fix outdated comment on getStableStorageLocation

2022-08-03 Thread Eric Li via Phabricator via cfe-commits
li.zhe.hua created this revision. li.zhe.hua added a reviewer: sgatev. Herald added subscribers: martong, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. li.zhe.hua requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits.

[PATCH] D131084: Add support for specifying the severity of a SARIF Result.

2022-08-03 Thread Vaibhav Yenamandra via Phabricator via cfe-commits
vaibhav.y added a comment. > Hmm, we can probably use "informational" for notes, warnings, and remarks, > but I'm kinda partial to proposing the latter two upstream. Interesting, I agree that remarks could fit under "informational". As for notes: As I understand it they are always child

[PATCH] D131076: [clang][modules] Don't depend on sharing FileManager during module build

2022-08-03 Thread Ben Barham via Phabricator via cfe-commits
bnbarham accepted this revision. bnbarham added inline comments. This revision is now accepted and ready to land. Comment at: clang/test/ClangScanDeps/modulemap-via-vfs.m:44 "case-sensitive": "false", + 'use-external-names': true, "roots": [ Nitpick: `'`

[PATCH] D130600: [clang][dataflow] Handle return statements

2022-08-03 Thread Sam Estep via Phabricator via cfe-commits
samestep updated this revision to Diff 449752. samestep added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130600/new/ https://reviews.llvm.org/D130600 Files:

[PATCH] D131057: [Sema] -Wformat: support C23 format specifier %b %B

2022-08-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D131057#3697265 , @enh wrote: >> I think making scanf in the same patch makes sense. Let me check existing >> tests... > > fwiw, most of the libcs seem to have been doing these separately because > scanf is harder. i hope to

[clang] c5ccb78 - [clang][Darwin] Always set the default C++ Standard Library to libc++

2022-08-03 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2022-08-03T15:40:27-04:00 New Revision: c5ccb78ade8136134e0ca9dde64de97f913f0f8c URL: https://github.com/llvm/llvm-project/commit/c5ccb78ade8136134e0ca9dde64de97f913f0f8c DIFF: https://github.com/llvm/llvm-project/commit/c5ccb78ade8136134e0ca9dde64de97f913f0f8c.diff

[PATCH] D131057: [Sema] -Wformat: support C23 format specifier %b %B

2022-08-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 449740. MaskRay retitled this revision from "[Sema] -Wformat: support C23 printf %b %B" to "[Sema] -Wformat: support C23 format specifier %b %B". MaskRay edited the summary of this revision. MaskRay added a comment. Herald added subscribers: krytarowski,

[PATCH] D131091: [clang][index] Index unresolved member expression as reference

2022-08-03 Thread Denis Fatkulin via Phabricator via cfe-commits
denis-fatkulin created this revision. denis-fatkulin added a reviewer: hokein. Herald added subscribers: usaxena95, kadircet, arphaman. Herald added a project: All. denis-fatkulin requested review of this revision. Herald added projects: clang, clang-tools-extra. Herald added a subscriber:

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D131057#3697265 , @enh wrote: >> I think making scanf in the same patch makes sense. Let me check existing >> tests... > > fwiw, most of the libcs seem to have been doing these separately because > scanf is harder. i

[PATCH] D131084: Add support for specifying the severity of a SARIF Result.

2022-08-03 Thread Denis Nikitin via Phabricator via cfe-commits
denik added a comment. In D131084#3697256 , @cjdb wrote: > In D131084#3697211 , @vaibhav.y > wrote: > >> Submitting for review: >> >> Some notes: >> >> There are a couple of ways I think we can acheive this, per

[PATCH] D131088: [clang] Apply FixIts to members declared via `using` in derived classes

2022-08-03 Thread Denis Fatkulin via Phabricator via cfe-commits
denis-fatkulin created this revision. Herald added subscribers: usaxena95, kadircet, arphaman. Herald added a project: All. denis-fatkulin requested review of this revision. Herald added projects: clang, clang-tools-extra. Herald added a subscriber: cfe-commits. FixIt don't switch to arrow in

[clang-tools-extra] a274219 - Revert "[Clang][C++20] Support capturing structured bindings in lambdas"

2022-08-03 Thread Corentin Jabot via cfe-commits
Author: Corentin Jabot Date: 2022-08-03T21:00:29+02:00 New Revision: a274219600ea00c4406248acfbea113e29a8ead2 URL: https://github.com/llvm/llvm-project/commit/a274219600ea00c4406248acfbea113e29a8ead2 DIFF:

[PATCH] D131012: No longer place const volatile global variables in a read only section

2022-08-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. On the one hand, we can certainly just have different behavior on BPF targets if this is a common expectation there. On the other hand, if there isn't a requirement to put `const volatile` objects in writable memory, then I'd rather not. If someone has specific

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Elliott Hughes via Phabricator via cfe-commits
enh added a comment. > I think making scanf in the same patch makes sense. Let me check existing > tests... fwiw, most of the libcs seem to have been doing these separately because scanf is harder. i hope to have bionic's scanf done this week though. (note in case you haven't already that

[PATCH] D124435: [X86] Always extend the integer parameters in callee

2022-08-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. I know what you're saying, but I don't think it matches any model of how programmers use command line flags. You're imagining that a programmer sits down and considers all of their flags deeply and holistically before touching any of them, and that's just not how

[PATCH] D131084: Add support for specifying the severity of a SARIF Result.

2022-08-03 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D131084#3697211 , @vaibhav.y wrote: > Submitting for review: > > Some notes: > > There are a couple of ways I think we can acheive this, per the spec: > > 1. The reportingDescriptor (rule) objects can be given a default >

[PATCH] D131020: Reland "[lldb/Fuzzer] Add fuzzer for expression evaluator"

2022-08-03 Thread Chelsea Cassanova via Phabricator via cfe-commits
cassanova updated this revision to Diff 449729. cassanova added a comment. Set the LLDB_FUZZER_TARGET environment variable in the CMake file for the source code to use. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131020/new/ https://reviews.llvm.org/D131020 Files:

[PATCH] D130800: [clang][Headers] Avoid compiler warnings in builtin headers

2022-08-03 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. These changes look reasonable to me, thanks! Comment at: clang/lib/Headers/stdint.h:99-100 typedef __UINT64_TYPE__ uint64_t; +# undef __int_least64_t #

[PATCH] D126676: [clang] Disallow differences in defines used for creating and using PCH

2022-08-03 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. @rnk Can you have another look here? There doesn’t really seem to be anyone else who’s able to give it a review at the moment, but @dexonsmith seemed ok with the idea. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D131057#3697165 , @aaron.ballman wrote: > Thanks for working on this! Please also add a release note for it. Will add:) > I think there are changes missing for ScanfFormatString.cpp to handle `bArg` > and `BArg` that

[PATCH] D131084: Add support for specifying the severity of a SARIF Result.

2022-08-03 Thread Vaibhav Yenamandra via Phabricator via cfe-commits
vaibhav.y created this revision. vaibhav.y added reviewers: aaron.ballman, cjdb, denik, abrahamcd, dbeer1. Herald added a project: All. vaibhav.y edited the summary of this revision. vaibhav.y edited the summary of this revision. vaibhav.y updated this revision to Diff 449713. vaibhav.y added a

[PATCH] D131062: [docs] Add "C++20 Modules"

2022-08-03 Thread Mark de Wever via Phabricator via cfe-commits
Mordante added a comment. Thanks a lot for working on this! I wonder whether it would be better to have some of the more technical information in a separate file and let this file mainly have an introduction to modules in general and how to get started using them in Clang. I haven't tested

[PATCH] D130516: [llvm] compression classes

2022-08-03 Thread Cole Kissane via Phabricator via cfe-commits
ckissane added inline comments. Comment at: llvm/include/llvm/Support/Compression.h:48-51 + Error decompress(ArrayRef Input, uint8_t *UncompressedBuffer, + size_t ) { +return Decompress(Input, UncompressedBuffer, UncompressedSize); + }

[PATCH] D129131: Remove uses of llvm_shutdown

2022-08-03 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added inline comments. Comment at: polly/lib/External/isl/interface/extract_interface.cc:590 delete Clang; - llvm::llvm_shutdown(); nhaehnle wrote: > Meinersbur wrote: > > This file is imported from the upstream project > >

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thanks for working on this! Please also add a release note for it. I think there are changes missing for ScanfFormatString.cpp to handle `bArg` and `BArg` that should be handled at the same time. WDYT? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D130372: [analyzer] Add a new factory function RangeSet::Factory::invert

2022-08-03 Thread Denys Petrov via Phabricator via cfe-commits
ASDenysPetrov added inline comments. Comment at: clang/unittests/StaticAnalyzer/RangeSetTest.cpp:1130 + // Check inverting single range. + this->checkInvert({{MIN, MAX}}, {}); + this->checkInvert({{MIN, MID}}, {{MID + 1, MAX}}); martong wrote: > ASDenysPetrov

[PATCH] D124435: [X86] Always extend the integer parameters in callee

2022-08-03 Thread James Y Knight via Phabricator via cfe-commits
jyknight added a comment. In D124435#3696862 , @rjmccall wrote: > That is an interesting idea. I like that it integrates this into > `-fclang-abi-compat`. The way that `-mno-conservative-small-integer-abi` > ends up meaning opposite things based on

[PATCH] D130130: [clang-tidy] Add an IgnoreMacros option to readability-avoid-const-params-in-decls

2022-08-03 Thread Thomas Etter via Phabricator via cfe-commits
thomasetter updated this revision to Diff 449719. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130130/new/ https://reviews.llvm.org/D130130 Files: clang-tools-extra/clang-tidy/readability/AvoidConstParamsInDecls.cpp clang-tools-extra/clang-tidy/readability/AvoidConstParamsInDecls.h

[clang] c9edf84 - Error instead of assert when making a _BitInt vector

2022-08-03 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2022-08-03T14:05:09-04:00 New Revision: c9edf843fcf954132271214445857498fb47bb72 URL: https://github.com/llvm/llvm-project/commit/c9edf843fcf954132271214445857498fb47bb72 DIFF: https://github.com/llvm/llvm-project/commit/c9edf843fcf954132271214445857498fb47bb72.diff

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Elliott Hughes via Phabricator via cfe-commits
enh accepted this revision. enh added a comment. thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131057/new/ https://reviews.llvm.org/D131057 ___ cfe-commits mailing list

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Dimitry Andric via Phabricator via cfe-commits
dim added a comment. > GCC 12 -Wformat -pedantic emits a warning: > > warning: ISO C17 does not support the ‘%b’ gnu_printf format [-Wformat=] > > The behavior is not ported (and it's unclear to me how to implement it). If you really want this, I think it can be implemented by looking at

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot 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 rG44f2baa3804a: [Clang][C++20] Support capturing structured bindings in lambdas (authored by cor3ntin). Repository: rG LLVM Github Monorepo

[clang-tools-extra] 44f2baa - [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot via cfe-commits
Author: Corentin Jabot Date: 2022-08-03T20:00:01+02:00 New Revision: 44f2baa3804a62ca793f0ff3e43aa71cea91a795 URL: https://github.com/llvm/llvm-project/commit/44f2baa3804a62ca793f0ff3e43aa71cea91a795 DIFF:

[PATCH] D131057: [Sema] -Wformat: support C23 printf %b %B

2022-08-03 Thread Dimitry Andric via Phabricator via cfe-commits
dim accepted this revision. dim added a subscriber: emaste. dim 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/D131057/new/ https://reviews.llvm.org/D131057

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-08-03 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak added a comment. @jdoerfert Attached are the device IR files, generated with -save-temps. F24006188: remarks_parallel_in_multiple_target_state_machines-openmp-amdgcn-amd-amdhsa.ll F24006197:

[PATCH] D131070: [clang][sema] Fix collectConjunctionTerms()

2022-08-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. It looks like precommit CI caught a relevant issue Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131070/new/ https://reviews.llvm.org/D131070 ___ cfe-commits mailing list

[PATCH] D131012: No longer place const volatile global variables in a read only section

2022-08-03 Thread Andrii Nakryiko via Phabricator via cfe-commits
anakryiko added a comment. In D131012#3697000 , @aaron.ballman wrote: > In D131012#3696810 , @anakryiko > wrote: > >> In D131012#3696327 , >> @aaron.ballman wrote: >>

[PATCH] D129973: [clang] Pass FoundDecl to DeclRefExpr creator for operator overloads

2022-08-03 Thread joanahalili via Phabricator via cfe-commits
joanahalili added a comment. In D129973#3696189 , @joanahalili wrote: > Heads up: This commit causes clang crashes on our end. We are currently > working on a reproducer and will post it as soon as its ready. Here is the reduced code: template

[PATCH] D131012: No longer place const volatile global variables in a read only section

2022-08-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D131012#3696810 , @anakryiko wrote: > In D131012#3696327 , @aaron.ballman > wrote: > >> In D131012#3695110 , @anakryiko >> wrote: >>

[PATCH] D131039: [clang][dataflow] Add cache of `ControlFlowContext`s for function decls.

2022-08-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/include/clang/Analysis/FlowSensitive/ControlFlowContext.h:38 + + // DEPRECATED. Use overload above. static llvm::Expected build(const Decl *D, Stmt *S, I think LLVM can use the `[[deprecated]]` attribute.

[PATCH] D130974: [analyzer] Fix for the crash in #56873

2022-08-03 Thread Domján Dániel via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG10a7ee0bac21: [analyzer] Fix for the crash in #56873 (authored by isuckatcs). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE

[clang] 10a7ee0 - [analyzer] Fix for the crash in #56873

2022-08-03 Thread via cfe-commits
Author: isuckatcs Date: 2022-08-03T19:25:02+02:00 New Revision: 10a7ee0bac211810376f29a879a9f73ed2ab15fc URL: https://github.com/llvm/llvm-project/commit/10a7ee0bac211810376f29a879a9f73ed2ab15fc DIFF: https://github.com/llvm/llvm-project/commit/10a7ee0bac211810376f29a879a9f73ed2ab15fc.diff

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Last scroll-through looked fine to me, so don't worry about waiting for me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122768/new/ https://reviews.llvm.org/D122768 ___

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. Thanks @aaron.ballman! I'm gonna wait a bit before merging in case @erichkeane want to do another pass. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122768/new/ https://reviews.llvm.org/D122768

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 449696. cor3ntin marked 2 inline comments as done. cor3ntin added a comment. Add fixed issues to the release notes + address aaron comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122768/new/

[PATCH] D129097: [clang][dataflow] Handle null pointers of type std::nullptr_t

2022-08-03 Thread Eric Li via Phabricator via cfe-commits
li.zhe.hua marked an inline comment as done. li.zhe.hua added inline comments. Comment at: clang/include/clang/Analysis/FlowSensitive/DataflowAnalysisContext.h:96 /// /// `Type` must not be null. StorageLocation (QualType Type); sgatev wrote: > This

[PATCH] D124435: [X86] Always extend the integer parameters in callee

2022-08-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. That is an interesting idea. I like that it integrates this into `-fclang-abi-compat`. The way that `-mno-conservative-small-integer-abi` ends up meaning opposite things based on the abi-compat setting worries me a lot, though. Repository: rG LLVM Github

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 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. I mostly only have minor nits, but otherwise this LGTM! Comment at: clang/docs/ReleaseNotes.rst:104-105 +- Support capturing structured bindings in lambdas +

[PATCH] D122768: [Clang][C++20] Support capturing structured bindings in lambdas

2022-08-03 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 449690. cor3ntin added a comment. Missed a comment (s/ValueDecl/auto/ on the LHS of a `cast`) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122768/new/ https://reviews.llvm.org/D122768 Files:

[PATCH] D131004: [clang] Add FileEntryRef::getNameAsRequested()

2022-08-03 Thread Ben Langmuir via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6a79e2ff1989: [clang] Add FileEntryRef::getNameAsRequested() (authored by benlangmuir). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131004/new/

[clang] 6a79e2f - [clang] Add FileEntryRef::getNameAsRequested()

2022-08-03 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2022-08-03T09:41:08-07:00 New Revision: 6a79e2ff1989b48f4a8ebf3ac51092eb8ad29e37 URL: https://github.com/llvm/llvm-project/commit/6a79e2ff1989b48f4a8ebf3ac51092eb8ad29e37 DIFF: https://github.com/llvm/llvm-project/commit/6a79e2ff1989b48f4a8ebf3ac51092eb8ad29e37.diff

[PATCH] D130964: [X86][BF16] Enable __bf16 for x86 targets.

2022-08-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D130964#3695408 , @FreddyYe wrote: > In D130964#3694540 , @bkramer wrote: > >> In D130964#3694473 , @rjmccall >> wrote: >> >>> How are you

[PATCH] D131012: No longer place const volatile global variables in a read only section

2022-08-03 Thread Andrii Nakryiko via Phabricator via cfe-commits
anakryiko added a comment. In D131012#3696327 , @aaron.ballman wrote: > In D131012#3695110 , @anakryiko > wrote: > >> This will severly break BPF users, as we have a heavy reliance on `const >> volatile`

[PATCH] D130123: Extend ptr32 support to be applied on typedef

2022-08-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. In D130123#3696752 , @Ariel-Burton wrote: > What is your expectation for your template code fragment? MSVC does not > accept it. Yes, I checked, MSVC rejects it, so clang should have test expectations to confirm that. It seems

[PATCH] D130123: Extend ptr32 support to be applied on typedef

2022-08-03 Thread Ariel Burton via Phabricator via cfe-commits
Ariel-Burton added a comment. In D130123#3691011 , @rnk wrote: > That sounds reasonable to me, I confirmed that MSVC really only lets you > apply these attributes directly to pointer types and to typedefs. > > Can you add a test for the other most

[PATCH] D131024: Fix assert in the call to isOpenMPRebuildMemberExpr

2022-08-03 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa7bca18bc50c: Fix assert during the call to getCanonicalDecl. (authored by jyu2). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131024/new/

[clang] a7bca18 - Fix assert during the call to getCanonicalDecl.

2022-08-03 Thread Jennifer Yu via cfe-commits
Author: Jennifer Yu Date: 2022-08-03T09:14:28-07:00 New Revision: a7bca18bc50cd2483fded0c77706980b2721ce6a URL: https://github.com/llvm/llvm-project/commit/a7bca18bc50cd2483fded0c77706980b2721ce6a DIFF: https://github.com/llvm/llvm-project/commit/a7bca18bc50cd2483fded0c77706980b2721ce6a.diff

[PATCH] D129016: [PowerPC] implemented @llvm.ppc.kill.canary to corrupt stack guard

2022-08-03 Thread Paul Scoropan via Phabricator via cfe-commits
pscoro updated this revision to Diff 449683. pscoro added a comment. removed comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129016/new/ https://reviews.llvm.org/D129016 Files: clang/include/clang/Basic/BuiltinsPPC.def

[PATCH] D131076: [clang][modules] Don't depend on sharing FileManager during module build

2022-08-03 Thread Ben Langmuir via Phabricator via cfe-commits
benlangmuir created this revision. benlangmuir added a reviewer: bnbarham. Herald added a project: All. benlangmuir requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Sharing the FileManager between the importer and the module build should

[PATCH] D123967: Disable update_cc_test_checks.py tests in stand-alone builds

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added inline comments. Comment at: clang/test/utils/update_cc_test_checks/lit.local.cfg:19 +# for any of the clang source code. +config.unsupported = True else: h-vetinari wrote: > I couldn't tell from the diff where this is used (though

[PATCH] D123967: Disable update_cc_test_checks.py tests in stand-alone builds

2022-08-03 Thread Tom Stellard via Phabricator via cfe-commits
tstellar updated this revision to Diff 449681. tstellar marked an inline comment as done. tstellar added a comment. Fix option spelling. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123967/new/ https://reviews.llvm.org/D123967 Files:

[PATCH] D130894: [clang] Print more information about failed static assertions

2022-08-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D130894#3696590 , @xbolva00 wrote: > Use ‘5 ==6’ ? So add quotes .. +1 to the suggestion to use quotes for a bit of visual distinction between the diagnostic message and the code embedded within it.

[PATCH] D130889: [llvm] Introduce a pass plugin registry and loader

2022-08-03 Thread wael yehia via Phabricator via cfe-commits
w2yehia added a comment. Looks good. Thanks. Comment at: llvm/lib/Passes/PassPluginLoader.cpp:23 +void PassPluginLoader::operator=(const std::string ) { + sys::SmartScopedLock Lock(*PluginsLock); + auto PassPlugin = PassPlugin::Load(Filename); why do we need

[PATCH] D130933: Add docs for function attributes hot/cold

2022-08-03 Thread David Li via Phabricator via cfe-commits
davidxl accepted this revision. davidxl added a comment. This revision is now accepted and ready to land. LGTM from the content point of view. Please also address aaron's comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130933/new/

[PATCH] D130888: [Clang] Introduce -fexperimental-sanitize-metadata=

2022-08-03 Thread Marco Elver via Phabricator via cfe-commits
melver added inline comments. Comment at: clang/lib/Driver/SanitizerArgs.cpp:839 + // Parse -f(no-)?sanitize-metadata. + for (const auto *Arg : Args) { +if (Arg->getOption().matches( MaskRay wrote: > Use `Args.getLastArg(...)` This won't work if someone

  1   2   >