LLVM 20.0.0git
ObjectLinkingLayer.cpp
Go to the documentation of this file.
1//===------- ObjectLinkingLayer.cpp - JITLink backed ORC ObjectLayer ------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
12
13#define DEBUG_TYPE "orc"
14
15namespace llvm::orc {
16
18
20
21void ObjectLinkingLayer::emit(std::unique_ptr<MaterializationResponsibility> R,
22 std::unique_ptr<MemoryBuffer> O) {
23 assert(O && "Object must not be null");
24 MemoryBufferRef ObjBuffer = O->getMemBufferRef();
25
27 ObjBuffer, getExecutionSession().getSymbolStringPool())) {
28 emit(std::move(R), std::move(*G), std::move(O));
29 } else {
30 R->getExecutionSession().reportError(G.takeError());
31 R->failMaterialization();
32 return;
33 }
34}
35
36} // namespace llvm::orc
#define G(x, y, z)
Definition: MD5.cpp:56
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
ExecutionSession & getExecutionSession()
void emit(std::unique_ptr< MaterializationResponsibility > R, std::unique_ptr< MemoryBuffer > O) override
Emit an object file.