Author: Ben Langmuir
Date: 2023-01-27T11:37:35-08:00
New Revision: 73dba2f649a8e8c01e9c8b8df3bdc89cdf0fd7ee
URL:
https://github.com/llvm/llvm-project/commit/73dba2f649a8e8c01e9c8b8df3bdc89cdf0fd7ee
DIFF:
https://github.com/llvm/llvm-project/commit/73dba2f649a8e8c01e9c8b8df3bdc89cdf0fd7ee.diff
Author: Ben Langmuir
Date: 2023-02-03T15:10:19-08:00
New Revision: 223e99fb698dd63b5bb9266e11c2582261e05ad9
URL:
https://github.com/llvm/llvm-project/commit/223e99fb698dd63b5bb9266e11c2582261e05ad9
DIFF:
https://github.com/llvm/llvm-project/commit/223e99fb698dd63b5bb9266e11c2582261e05ad9.diff
Author: Ben Langmuir
Date: 2022-06-15T13:29:47-07:00
New Revision: 509223da61145c3eb982751cba9ab6ddf0f48e9d
URL:
https://github.com/llvm/llvm-project/commit/509223da61145c3eb982751cba9ab6ddf0f48e9d
DIFF:
https://github.com/llvm/llvm-project/commit/509223da61145c3eb982751cba9ab6ddf0f48e9d.diff
Author: Ben Langmuir
Date: 2022-06-17T07:55:27-07:00
New Revision: 4a3a9a5fa0b2fd0e70672c35010fe2f00740f098
URL:
https://github.com/llvm/llvm-project/commit/4a3a9a5fa0b2fd0e70672c35010fe2f00740f098
DIFF:
https://github.com/llvm/llvm-project/commit/4a3a9a5fa0b2fd0e70672c35010fe2f00740f098.diff
Author: Ben Langmuir
Date: 2022-06-08T11:09:17-07:00
New Revision: 7a72dca74a27f1f6198cfabb064dc43274ee005d
URL:
https://github.com/llvm/llvm-project/commit/7a72dca74a27f1f6198cfabb064dc43274ee005d
DIFF:
https://github.com/llvm/llvm-project/commit/7a72dca74a27f1f6198cfabb064dc43274ee005d.diff
Author: Ben Langmuir
Date: 2022-06-08T11:09:17-07:00
New Revision: 835fcf2aa5127bf99a1e6397c72153f00a0497b2
URL:
https://github.com/llvm/llvm-project/commit/835fcf2aa5127bf99a1e6397c72153f00a0497b2
DIFF:
https://github.com/llvm/llvm-project/commit/835fcf2aa5127bf99a1e6397c72153f00a0497b2.diff
@@ -330,3 +359,24 @@ DependencyScanningWorkerFilesystem::openFileForRead(const
Twine &Path) {
return Result.getError();
return DepScanFile::create(Result.get());
}
+
+std::error_code DependencyScanningWorkerFilesystem::setCurrentWorkingDirectory(
+const Twine &Path)
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/66122
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -524,13 +524,7 @@ enum ASTRecordTypes {
/// of source-location information.
SOURCE_LOCATION_OFFSETS = 14,
- /// Record code for the set of source location entries
- /// that need to be preloaded by the AST reader.
- ///
- /// This set contains the source location en
https://github.com/benlangmuir commented:
> in my experience, it's not actually referenced in most modules
Can you clarify what you looked at here? I assume you checked non-scanner
modules as well?
https://github.com/llvm/llvm-project/pull/66962
___
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/66962
___
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 other than my nit about the comment
https://github.com/llvm/llvm-project/pull/66962
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/67383
___
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/67383
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -612,24 +612,21 @@ FileManager::getNoncachedStatValue(StringRef Path,
}
void FileManager::GetUniqueIDMapping(
-SmallVectorImpl &UIDToFiles) const {
+SmallVectorImpl &UIDToFiles) const {
UIDToFiles.clear();
UIDToFiles.resize(NextFileUID);
- // Map file entri
benlangmuir wrote:
> I changed SourceManager::isInTheSameTranslationUnit() to check for that case
> explicitly instead of relying on the fact/bug that built-ins buffers happened
> to be assigned an untranslated include SourceLocation.
What is the translated location you get here? It's hard fo
@@ -864,74 +864,7 @@ FileID
SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const {
/// This function knows that the SourceLocation is in a loaded buffer, not a
/// local one.
FileID SourceManager::getFileIDLoaded(SourceLocation::UIntTy SLocOffset) const
{
-
@@ -50,6 +50,7 @@ int y = a2;
// CHECK: In module 'a':
// CHECK-NEXT: a.h:1:45: error:
+int z = b;
// MISSING-B: could not find file '{{.*}}b.h'
// MISSING-B-NOT: please delete the module cache
benlangmuir wrote:
Can we use this approach to test the current
@@ -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 locati
@@ -2261,43 +2261,68 @@ template struct
enumerator_result {
mutable range_reference_tuple Storage;
};
-/// Infinite stream of increasing 0-based `size_t` indices.
-struct index_stream {
- struct iterator : iterator_facade_base {
-iterator &operator++() {
- assert
@@ -1444,6 +1444,77 @@ llvm::Error ASTReader::ReadSourceManagerBlock(ModuleFile
&F) {
}
}
+std::optional
+ASTReader::readSLocOffset(ModuleFile *F, unsigned Index) {
benlangmuir wrote:
Does every path that returns `std::nullopt` report an error? If so I wou
benlangmuir wrote:
Thanks for laying it out. I also find this easier to understand in your latest
changes because the comments in `isBeforeInTranslationUnit` lay out the
intended ordering without relying on `isInTheSameTranslationUnit` returning
`false` for builtin buffers, which is the part t
https://github.com/benlangmuir commented:
I'm skeptical that treating `FileEntryRef` as `FileEntry *` for the purposes of
equality and hashing is a good idea. To me, the obvious interpretation of
`FileEntryRef ==` is that the path must be equal, and having it based on the
dev/inode is surpris
benlangmuir wrote:
For what it's worth, until recently there was almost no **use** of the implicit
unique file semantics for FileEntryRef even though the DenseMapInfo had been
available for a long time. But okay, I see there are more uses now so this is
not the right place to push back on tha
@@ -179,6 +179,46 @@ TEST(FileEntryTest, DenseMapInfo) {
EXPECT_TRUE(Set.find(R1)->isSameRef(R1));
EXPECT_TRUE(Set.find(R2)->isSameRef(R2));
}
+
+ // Insert R1Also second and confirm R1 "wins" when looked up as FileEntry.
benlangmuir wrote:
This com
https://github.com/benlangmuir approved this pull request.
Comment in the test needs a fix, but otherwise LGTM
https://github.com/llvm/llvm-project/pull/67742
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailma
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/67742
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir commented:
I thin
https://github.com/llvm/llvm-project/pull/67838
___
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/67838
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -843,7 +843,7 @@ void ClangMoveTool::moveDeclsToNewFiles() {
// Move all contents from OldFile to NewFile.
void ClangMoveTool::moveAll(SourceManager &SM, StringRef OldFile,
StringRef NewFile) {
- auto FE = SM.getFileManager().getFile(makeAbsolute
@@ -228,7 +228,7 @@ int main(int argc, const char **argv) {
Tool.applyAllReplacements(Rewrite);
for (const auto &File : Files) {
- auto Entry = FileMgr.getFile(File);
+ auto Entry = FileMgr.getOptionalFileRef(File);
benlangmuir wrote:
Anothe
@@ -152,7 +152,7 @@ int main(int argc, const char **argv) {
for (auto I = ChangedFiles.begin(), E = ChangedFiles.end(); I != E; ++I)
{
OS << " {\n";
OS << "\"FilePath\": \"" << *I << "\",\n";
-const auto Entry = FileMgr.getFile(*I);
+
@@ -527,17 +527,6 @@ FileID SourceManager::getNextFileID(FileID FID) const {
/// Create a new FileID that represents the specified file
/// being \#included from the specified IncludePosition.
-///
-/// This translates NULL into standard input.
-FileID SourceManager::createFil
@@ -348,6 +348,10 @@ bool ModuleMap::resolveAsBuiltinHeader(
if (!File)
return false;
+ // Ensure the path to the module directory is absolute, otherwise
+ // builtin headers will fail to resolve when using relative resource
+ // directory paths without a -I.
+ llvm:
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/67838
___
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/68156
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2082,6 +2082,11 @@ std::pair
SourceManager::isInTheSameTranslationUnit(
if (LOffs.first == ROffs.first)
return std::make_pair(true, LOffs.second < ROffs.second);
+ // Built-ins are not considered part of any TU.
benlangmuir wrote:
Does this have t
@@ -701,6 +701,10 @@ class SourceManager : public RefCountedBase
{
/// use (-ID - 2).
SmallVector LoadedSLocEntryTable;
+ /// For each allocation in LoadedSLocEntryTable, we keep the new size. This
+ /// can be used to determine whether two FileIDs come from the same AS
@@ -458,11 +458,14 @@ SourceManager::AllocateLoadedSLocEntries(unsigned
NumSLocEntries,
CurrentLoadedOffset - TotalSize < NextLocalOffset) {
return std::make_pair(0, 0);
}
- LoadedSLocEntryTable.resize(LoadedSLocEntryTable.size() + NumSLocEntries);
- SLocEntryLoa
@@ -458,11 +458,14 @@ SourceManager::AllocateLoadedSLocEntries(unsigned
NumSLocEntries,
CurrentLoadedOffset - TotalSize < NextLocalOffset) {
return std::make_pair(0, 0);
}
- LoadedSLocEntryTable.resize(LoadedSLocEntryTable.size() + NumSLocEntries);
- SLocEntryLoa
https://github.com/benlangmuir edited
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
@@ -284,7 +284,6 @@ TEST_F(FileManagerTest,
getFileRefReturnsCorrectNameForDifferentStatPath) {
ASSERT_FALSE(!F1Alias);
ASSERT_FALSE(!F1Alias2);
EXPECT_EQ("dir/f1.cpp", F1->getName());
- EXPECT_EQ("dir/f1.cpp", F1->getFileEntry().getName());
benlangmuir
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
@@ -2082,6 +2082,11 @@ std::pair
SourceManager::isInTheSameTranslationUnit(
if (LOffs.first == ROffs.first)
return std::make_pair(true, LOffs.second < ROffs.second);
+ // Built-ins are not considered part of any TU.
benlangmuir wrote:
Yes, this commen
https://github.com/benlangmuir approved this pull request.
This seems reasonable to me, but I would like @jansvoboda11 to also look at it.
https://github.com/llvm/llvm-project/pull/68023
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://l
@@ -701,6 +701,10 @@ class SourceManager : public RefCountedBase
{
/// use (-ID - 2).
SmallVector LoadedSLocEntryTable;
+ /// For each allocation in LoadedSLocEntryTable, we keep the new size. This
+ /// can be used to determine whether two FileIDs come from the same AS
@@ -458,14 +458,12 @@ SourceManager::AllocateLoadedSLocEntries(unsigned
NumSLocEntries,
CurrentLoadedOffset - TotalSize < NextLocalOffset) {
return std::make_pair(0, 0);
}
-
- unsigned NewTableSize = LoadedSLocEntryTable.size() + NumSLocEntries;
- LoadedSLocEntry
@@ -1986,13 +1984,15 @@ bool SourceManager::isInTheSameTranslationUnitImpl(
if (isLoadedFileID(LOffs.first) != isLoadedFileID(ROffs.first))
return false;
- // If both are loaded from different AST files.
if (isLoadedFileID(LOffs.first) && isLoadedFileID(ROffs.first))
https://github.com/benlangmuir edited
https://github.com/llvm/llvm-project/pull/66962
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -458,14 +458,12 @@ SourceManager::AllocateLoadedSLocEntries(unsigned
NumSLocEntries,
CurrentLoadedOffset - TotalSize < NextLocalOffset) {
return std::make_pair(0, 0);
}
-
- unsigned NewTableSize = LoadedSLocEntryTable.size() + NumSLocEntries;
- LoadedSLocEntry
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" f
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" f
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
@@ -1444,6 +1444,74 @@ llvm::Error ASTReader::ReadSourceManagerBlock(ModuleFile
&F) {
}
}
+llvm::Expected
+ASTReader::readSLocOffset(ModuleFile *F, unsigned Index) {
+ BitstreamCursor &Cursor = F->SLocEntryCursor;
+ SavedStreamPosition SavedPosition(Cursor);
+ if (llvm::
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
htt
@@ -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 locati
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
https://lists.llvm.org/cgi-bin/mailman/listinfo/
@@ -1384,10 +1384,10 @@ void ASTWriter::WriteControlBlock(Preprocessor &PP,
ASTContext &Context,
SmallVector ModMaps(AdditionalModMaps->begin(),
AdditionalModMaps->end());
llvm::sort(ModMaps, [](FileEntryRef A, FileEntryRe
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
Author: Ben Langmuir
Date: 2023-08-09T10:40:53-07:00
New Revision: dc5cbba3196db61d57b7d84118732a6c96d8ee64
URL:
https://github.com/llvm/llvm-project/commit/dc5cbba3196db61d57b7d84118732a6c96d8ee64
DIFF:
https://github.com/llvm/llvm-project/commit/dc5cbba3196db61d57b7d84118732a6c96d8ee64.diff
@@ -66,16 +66,18 @@ bool ParseDiagnosticArgs(DiagnosticOptions &Opts,
llvm::opt::ArgList &Args,
DiagnosticsEngine *Diags = nullptr,
bool DefaultDiagColor = true);
+namespace CompilerInvocationDetail {
/// The base class of Co
@@ -94,47 +96,37 @@ class CompilerInvocationRefBase {
/// Options controlling the static analyzer.
AnalyzerOptionsRef AnalyzerOpts;
- CompilerInvocationRefBase();
- CompilerInvocationRefBase(const CompilerInvocationRefBase &X);
- CompilerInvocationRefBase(CompilerInvoca
@@ -154,46 +146,158 @@ class CompilerInvocationValueBase {
PreprocessorOutputOptions PreprocessorOutputOpts;
public:
- MigratorOptions &getMigratorOpts() { return MigratorOpts; }
+ // clang-format off
const MigratorOptions &getMigratorOpts() const { return MigratorOpts;
@@ -123,49 +123,101 @@ static Expected>
parseToleranceOption(StringRef Arg) {
}
//===--===//
-// Initialization.
+// Storage details.
//===--
@@ -94,47 +96,37 @@ class CompilerInvocationRefBase {
/// Options controlling the static analyzer.
AnalyzerOptionsRef AnalyzerOpts;
- CompilerInvocationRefBase();
- CompilerInvocationRefBase(const CompilerInvocationRefBase &X);
- CompilerInvocationRefBase(CompilerInvoca
@@ -123,49 +123,101 @@ static Expected>
parseToleranceOption(StringRef Arg) {
}
//===--===//
-// Initialization.
+// Storage details.
//===--
@@ -94,47 +96,37 @@ class CompilerInvocationRefBase {
/// Options controlling the static analyzer.
AnalyzerOptionsRef AnalyzerOpts;
- CompilerInvocationRefBase();
- CompilerInvocationRefBase(const CompilerInvocationRefBase &X);
- CompilerInvocationRefBase(CompilerInvoca
@@ -123,49 +123,101 @@ static Expected>
parseToleranceOption(StringRef Arg) {
}
//===--===//
-// Initialization.
+// Storage details.
//===--
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/65647
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir commented:
This basically LGTM, but could we add some unit tests for the new type?
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mai
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/benlangmuir unresolved
https://github.com/llvm/llvm-project/pull/65412
___
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/65412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -279,13 +281,16 @@ class ModuleDepCollector final : public
DependencyCollector {
/// Add module files (pcm) to the invocation, if needed.
void addModuleFiles(CompilerInvocation &CI,
ArrayRef ClangModuleDeps) const;
+ void addModuleFiles(CowCompile
@@ -117,14 +112,37 @@
ModuleDepCollector::makeInvocationForModuleBuildWithoutOutputs(
CI.getFrontendOpts().ARCMTAction = FrontendOptions::ARCMT_None;
CI.getFrontendOpts().ObjCMTAction = FrontendOptions::ObjCMT_None;
CI.getFrontendOpts().MTMigrateDir.clear();
- CI.getLan
@@ -117,14 +112,37 @@
ModuleDepCollector::makeInvocationForModuleBuildWithoutOutputs(
CI.getFrontendOpts().ARCMTAction = FrontendOptions::ARCMT_None;
CI.getFrontendOpts().ObjCMTAction = FrontendOptions::ObjCMT_None;
CI.getFrontendOpts().MTMigrateDir.clear();
- CI.getLan
https://github.com/benlangmuir resolved
https://github.com/llvm/llvm-project/pull/65677
___
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/65677
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -532,7 +539,8 @@ ModuleDepCollectorPP::handleTopLevelModule(const Module *M)
{
// Finish the compiler invocation. Requires dependencies and the context
hash.
MDC.addOutputPaths(CI, MD);
- MD.BuildArguments = CI.getCC1CommandLine();
+ MD.BuildInvocationOrArguments =
@@ -136,9 +138,15 @@ struct ModuleDeps {
/// determined that the differences are benign for this compilation.
std::vector ClangModuleDeps;
- /// Compiler invocation that can be used to build this module. Does not
- /// include argv[0].
- std::vector BuildArguments;
+ /
https://github.com/benlangmuir approved this pull request.
https://github.com/llvm/llvm-project/pull/65691
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -215,44 +225,57 @@
DependencyScanningWorkerFilesystem::findEntryByFilenameWithWriteThrough(
}
llvm::ErrorOr
-DependencyScanningWorkerFilesystem::computeAndStoreResult(StringRef Filename) {
- llvm::ErrorOr Stat = getUnderlyingFS().status(Filename);
+DependencyScanningWorke
@@ -215,44 +225,57 @@
DependencyScanningWorkerFilesystem::findEntryByFilenameWithWriteThrough(
}
llvm::ErrorOr
-DependencyScanningWorkerFilesystem::computeAndStoreResult(StringRef Filename) {
- llvm::ErrorOr Stat = getUnderlyingFS().status(Filename);
+DependencyScanningWorke
@@ -482,16 +482,9 @@ ModuleDepCollectorPP::handleTopLevelModule(const Module
*M) {
MD.ID.ModuleName = M->getFullModuleName();
MD.IsSystem = M->IsSystem;
- ModuleMap &ModMapInfo =
- MDC.ScanInstance.getPreprocessor().getHeaderSearchInfo().getModuleMap();
-
- Optiona
@@ -1307,6 +1307,9 @@ void ModuleMap::setInferredModuleAllowedBy(Module *M,
std::error_code
ModuleMap::canonicalizeModuleMapPath(SmallVectorImpl &Path) {
+ FileManager &FM = SourceMgr.getFileManager();
+ FM.makeAbsolutePath(Path);
benlangmuir wrote:
I'm not
@@ -1307,6 +1307,9 @@ void ModuleMap::setInferredModuleAllowedBy(Module *M,
std::error_code
ModuleMap::canonicalizeModuleMapPath(SmallVectorImpl &Path) {
+ FileManager &FM = SourceMgr.getFileManager();
+ FM.makeAbsolutePath(Path);
benlangmuir wrote:
This wo
@@ -1307,6 +1307,9 @@ void ModuleMap::setInferredModuleAllowedBy(Module *M,
std::error_code
ModuleMap::canonicalizeModuleMapPath(SmallVectorImpl &Path) {
+ FileManager &FM = SourceMgr.getFileManager();
+ FM.makeAbsolutePath(Path);
benlangmuir wrote:
Is the
@@ -330,3 +353,20 @@ DependencyScanningWorkerFilesystem::openFileForRead(const
Twine &Path) {
return Result.getError();
return DepScanFile::create(Result.get());
}
+
+std::error_code DependencyScanningWorkerFilesystem::setCurrentWorkingDirectory(
+const Twine &Path)
@@ -1307,6 +1307,9 @@ void ModuleMap::setInferredModuleAllowedBy(Module *M,
std::error_code
ModuleMap::canonicalizeModuleMapPath(SmallVectorImpl &Path) {
+ FileManager &FM = SourceMgr.getFileManager();
+ FM.makeAbsolutePath(Path);
benlangmuir wrote:
> The c
@@ -330,3 +353,20 @@ DependencyScanningWorkerFilesystem::openFileForRead(const
Twine &Path) {
return Result.getError();
return DepScanFile::create(Result.get());
}
+
+std::error_code DependencyScanningWorkerFilesystem::setCurrentWorkingDirectory(
+const Twine &Path)
@@ -330,3 +353,20 @@ DependencyScanningWorkerFilesystem::openFileForRead(const
Twine &Path) {
return Result.getError();
return DepScanFile::create(Result.get());
}
+
+std::error_code DependencyScanningWorkerFilesystem::setCurrentWorkingDirectory(
+const Twine &Path)
@@ -1307,6 +1307,9 @@ void ModuleMap::setInferredModuleAllowedBy(Module *M,
std::error_code
ModuleMap::canonicalizeModuleMapPath(SmallVectorImpl &Path) {
+ FileManager &FM = SourceMgr.getFileManager();
+ FM.makeAbsolutePath(Path);
benlangmuir wrote:
> This
101 - 200 of 451 matches
Mail list logo