[PATCH] D151938: [clang][index] NFCI: Make `CXFile` a `FileEntryRef`

2023-09-13 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D151938#4645381 , @Jake-Egan wrote: > @jansvoboda11 Actually, we could give you access to an AIX machine to debug > this. Would that work for you? Hi, I'd be happy to try that! Repository: rG LLVM Github Monorepo CH

[PATCH] D151938: [clang][index] NFCI: Make `CXFile` a `FileEntryRef`

2023-09-10 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D151938#4626992 , @Jake-Egan wrote: > Sorry for the late response @jansvoboda11, when `lookupModuleFile` is called, > the file > `build/tools/clang/test/Index/Core/Output/index-with-module.m.tmp.mcp/A03A61VI43WA/ModA-21U

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

2023-08-28 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a subscriber: rsmith. jansvoboda11 added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:6343 "Invalid data, missing pragma diagnostic states"); - SourceLocation Loc = ReadSourceLocation(F, Record[Idx++]); - auto IDAnd

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-24 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. @phosek BTW can you confirm whether these started failing with this patch or with D158573 ? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158572/new/ https://reviews.llvm.org/D158572

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-24 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D158572#4615198 , @phosek wrote: > After this change, all libc++ `clang_modules_include.gen.py` tests started > failing on our Linux builders: > > ... > > You can see the full output at > https://luci-milo.appspot.com/

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-24 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. jansvoboda11 marked an inline comment as done. Closed by commit rG7d1565727dad: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file (authored by jansvobod

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-24 Thread Jan Svoboda 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 rGb9d78bdc730b: [clang][modules] Use relative offsets for input files (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D158469#4612012 , @benlangmuir wrote: >> I tried that approach, but found it way too easy to keep `ModuleDeps` >> around, which keep scanning instances alive, and use tons of memory. > > It seems like the problem (too ea

[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Hmm, maybe we could avoid holding on to the whole `CompilerInstance`. For generating the command-line, we only need the `CompilerInvocation`. For collecting file dependencies, we could hold on to the `MemoryBuffer` (and maybe offset to the input files block), and d

[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D158469#4611923 , @benlangmuir wrote: > I find this a bit hard to understand as far as object lifetime is concerned: > you're storing the `ScanInstance` in `TranslationUnitDeps`, but that's a > layer above the actual co

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked 5 inline comments as done. jansvoboda11 added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:1169 + writeSignature(Sig, Out); + std::copy_n(Out.begin(), Out.size(), Buffer.begin() + Offset); +}; benlangmuir wr

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 552897. jansvoboda11 added a comment. Early return. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158573/new/ https://reviews.llvm.org/D158573 Files: clang/include/clang/Basic/Module.h clang/include/c

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 552896. jansvoboda11 added a comment. Use `Stream::BackpatchWord()` instead of manipulating `Buffer` directly. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158573/new/ https://reviews.llvm.org/D158573 Fi

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 552894. jansvoboda11 added a comment. Initialize absolute offsets in `ASTReader`/`ModuleFile`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158572/new/ https://reviews.llvm.org/D158572 Files: clang/inc

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Serialization/ModuleFile.h:249 + /// Absolute offset of the start of the input-files block. + uint64_t InputFilesOffsetBase; + benlangmuir wrote: > Doesn't `InputFilesCursor` already know where

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-23 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Good suggestions all around, thanks! Comment at: clang/lib/Serialization/ASTWriter.cpp:1169 + writeSignature(Sig, Out); + std::copy_n(Out.begin(), Out.size(), Buffer.begin() + Offset); +}; I don't feel great about rem

[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

2023-08-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 552566. jansvoboda11 added a comment. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158469/new/ https://reviews.llvm.org/D158469 Files: clang/include/clang/Tooling/DependencyScanning/DependencyS

[PATCH] D158573: [clang][modules] Move `UNHASHED_CONTROL_BLOCK` up in the AST file

2023-08-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added subscribers: ributzka, arphaman. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When loading (transitive

[PATCH] D158572: [clang][modules] Use relative offsets for input files

2023-08-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch replaces absolute offs

[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

2023-08-21 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Although generating command lines

[PATCH] D158136: [clang][modules] Avoid storing command-line macro definitions into implicitly built PCM files

2023-08-17 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6a115578324f: [clang][modules] Avoid storing command-line macro definitions into implicitly… (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/D158136?vs=550964&id=551197#toc

[PATCH] D158136: [clang][modules] Avoid storing command-line macro definitions into implicitly built PCM files

2023-08-16 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 550964. jansvoboda11 added a comment. Format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158136/new/ https://reviews.llvm.org/D158136 Files: clang/include/clang/Serialization/ASTReader.h clang/inclu

[PATCH] D158136: [clang][modules] Avoid storing command-line macro definitions into implicitly built PCM files

2023-08-16 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: benlangmuir, rsmith, Bigcheese. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. With implicit m

[PATCH] D157559: [clang][modules] Respect "-fmodule-name=" when serializing included files into a PCH

2023-08-10 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbbdb0c7e4496: [clang][modules] Respect "-fmodule-name=" when serializing included files into… (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://review

[PATCH] D156749: [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.

2023-08-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:1330 AddPath(WritingModule->PresumedModuleMapFile.empty() -? Map.getModuleMapFileForUniquing(WritingModule)->getName() +? Map.getModuleMapFileForUniquing(Wri

[PATCH] D157559: [clang][modules] Respect "-fmodule-name=" when serializing included files into a PCH

2023-08-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Clang writes the set of textually

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-09 Thread Jan Svoboda 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 rGdcd3a0c9f13b: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile`… (authored by jansvoboda11). Changed prior to commit:

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Landing with one more use of `Filename` converted to `FilenameAsRequested` (in call to `Listener.visitInputFile()`). The only remaining usages of `Filename` is now in the scanner (intentional) and in `ASTReader` when deciding whether an `InputFileInfo` has already

[PATCH] D157054: [clang] NFC: Use compile-time option spelling when generating command line

2023-08-09 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGacf57858c1ac: [clang] NFC: Use compile-time option spelling when generating command line (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-09 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG501f92d34382: [llvm] Construct option's prefixed name at compile-time (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/

[PATCH] D157054: [clang] NFC: Use compile-time option spelling when generating command line

2023-08-08 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 548425. jansvoboda11 added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157054/new/ https://reviews.llvm.org/D157054 Files: clang/lib/Frontend/CompilerInvocation.cpp Index: clang/li

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-08 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 548423. jansvoboda11 added a comment. Rebase, remove unnecessary changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/ https://reviews.llvm.org/D157029 Files: clang-tools-extra/clangd/Compil

[PATCH] D156749: [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.

2023-08-07 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. In D156749#4562469 , @vsapsai wrote: > In D156749#4561803 , @jansvoboda11 > wrote: > >> My suggestion is to use the actual real on-disk path. Not

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Serialization/ASTReader.cpp:2411 bool Transient = FI.Transient; - StringRef Filename = FI.Filename; + StringRef Filename = FI.FilenameAsRequested; uint64_t StoredContentHash = FI.ContentHash; jansv

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Serialization/ModuleFile.h:72 + bool TopLevel; + bool ModuleMap; }; benlangmuir wrote: > Is there something using this new split? It seems like every user is using > `&&` for these You're rig

[PATCH] D156234: [clang][deps] add support for dependency scanning with cc1 command line

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6b4de7b1c71b: [clang][deps] add support for dependency scanning with cc1 command line (authored by cpsughrue, committed by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547339. jansvoboda11 added a comment. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/ https://reviews.llvm.org/D157029 Files: clang-tools-extra/clangd/CompileCommands.cpp clang/lib/D

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3f092f37b736: [llvm] Extract common `OptTable` bits into macros (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157028/new/ https:

[PATCH] D156749: [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D156749#4552590 , @vsapsai wrote: > In D156749#4551596 , @jansvoboda11 > wrote: > >> Alternatively, we could keep VFS overlays out of the context hash but create >> `` from the o

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D157029#4561519 , @jansvoboda11 wrote: > In D157029#4561490 , @MaskRay wrote: > >> This increases the size of `Info` (static data size and static >> relocations). In return, som

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547316. jansvoboda11 added a comment. Remove `OptTable::Info::Name`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/ https://reviews.llvm.org/D157029 Files: clang-tools-extra/clangd/CompileCom

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D157029#4561490 , @MaskRay wrote: > This increases the size of `Info` (static data size and static relocations). > In return, some dynamic relocations are saved. Is this a net win? If that's a concern, I can remove `Inf

[PATCH] D157029: [llvm] Construct option's prefixed name at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: llvm/include/llvm/Option/Option.h:103 + StringLiteral getSpelling() const { +assert(Info && "Must have a valid info!"); benlangmuir wrote: > This could use a doc comment to differentiate it from other string

[PATCH] D157029: [llvm] Construct option spelling at compile-time

2023-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547298. jansvoboda11 added a comment. Improve `Option::getPrefixedName()` instead of introducing new `Option::getSpelling()`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/ https://reviews.llvm

[PATCH] D156948: [clang][modules] Add -Wsystem-headers-in-module=

2023-08-04 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 Comment at: clang/include/clang/Basic/DiagnosticOptions.h:128 + /// whether -Wsystem-headers is enabled on a per-module basis. + std::vector SystemHeaderWa

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547097. jansvoboda11 added a comment. Remove leftover `std::string` constructor Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157066/new/ https://reviews.llvm.org/D157066 Files: clang/include/clang/Seri

[PATCH] D157066: [clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The current `ASTReader::visitInpu

[PATCH] D157046: [clang] Abstract away string allocation in command line generation

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:4323 +GenerateArg(Consumer, OPT_darwin_target_variant_sdk_version_EQ, +Opts.DarwinTargetVariantSDKVersion.getAsString()); } benlangmuir wrote: > Maybe n

[PATCH] D157052: [clang][deps] NFC: Speed up canonical context hash computation

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG8fd56ea11256: [clang][deps] NFC: Speed up canonical context hash computation (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157052

[PATCH] D157048: [clang] NFC: Avoid double allocation when generating command line

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGacd1ab869fca: [clang] NFC: Avoid double allocation when generating command line (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157

[PATCH] D157046: [clang] Abstract away string allocation in command line generation

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG83452650490e: [clang] Abstract away string allocation in command line generation (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D15

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: lld/ELF/Driver.h:28 OPT_INVALID = 0, -#define OPTION(_1, _2, ID, _4, _5, _6, _7, _8, _9, _10, _11, _12) OPT_##ID, +#define OPTION(...) LLVM_MAKE_OPT_ID(__VA_ARGS__), #include "Options.inc" MaskRay wrote: > lld/w

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547090. jansvoboda11 added a comment. Herald added subscribers: pmatos, asb, aheejin, sbc100. Herald added a project: lld-macho. Herald added a reviewer: lld-macho. Convert missed LLD parts. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTI

[PATCH] D157055: [clang][deps] Avoid unnecessary work for seen dependencies

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Modular dependencies the client h

[PATCH] D157054: [clang] NFC: Use compile-time option spelling when generating command line

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When generating command lines, us

[PATCH] D157050: [clang] NFC: Avoid double allocation when generating command line

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 abandoned this revision. jansvoboda11 added a comment. In D157050#4559138 , @benlangmuir wrote: > Dupe of https://reviews.llvm.org/D157048 ? Yes, weird. Closing this one. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D157052: [clang][deps] NFC: Speed up canonical context hash computation

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch makes use of the infra

[PATCH] D157050: [clang] NFC: Avoid double allocation when generating command line

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch makes use of the infra

[PATCH] D157048: [clang] NFC: Avoid double allocation when generating command line

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch makes use of the infra

[PATCH] D157046: [clang] Abstract string allocation in command line generation

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: cfe-commits, jplehr, sstefan1. Herald added

[PATCH] D157029: [llvm] Construct option spelling at compile-time

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547019. jansvoboda11 added a comment. Rebase on top of D157028 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157029/new/ https://reviews.llvm.org/D157029 Files: clang

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547018. jansvoboda11 added a comment. Herald added a reviewer: alexander-shaposhnikov. Consolidate all usages by extra `_WITH_ID_PREFIX` macros Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157028/new/ htt

[PATCH] D157035: [clang][cli] Accept option spelling as `Twine`

2023-08-03 Thread Jan Svoboda 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 rG243bc7504965: [clang][cli] Accept option spelling as `Twine` (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST A

[PATCH] D157035: [clang][cli] Accept option spelling as `Twine`

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. That's a good point. Updated. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157035/new/ https://reviews.llvm.org/D157035 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[PATCH] D157035: [clang][cli] Accept option spelling as `Twine`

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 547014. jansvoboda11 added a comment. Assert that spelling is null-terminated Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157035/new/ https://reviews.llvm.org/D157035 Files: clang/lib/Frontend/Compile

[PATCH] D157035: [clang][cli] Accept option spelling as `Twine`

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This will make it possible to acc

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Here's an example of a patch that changes the `OPTION` macro: D157029 . I wonder if we could have counterparts to `LLVM_MAKE_OPT_ID` and `LLVM_CONSTRUCT_OPT_INFO` that allow overriding the default `OPT_` prefix. That would make D15

[PATCH] D157029: [llvm] Construct option spelling at compile-time

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: MaskRay. Herald added subscribers: ormris, ributzka, kadircet, arphaman, hiraditya. Herald added a reviewer: alexander-shaposhnikov. Herald added a reviewer: jhenderson. Herald added a project: All. jansvoboda11 requested review of

[PATCH] D157028: [llvm] Extract common `OptTable` bits into macros

2023-08-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: MaskRay. Herald added subscribers: jhenderson, ormris, ributzka, steven_wu, hiraditya, arichardson, emaste. Herald added a reviewer: JDevlieghere. Herald added a reviewer: jhenderson. Herald added a project: All. jansvoboda11 reque

[PATCH] D156234: [clang][deps] add support for dependency scanning with cc1 command line

2023-08-02 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 after Windows CI gets fixed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156234/new/ https://reviews.llvm.org/D156234 _

[PATCH] D156749: [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.

2023-08-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a subscriber: benlangmuir. jansvoboda11 added a comment. CC @benlangmuir, since we've talked about this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156749/new/ https://reviews.llvm.org/D156749

[PATCH] D156749: [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.

2023-08-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. > And it is build system's responsibility to provide `-ivfsoverlay` options > that don't cause observable differences. I wasn't aware of that. Do we document this anywhere? It surprises me that we'd impose such restriction on the build system. This seems fairly eas

[PATCH] D156234: [clang][deps] add support for dependency scanning with cc1 command line

2023-08-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp:482 + bool Success = false; + if (FinalCommandLine[1] == "-cc1") { +Success = createAndRunToolInvocation(FinalCommandLine, Action, *FileMgr, c

[PATCH] D156563: [clang][deps] Remove `ModuleDeps::ImportedByMainFile`

2023-07-28 Thread Jan Svoboda 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 rGc75b331fc231: [clang][deps] Remove `ModuleDeps::ImportedByMainFile` (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/

[PATCH] D156492: [clang][deps] Make the C++ API more type-safe

2023-07-28 Thread Jan Svoboda 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 rG8a077cfe23e3: [clang][deps] Make the C++ API more type-safe (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/D156492?

[PATCH] D156563: [clang][deps] Remove `ModuleDeps::ImportedByMainFile`

2023-07-28 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This information is already expos

[PATCH] D156492: [clang][deps] Make the C++ API more type-safe

2023-07-27 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: artemcm. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Scanner's C++ API accepts a set of mo

[PATCH] D156234: [clang][deps] provide support for cc1 command line scanning

2023-07-25 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. This looks pretty good! I'm not sure unit testing is the best choice here, since we're not checking for low-level properties or hard-to-observe behavior. In general LIT tests are easier to write/maintain/understand and don't require recompiling, so I'd suggest to

[PATCH] D156000: Track the RequestingModule in the HeaderSearch LookupFile cache.

2023-07-21 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, thanks for the quick turnaround! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156000/new/ https://reviews.llvm.org/D156000 _

[PATCH] D132779: Enforce module decl-use restrictions and private header restrictions in textual headers

2023-07-21 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Hi @rsmith, this commit makes it possible for `HeaderInfo::LookupFile()` to be called with different `RequestingModule` within single `CompilerInstance`. This is problematic, since some modules may see headers other modules can't (due to `[no_undeclared_includes]`)

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

2023-07-17 Thread Jan Svoboda 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 rG227f71995804: [clang][modules][deps] Avoid checks for relocated modules (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES S

[PATCH] D150479: [clang][modules] Skip submodule & framework re-definitions in module maps

2023-07-17 Thread Jan Svoboda 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 rGdba2b5c9314e: [clang][modules] Skip submodule & framework re-definitions in module maps (authored by jansvoboda11). Repository: rG LLVM Github Mon

[PATCH] D150478: [clang][modules][deps] Parse "FW_Private" module map even after loading "FW" PCM

2023-07-17 Thread Jan Svoboda 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 rGbe014563f2f4: [clang][modules][deps] Parse "FW_Private" module map even after loading "FW" PCM (authored by jansvoboda11). Repository: rG LLVM Gi

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

2023-07-17 Thread Jan Svoboda 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 rGabcf7ce45794: [clang][modules] Serialize `Module::DefinitionLoc` (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/D15

[PATCH] D114173: [clang][modules] Apply local submodule visibility to includes

2023-07-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 541218. jansvoboda11 edited the summary of this revision. jansvoboda11 added a comment. Rebase on top of D155503 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114173/new/

[PATCH] D155503: [clang][modules] Track included files per submodule

2023-07-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Note to self: lost the change that bumps PCM format version during a rebase. Make sure to increment the major version before committing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155503/new/ https://reviews.llvm.o

[PATCH] D155503: [clang][modules] Track included files per submodule

2023-07-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: benlangmuir, vsapsai, Bigcheese. Herald added subscribers: ributzka, mgrang. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When bu

[PATCH] D155131: [clang][modules] Deserialize included files lazily

2023-07-13 Thread Jan Svoboda 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 rG6504d87fc0c8: [clang][modules] Deserialize included files lazily (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LA

[PATCH] D155131: [clang][modules] Deserialize included files lazily

2023-07-13 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 540174. jansvoboda11 added a comment. Herald added a subscriber: mgrang. Remove dead code, make sure `getFileInfo()` is called in `alreadyIncluded()`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155131/ne

[PATCH] D155131: [clang][modules] Deserialize included files lazily

2023-07-13 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D155131#4495489 , @benlangmuir wrote: > Now that it's not eagerly deserialized, should > `Preprocessor::alreadyIncluded` call `HeaderInfo.getFileInfo(File)` to ensure > the information is up to date? It should, but `Pr

[PATCH] D155131: [clang][modules] Deserialize included files lazily

2023-07-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: benlangmuir, vsapsai, Bigcheese. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. In D114095

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

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. jansvoboda11 marked an inline comment as done. Closed by commit rG06611e361363: [clang] Implement `PointerLikeTraits` for `{File,Directory}EntryRef` (authored by jansvo

[PATCH] D150479: [clang][modules] Skip submodule & framework re-definitions in module maps

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 539156. jansvoboda11 added a comment. Skip re-definitions of frameworks too, add new tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150479/new/ https://reviews.llvm.org/D150479 Files: clang/lib/Lex

[PATCH] D150478: [clang][modules][deps] Parse "FW_Private" module map even after loading "FW" PCM

2023-07-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 539127. jansvoboda11 added a comment. Expose new preprocessor option as a `-cc1` flag, move test from `ClangScanDeps` to `Modules` directory. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150478/new/ http

[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] 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] 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] 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] D154905: [clang] Implement `PointerLikeTraits` for `{File,Directory}EntryRef`

2023-07-10 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Note that this enables usage of `{File,Directory}EntryRef` in other containers using `PointerLikeTraits` such as `SmallPtrSet`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154905/new/ https://reviews.llvm.org/D15490

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

2023-07-10 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: benlangmuir. Herald added a subscriber: ributzka. Herald added a project: All. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch implements `llvm::Poin

  1   2   3   4   5   6   7   8   9   10   >