003 File Manager
Current Path:
/usr/src/contrib/llvm-project/llvm/lib/ExecutionEngine/Orc
usr
/
src
/
contrib
/
llvm-project
/
llvm
/
lib
/
ExecutionEngine
/
Orc
/
📁
..
📄
CompileOnDemandLayer.cpp
(12.91 KB)
📄
CompileUtils.cpp
(2.8 KB)
📄
Core.cpp
(71.56 KB)
📄
DebugUtils.cpp
(10.4 KB)
📄
ExecutionUtils.cpp
(13.7 KB)
📄
IRCompileLayer.cpp
(1.55 KB)
📄
IRTransformLayer.cpp
(1.17 KB)
📄
IndirectionUtils.cpp
(12.36 KB)
📄
JITTargetMachineBuilder.cpp
(3.71 KB)
📄
LLJIT.cpp
(41.6 KB)
📄
Layer.cpp
(7.61 KB)
📄
LazyReexports.cpp
(7.9 KB)
📄
Legacy.cpp
(2.08 KB)
📄
MachOPlatform.cpp
(17.2 KB)
📄
Mangling.cpp
(5.03 KB)
📄
NullResolver.cpp
(1.12 KB)
📄
ObjectLinkingLayer.cpp
(20.23 KB)
📄
ObjectTransformLayer.cpp
(1.33 KB)
📄
OrcABISupport.cpp
(41.44 KB)
📄
OrcCBindings.cpp
(5.73 KB)
📄
OrcCBindingsStack.h
(18.01 KB)
📄
OrcMCJITReplacement.cpp
(4.68 KB)
📄
OrcMCJITReplacement.h
(17.73 KB)
📄
OrcV2CBindings.cpp
(7.81 KB)
📄
RTDyldObjectLinkingLayer.cpp
(11 KB)
📄
SpeculateAnalyses.cpp
(9.8 KB)
📄
Speculation.cpp
(5.82 KB)
📄
ThreadSafeModule.cpp
(2.04 KB)
Editing: ObjectTransformLayer.cpp
//===---------- ObjectTransformLayer.cpp - Object Transform Layer ---------===// // // 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: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// #include "llvm/ExecutionEngine/Orc/ObjectTransformLayer.h" #include "llvm/Support/MemoryBuffer.h" namespace llvm { namespace orc { ObjectTransformLayer::ObjectTransformLayer(ExecutionSession &ES, ObjectLayer &BaseLayer, TransformFunction Transform) : ObjectLayer(ES), BaseLayer(BaseLayer), Transform(std::move(Transform)) {} void ObjectTransformLayer::emit(MaterializationResponsibility R, std::unique_ptr<MemoryBuffer> O) { assert(O && "Module must not be null"); // If there is a transform set then apply it. if (Transform) { if (auto TransformedObj = Transform(std::move(O))) O = std::move(*TransformedObj); else { R.failMaterialization(); getExecutionSession().reportError(TransformedObj.takeError()); return; } } BaseLayer.emit(std::move(R), std::move(O)); } } // End namespace orc. } // End namespace llvm.
Upload File
Create Folder