ChuanqiXu9 wrote:
Given we are going to branch clang19 in the end of the month, it is highly
possible that we can't land sufficient patches before that. Note that even if
we land this patch before that, the support of modules in clangd is expected to
very slow for real world applications. See
ChuanqiXu9 wrote:
> Hi, sorry if this is off topic -- How can I try this PR?
>
> I've done the following:
>
> 1. checked out the latest commit on the `clangmodules` branch
> ([16541c8](https://github.com/llvm/llvm-project/commit/16541c8bf44cf38497ce6fd7377ee966d61be5aa)),
> and built it from
chriselrod wrote:
Hi, sorry if this is off topic --
How can I try this PR?
I've done the following:
1. checked out the latest commit on the `clangmodules` branch (16541c8bf44c),
and built it from source.
2. Added `clangd` to my path, by sym-linking `$LLVMBUILDDIR/bin/clangd` to
kadircet wrote:
Hi @ChuanqiXu9, I was on vacation and just returned, i'll provide next round of
feedback quite soon.
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ChuanqiXu9 wrote:
@kadircet ping~
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,199 @@
+//===-- ProjectModules.h -*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,364 @@
+//===--- PrerequisiteModulesTests.cpp ---*- C++
+//-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+//
@@ -0,0 +1,364 @@
+//===--- PrerequisiteModulesTests.cpp ---*- C++
+//-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+//
@@ -213,10 +213,10 @@ ClangdServer::Options::operator TUScheduler::Options()
const {
ClangdServer::ClangdServer(const GlobalCompilationDatabase ,
const ThreadsafeFS , const Options ,
- Callbacks *Callbacks)
+
@@ -0,0 +1,26 @@
+//=== ScanningProjectModules.h ---*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -710,6 +710,7 @@ class ASTWorker {
TUScheduler::ASTCache
TUScheduler::HeaderIncluderCache
const bool RunSync;
+
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,81 @@
+//=== ModuleDependencyScanner.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -27,6 +27,9 @@
#include "Diagnostics.h"
#include "FS.h"
#include "Headers.h"
+
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ChuanqiXu9 wrote:
Oh, maybe I was misreading. It looks doable if we only want to avoid
DirectoryBasedGlobalCompilationDatabase. Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -112,6 +114,9 @@ class ClangdServer {
/// This throttler controls which preambles may be built at a given time.
clangd::PreambleThrottler *PreambleThrottler = nullptr;
+/// Enable experimental support for modules.
ChuanqiXu9 wrote:
I add
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -146,6 +146,8 @@ class Checker {
ClangdLSPServer::Options Opts;
// from buildCommand
tooling::CompileCommand Cmd;
+ std::unique_ptr BaseCDB;
+ std::unique_ptr CDB;
kadircet wrote:
can you also construct a `ModulesBuilder` here and populate `Inputs`
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
kadircet wrote:
again can you revert these changes?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/kadircet requested changes to this pull request.
thanks, mostly LG.
my biggest concern is around testing setup, PTAL.
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -0,0 +1,199 @@
+//===-- ProjectModules.h -*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,347 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
kadircet wrote:
can you rename this to `ScanningProjectModules.cpp` ?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -0,0 +1,26 @@
+//=== ScanningProjectModules.h ---*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
kadircet wrote:
again can you revert these changes?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
kadircet wrote:
again can you revert these changes?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -27,6 +27,9 @@
#include "Diagnostics.h"
#include "FS.h"
#include "Headers.h"
+
kadircet wrote:
can you drop the extra new lines?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
@@ -112,6 +114,9 @@ class ClangdServer {
/// This throttler controls which preambles may be built at a given time.
clangd::PreambleThrottler *PreambleThrottler = nullptr;
+/// Enable experimental support for modules.
kadircet wrote:
this isn't
kadircet wrote:
again can you revert these changes?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -710,6 +710,7 @@ class ASTWorker {
TUScheduler::ASTCache
TUScheduler::HeaderIncluderCache
const bool RunSync;
+
kadircet wrote:
can you get rid of these new line changes as well?
https://github.com/llvm/llvm-project/pull/66462
https://github.com/kadircet edited
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
kadircet wrote:
can you revert all of these changes?
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,364 @@
+//===--- PrerequisiteModulesTests.cpp ---*- C++
+//-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+//
ChuanqiXu9 wrote:
> Just a note, I am building on Windows with MSVC cl.exe and ninja and get this:
>
> ```
> C:\Program Files\Microsoft Visual
> Studio\2022\Community\VC\Tools\MSVC\14.39.33519\include\memory(3138): error
> C2027: use of undefined type 'clang::clangd::ProjectModules'
> ```
>
ChuanqiXu9 wrote:
> I think that needs to happen eventually as well
Agreed.
> similar to preambles supporting in-memory storage, and it's actually not that
> hard, GenerateModuleInterfaceAction already has an overrideable
> CreateOutputFile method.
I am
@@ -0,0 +1,87 @@
+//===- PrerequisiteModules.h -*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,115 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,115 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -208,15 +208,16 @@ ClangdServer::Options::operator TUScheduler::Options()
const {
Opts.UpdateDebounce = UpdateDebounce;
Opts.ContextProvider = ContextProvider;
Opts.PreambleThrottler = PreambleThrottler;
+ Opts.ExperimentalModulesSupport =
@@ -44,6 +44,8 @@ struct ParseOptions {
bool ImportInsertions = false;
};
+class ModulesBuilder;
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
@@ -192,8 +192,10 @@ TEST(PreamblePatchTest, PatchesPreambleIncludes) {
TU.AdditionalFiles["b.h"] = "";
TU.AdditionalFiles["c.h"] = "";
auto PI = TU.inputs(FS);
- auto BaselinePreamble = buildPreamble(
- TU.Filename, *buildCompilerInvocation(PI, Diags), PI, true,
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -149,9 +154,13 @@ struct PreambleBuildStats {
/// If \p PreambleCallback is set, it will be run on top of the AST while
/// building the preamble.
/// If Stats is not non-null, build statistics will be exported there.
+/// If \p RequiredModuleBuilder is not null, it will
@@ -0,0 +1,339 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -42,6 +42,8 @@
namespace clang {
namespace clangd {
+
+class ModulesBuilder;
ChuanqiXu9 wrote:
Done
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -222,6 +222,9 @@ class TUScheduler {
/// Cache (large) preamble data in RAM rather than temporary files on disk.
bool StorePreamblesInMemory = false;
+/// Enable experimental support for modules.
+bool ExperimentalModulesSupport = false;
@@ -740,6 +741,21 @@
DirectoryBasedGlobalCompilationDatabase::getProjectInfo(PathRef File) const {
return Res->PI;
}
+std::shared_ptr
+DirectoryBasedGlobalCompilationDatabase::getProjectModules(PathRef File) const
{
+ CDBLookupRequest Req;
+ Req.FileName = File;
+
@@ -0,0 +1,81 @@
+//=== ModuleDependencyScanner.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -192,8 +192,10 @@ TEST(PreamblePatchTest, PatchesPreambleIncludes) {
TU.AdditionalFiles["b.h"] = "";
TU.AdditionalFiles["c.h"] = "";
auto PI = TU.inputs(FS);
- auto BaselinePreamble = buildPreamble(
- TU.Filename, *buildCompilerInvocation(PI, Diags), PI, true,
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,115 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,370 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -25,6 +25,8 @@
namespace clang {
namespace clangd {
+class ProjectModules;
kadircet wrote:
as others have also pointed out, this forward declaration is working around a
cyclic dependency. can we restructure this a little by:
- moving definition of
@@ -0,0 +1,206 @@
+//===-- ProjectModules.h -*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
kadircet wrote:
again no need for any of these changes, we should just pass `Inputs` as-is to
`buildPreamble`.
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -44,6 +44,8 @@ struct ParseOptions {
bool ImportInsertions = false;
};
+class ModulesBuilder;
kadircet wrote:
again instead of forward decl, can you include the header?
https://github.com/llvm/llvm-project/pull/66462
@@ -0,0 +1,115 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -208,15 +208,16 @@ ClangdServer::Options::operator TUScheduler::Options()
const {
Opts.UpdateDebounce = UpdateDebounce;
Opts.ContextProvider = ContextProvider;
Opts.PreambleThrottler = PreambleThrottler;
+ Opts.ExperimentalModulesSupport =
https://github.com/kadircet requested changes to this pull request.
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -222,6 +222,9 @@ class TUScheduler {
/// Cache (large) preamble data in RAM rather than temporary files on disk.
bool StorePreamblesInMemory = false;
+/// Enable experimental support for modules.
+bool ExperimentalModulesSupport = false;
@@ -149,9 +154,13 @@ struct PreambleBuildStats {
/// If \p PreambleCallback is set, it will be run on top of the AST while
/// building the preamble.
/// If Stats is not non-null, build statistics will be exported there.
+/// If \p RequiredModuleBuilder is not null, it will
@@ -42,6 +42,8 @@
namespace clang {
namespace clangd {
+
+class ModulesBuilder;
kadircet wrote:
we prefer to avoid forward declarations in clangd, can you rather depend on the
header directly?
https://github.com/llvm/llvm-project/pull/66462
https://github.com/kadircet edited
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jpc0 wrote:
Just a note, I am building on Windows with MSVC cl.exe and ninja and get this:
```
C:\Program Files\Microsoft Visual
Studio\2022\Community\VC\Tools\MSVC\14.39.33519\include\memory(3138): error
C2027: use of undefined type 'clang::clangd::ProjectModules'
```
While building
ChuanqiXu9 wrote:
Oh, I don't know why I didn't get this in files page so I missed this.
But since we can't get rid of writing/reading the modules actually in
`ModulesBuilder` (Or it is pretty hard). Then it looks not so worthy to
introduce the layer.
@@ -0,0 +1,339 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,62 @@
+//===-- ProjectModules.h -*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,339 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,71 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,71 @@
+//===- ModulesBuilder.h --*-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,339 @@
+//===- ModulesBuilder.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
https://github.com/ChuanqiXu9 commented:
Thanks for reviewing. It makes the code looks better indeed.
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -0,0 +1,81 @@
+//=== ModuleDependencyScanner.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,81 @@
+//=== ModuleDependencyScanner.cpp *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -740,6 +741,21 @@
DirectoryBasedGlobalCompilationDatabase::getProjectInfo(PathRef File) const {
return Res->PI;
}
+std::shared_ptr
+DirectoryBasedGlobalCompilationDatabase::getProjectModules(PathRef File) const
{
+ CDBLookupRequest Req;
+ Req.FileName = File;
+
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
@@ -0,0 +1,106 @@
+//===-- ModuleDependencyScanner.h *-
C++-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier:
https://github.com/ChuanqiXu9 edited
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
1 - 100 of 248 matches
Mail list logo