[PATCH] D69817: Fix OrcError build with modules enabled.
Chris Bieneman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 5 17:44:01 PST 2019
beanz added a comment.
In D69817#1734876 <https://reviews.llvm.org/D69817#1734876>, @vsapsai wrote:
> I don't think that's the right fix as it moves a module map from representing a project structure towards having a random set of headers. But even after excluding 3 headers there are errors
ExecutionEngine isn't like the rest of LLVM's project structure. It should not be treated as a single module component. We can debate whether or not that is appropriate in LLVM conventions, but it is the way the code is structured. The module map is not representative of the actual structure of the code under the ExecutionEngine header directory.
>> llvm-project/llvm/include/llvm/Support/Error.h:331:10: error: no matching conversion for functional-style cast from 'typename __unique_if<JITSymbolNotFound>::__unique_single' (aka 'unique_ptr<llvm::orc::JITSymbolNotFound>') to 'llvm::Error'
>
> return Error(std::make_unique<ErrT>(std::forward<ArgTs>(Args)...));
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
There isn't enough context on this error for me to understand what is causing it, but the problem is in the module map.
> Have you seen these errors before? The second error implies a module map with excluded headers doesn't work.
The ExecutionEngine module map has a bunch of excludes already because of similar errors in the past. The ORC error and RPC related headers only rely on LLVMSupport, and can be used independently of the rest of ExecutionEngine. This is *very* important because it allows building remote JIT clients that don't depend on the LLVM IR, or Target libraries. The problem you're experiencing is the result of the module map not appropriately representing the orc error and RPC headers as separable parts from the ExecutionEngine module.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69817/new/
https://reviews.llvm.org/D69817
More information about the llvm-commits
mailing list