https://github.com/benlangmuir approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/91645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/90925
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
LGTM if we rename the checkHeaderSearchOptions function.
https://github.com/llvm/llvm-project/pull/90925
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -833,32 +833,33 @@ bool SimpleASTReaderListener::ReadPreprocessorOptions(
/// against the header search options in an existing preprocessor.
///
/// \param Diags If non-null, produce diagnostics for any mismatches incurred.
-static bool checkHeaderSearchOptions(const
@@ -839,17 +839,15 @@ static bool checkHeaderSearchOptions(const
HeaderSearchOptions ,
DiagnosticsEngine *Diags,
const LangOptions ,
const PreprocessorOptions ) {
-
@@ -839,17 +839,15 @@ static bool checkHeaderSearchOptions(const
HeaderSearchOptions ,
DiagnosticsEngine *Diags,
const LangOptions ,
const PreprocessorOptions ) {
-
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/89992
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/90319
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,34 @@
+// UNSUPPORTED: system-windows
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+// RUN: cd %t
+//
+// RUN: cp a1.h a.h
+// RUN: %clang -fmodules -fmodules-validate-input-files-content -Xclang
-fno-pch-timestamp -fimplicit-modules -fmodule-map-file=module.modulemap
@@ -0,0 +1,34 @@
+// UNSUPPORTED: system-windows
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+// RUN: cd %t
+//
+// RUN: cp a1.h a.h
+// RUN: %clang -fmodules -fmodules-validate-input-files-content -Xclang
-fno-pch-timestamp -fimplicit-modules -fmodule-map-file=module.modulemap
@@ -249,9 +245,27 @@ GetAffectingModuleMaps(const Preprocessor , Module
*RootModule) {
for (const auto : HS.findResolvedModulesForHeader(*File))
if (const Module *M = KH.getModule())
-CollectIncludingMapsFromAncestors(M);
+
@@ -249,9 +245,27 @@ GetAffectingModuleMaps(const Preprocessor , Module
*RootModule) {
for (const auto : HS.findResolvedModulesForHeader(*File))
if (const Module *M = KH.getModule())
-CollectIncludingMapsFromAncestors(M);
+
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/88764
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1,23 +1,10 @@
// RUN: rm -rf %t
// RUN: split-file %s %t
-//--- missing_tu.json.in
-[{
- "directory": "DIR",
- "command": "clang -fsyntax-only DIR/missing_tu.c",
- "file": "DIR/missing_tu.c"
-}]
-//--- missing_header.json.in
-[{
- "directory": "DIR",
- "command":
@@ -1,23 +1,10 @@
// RUN: rm -rf %t
// RUN: split-file %s %t
-//--- missing_tu.json.in
-[{
- "directory": "DIR",
- "command": "clang -fsyntax-only DIR/missing_tu.c",
- "file": "DIR/missing_tu.c"
-}]
-//--- missing_header.json.in
-[{
- "directory": "DIR",
- "command":
@@ -864,8 +873,24 @@ int clang_scan_deps_main(int argc, char **argv, const
llvm::ToolContext &) {
});
SharedStream Errs(llvm::errs());
- // Print out the dependency results to STDOUT by default.
- SharedStream DependencyOS(llvm::outs());
+
+ std::optional FileOS;
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/88767
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -864,8 +873,24 @@ int clang_scan_deps_main(int argc, char **argv, const
llvm::ToolContext &) {
});
SharedStream Errs(llvm::errs());
- // Print out the dependency results to STDOUT by default.
- SharedStream DependencyOS(llvm::outs());
+
+ std::optional FileOS;
https://github.com/benlangmuir approved this pull request.
LGTM with a couple minor comments
https://github.com/llvm/llvm-project/pull/88767
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://github.com/benlangmuir approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/68645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
LGTM (with the `Not to be committed, just here as a demonstration` test
removed, of course).
https://github.com/llvm/llvm-project/pull/87848
___
cfe-commits mailing list
@@ -194,6 +201,17 @@ class DependencyScanningFilesystemSharedCache {
const CachedFileSystemEntry &
getOrInsertEntryForFilename(StringRef Filename,
const CachedFileSystemEntry );
+
+/// Returns real path associated with the filename
@@ -230,6 +251,26 @@ class DependencyScanningFilesystemLocalCache {
assert(InsertedEntry == && "entry already present");
return *InsertedEntry;
}
+
+ /// Returns real path associated with the filename or nullptr if none is
+ /// found.
+ const CachedRealPath
@@ -159,7 +159,37 @@ DependencyScanningFilesystemSharedCache::CacheShard::
getOrInsertEntryForFilename(StringRef Filename,
const CachedFileSystemEntry ) {
std::lock_guard LockGuard(CacheLock);
- return *EntriesByFilename.insert({Filename,
@@ -130,11 +130,11 @@ DependencyScanningFilesystemSharedCache::CacheShard::
getOrEmplaceEntryForFilename(StringRef Filename,
llvm::ErrorOr Stat) {
std::lock_guard LockGuard(CacheLock);
- auto Insertion =
@@ -226,9 +247,28 @@ class DependencyScanningFilesystemLocalCache {
insertEntryForFilename(StringRef Filename,
const CachedFileSystemEntry ) {
assert(llvm::sys::path::is_absolute_gnu(Filename));
-const auto *InsertedEntry =
@@ -409,7 +409,7 @@ class SymbolCollector::HeaderFileURICache {
// Framework headers are spelled as , not
// "path/FrameworkName.framework/Headers/Foo.h".
auto = PP->getHeaderSearchInfo();
-if (const auto *HFI = HS.getExistingFileInfo(*FE, /*WantExternal*/
@@ -409,7 +409,7 @@ class SymbolCollector::HeaderFileURICache {
// Framework headers are spelled as , not
// "path/FrameworkName.framework/Headers/Foo.h".
auto = PP->getHeaderSearchInfo();
-if (const auto *HFI = HS.getExistingFileInfo(*FE, /*WantExternal*/
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/87849
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/87099
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/86358
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -34,12 +34,17 @@ class InitOnlyAction : public FrontendAction {
/// Preprocessor-based frontend action that also loads PCH files.
class ReadPCHAndPreprocessAction : public FrontendAction {
+ llvm::function_ref OnCI;
benlangmuir wrote:
My concern is that
@@ -736,6 +736,19 @@ class Preprocessor {
State ConditionalStackState = Off;
} PreambleConditionalStack;
+ /// Function for getting the dependency preprocessor directives of a file.
+ ///
+ /// These are directives derived from a special form of lexing where the
+
@@ -34,12 +34,17 @@ class InitOnlyAction : public FrontendAction {
/// Preprocessor-based frontend action that also loads PCH files.
class ReadPCHAndPreprocessAction : public FrontendAction {
+ llvm::function_ref OnCI;
benlangmuir wrote:
What does `OnCI`
https://github.com/benlangmuir approved this pull request.
Thanks for explaining; LGTM
https://github.com/llvm/llvm-project/pull/86216
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -71,6 +71,7 @@
// CHECK-NEXT: "context-hash": "{{.*}}",
// CHECK-NEXT: "file-deps": [
// CHECK-NEXT: "[[PREFIX]]/first/module.modulemap",
+// CHECK-NEXT: "[[PREFIX]]/second/module.modulemap",
benlangmuir wrote:
Why did this
@@ -1337,9 +1337,24 @@ static bool compileModule(CompilerInstance
,
// Get or create the module map that we'll use to build this module.
ModuleMap
= ImportingInstance.getPreprocessor().getHeaderSearchInfo().getModuleMap();
+ SourceManager =
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/86347
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/84127
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -301,10 +301,9 @@ bool Module::directlyUses(const Module *Requested) {
if (Requested->isSubModuleOf(Use))
return true;
- // Anyone is allowed to use our builtin stdarg.h and stddef.h and their
- // accompanying modules.
- if (Requested->getTopLevelModuleName()
@@ -301,10 +301,9 @@ bool Module::directlyUses(const Module *Requested) {
if (Requested->isSubModuleOf(Use))
return true;
- // Anyone is allowed to use our builtin stdarg.h and stddef.h and their
- // accompanying modules.
- if (Requested->getTopLevelModuleName()
benlangmuir wrote:
>> I'm not excited by the complexity we are moving toward with the builtin
>> headers. But I don't have any alternatives.
> When -fbuiltin-headers-in-system-modules goes away, things become simpler
> than they were since modules were introduced.
Even for the case with
@@ -301,10 +301,9 @@ bool Module::directlyUses(const Module *Requested) {
if (Requested->isSubModuleOf(Use))
return true;
- // Anyone is allowed to use our builtin stdarg.h and stddef.h and their
- // accompanying modules.
- if (Requested->getTopLevelModuleName()
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/84285
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir closed
https://github.com/llvm/llvm-project/pull/84525
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir updated
https://github.com/llvm/llvm-project/pull/84525
>From 24e2454b90c2aaabb999e84240d5b2263ff01719 Mon Sep 17 00:00:00 2001
From: Ben Langmuir
Date: Fri, 8 Mar 2024 09:53:42 -0800
Subject: [PATCH] [clang][deps] Fix dependency scanning with -working-directory
benlangmuir wrote:
I don't think there's a difference we can test for here -- the VFS WD shouldn't
be modified after the driver sets it and before the FM is used here, so it
would be identical to `-working-directory` during the critical window. But I
agree recreating the FileManager is
benlangmuir wrote:
> I can see a situation where we ask FileManager about the same relative path
> before and after setting the parsed FileSystemOptions. The second call would
> blindly return the cached result, effectively ignoring -working-directory for
> that file.
The driver calls
https://github.com/benlangmuir created
https://github.com/llvm/llvm-project/pull/84525
Stop overriding -working-directory to CWD during argument parsing, which should
no longer necessary after we set the VFS working directory, and set FSOpts
correctly after parsing arguments so that
@@ -175,8 +192,19 @@ static void sanitizeDiagOpts(DiagnosticOptions ) {
DiagOpts.ShowCarets = false;
// Don't write out diagnostic file.
DiagOpts.DiagnosticSerializationFile.clear();
- // Don't emit warnings as errors (and all other warnings too).
-
@@ -175,8 +192,19 @@ static void sanitizeDiagOpts(DiagnosticOptions ) {
DiagOpts.ShowCarets = false;
// Don't write out diagnostic file.
DiagOpts.DiagnosticSerializationFile.clear();
- // Don't emit warnings as errors (and all other warnings too).
-
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/81061
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -127,8 +127,12 @@ class PPCallbacks {
/// \param RelativePath The path relative to SearchPath, at which the include
/// file was found. This is equal to FileName except for framework includes.
///
- /// \param Imported The module, whenever an inclusion directive was
https://github.com/benlangmuir deleted
https://github.com/llvm/llvm-project/pull/81061
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -127,8 +127,12 @@ class PPCallbacks {
/// \param RelativePath The path relative to SearchPath, at which the include
/// file was found. This is equal to FileName except for framework includes.
///
- /// \param Imported The module, whenever an inclusion directive was
https://github.com/benlangmuir commented:
It would be good to update your commit message to talk about the benefits of
this change: the callback now provides more information about the included
header and models the associated module accurately regardless of whether it is
translated to an
@@ -127,8 +127,12 @@ class PPCallbacks {
/// \param RelativePath The path relative to SearchPath, at which the include
/// file was found. This is equal to FileName except for framework includes.
///
- /// \param Imported The module, whenever an inclusion directive was
@@ -2265,7 +2265,6 @@ Preprocessor::ImportAction
Preprocessor::HandleHeaderIncludeOrImport(
UsableHeaderUnit = true;
else if (!IsImportDecl) {
// This is a Header Unit that we do not include-translate
- SuggestedModule = ModuleMap::KnownHeader();
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/81061
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/74910
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/74899
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
Nice simplification
https://github.com/llvm/llvm-project/pull/74900
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/74892
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -441,22 +434,19 @@ void
ModuleManager::visit(llvm::function_ref Visitor,
bool ModuleManager::lookupModuleFile(StringRef FileName, off_t ExpectedSize,
time_t ExpectedModTime,
OptionalFileEntryRef ) {
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/74892
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/68157
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -157,6 +157,25 @@
#define LLVM_DEPRECATED(MSG, FIX) [[deprecated(MSG)]]
#endif
+// clang-format off
+#if defined(__clang__) || defined(__GNUC__)
+#define LLVM_IGNORE_DEPRECATIONS_OF_DECLARATIONS_BEGIN
\
benlangmuir wrote:
I'm not
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/73719
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -498,11 +518,18 @@ class NamedNodeOrError {
} // namespace detail
/// An in-memory file system.
-class InMemoryFileSystem : public FileSystem {
+class InMemoryFileSystem : public RTTIExtends {
std::unique_ptr Root;
std::string WorkingDirectory;
bool
https://github.com/benlangmuir commented:
It's odd to me that tracking is enabled by default. I would have expected
tracking be off by default and enabled explicitly for scanning. Similarly, in
the modulemap case it could save-and-restore rather than enable the tracking if
it was previously
@@ -4997,6 +4997,19 @@ ASTReader::ASTReadResult
ASTReader::readUnhashedControlBlockImpl(
F->SearchPathUsage[I] = true;
break;
}
+case VFS_USAGE: {
+ if (!F)
+break;
+ unsigned Count = Record[0];
+ const char *Byte =
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/73734
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
benlangmuir wrote:
You could try using `clang -cc1 -E -x c-module-map` which calls
`Module::print`. To trigger this code path you can follow the pattern in
`darwin_specific_modulemap_hacks.m`, ie create a module like
```
$ touch Tcl/x1.h
$ touch Tcl/x2.h
$ cat Tcl/module.modulemap
module Tcl
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/71612
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/70874
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/71697
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/71588
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/71450
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/70714
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/69975
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/69551
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -666,13 +666,19 @@ static StringRef
makeAbsoluteAndPreferred(CompilerInstance , StringRef Path,
}
void ModuleDepCollector::addFileDep(StringRef Path) {
- llvm::SmallString<256> Storage;
- Path = makeAbsoluteAndPreferred(ScanInstance, Path, Storage);
+ // Within P1689
benlangmuir wrote:
Thanks for the ping, I had missed your question
> How do you think about the idea to add a flag to the MDC about whether or not
> calling makeAbsoluteAndPreferred?
SGTM; this seems like a good compromise since we can't easily extract this into
the consumer.
@@ -168,6 +170,12 @@ class DependencyScanningFilesystemSharedCache {
/// The backing storage for cached contents.
llvm::SpecificBumpPtrAllocator ContentsStorage;
+/// Map from filenames to cached real paths.
+llvm::StringMap RealPathsByFilename;
@@ -230,6 +251,26 @@ class DependencyScanningFilesystemLocalCache {
assert(InsertedEntry == && "entry already present");
return *InsertedEntry;
}
+
+ /// Returns real path associated with the filename or nullptr if none is
+ /// found.
+ const CachedRealPath
https://github.com/benlangmuir approved this pull request.
> Yeah. I did try to fix up all calls to LookupFile to perform module map
> lookup, but a bunch of tests started failing (mostly standard C++ modules
> tests IIRC), so there's probably more nuance required there.
Okay, I do think this
benlangmuir wrote:
Thanks for your patience, I should have looked at this sooner. The change to
our downstream test looks expected; the `` buffer changed
```diff
-#import "/^tc/lib/clang/18/include/stdbool.h"
+#import "stdbool.h"
```
But the actual resolution of which header is used is
https://github.com/benlangmuir commented:
Can you clarify how this bug occurs in terms of what information about the
header is stored that causes us to get the wrong module? It seems bad that
passing `nullptr` to `LookupFile` could cause incorrect behaviour and makes me
wonder if we need to
@@ -2944,6 +2944,10 @@ def fno_modules_validate_textual_header_includes :
MarshallingInfoNegativeFlag>,
HelpText<"Do not enforce -fmodules-decluse and private header restrictions
for textual headers. "
"This flag will be removed in a future Clang release.">;
@@ -1212,9 +1212,12 @@ void ASTWriter::writeUnhashedControlBlock(Preprocessor
,
Record.clear();
}
+ const auto = PP.getHeaderSearchInfo().getHeaderSearchOpts();
+
// Diagnostic options.
const auto = Context.getDiagnostics();
const DiagnosticOptions =
@@ -2944,6 +2944,10 @@ def fno_modules_validate_textual_header_includes :
MarshallingInfoNegativeFlag>,
HelpText<"Do not enforce -fmodules-decluse and private header restrictions
for textual headers. "
"This flag will be removed in a future Clang release.">;
https://github.com/benlangmuir commented:
Is the issue with MDC's FileDeps that we are calling `makeAbsoluteAndPreferred`
on the paths? Maybe we could instead move that call into
`FullDependencyConsumer`. Or are there other issues?
The fact we need to add additional
https://github.com/benlangmuir approved this pull request.
Thanks
https://github.com/llvm/llvm-project/pull/68957
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1384,10 +1384,10 @@ void ASTWriter::WriteControlBlock(Preprocessor ,
ASTContext ,
SmallVector ModMaps(AdditionalModMaps->begin(),
AdditionalModMaps->end());
llvm::sort(ModMaps, [](FileEntryRef A, FileEntryRef B) {
-
https://github.com/benlangmuir approved this pull request.
Latest change to shrink memory use LGTM.
https://github.com/llvm/llvm-project/pull/66966
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -288,10 +288,12 @@ class ModuleFile {
/// for the entry is SLocEntryOffsetsBase + SLocEntryOffsets[i].
uint64_t SLocEntryOffsetsBase = 0;
- /// Offsets for all of the source location entries in the
- /// AST file.
+ /// Stream bit offsets for all of the source
https://github.com/benlangmuir approved this pull request.
LGTM; you might need a `std::move` in `readSLocOffset` to appease an older
compiler.
https://github.com/llvm/llvm-project/pull/66966
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -1444,6 +1444,74 @@ llvm::Error ASTReader::ReadSourceManagerBlock(ModuleFile
) {
}
}
+llvm::Expected
+ASTReader::readSLocOffset(ModuleFile *F, unsigned Index) {
+ BitstreamCursor = F->SLocEntryCursor;
+ SavedStreamPosition SavedPosition(Cursor);
+ if (llvm::Error
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/66966
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir approved this pull request.
Thanks for iterating! I find the current implementation much clearer.
The only thing I might quibble about is the "child" vs. "parent" terminology
you changed: I think it's fairly ambiguous either way, because the node is the
"child"
1 - 100 of 323 matches
Mail list logo