MCPcopy Create free account
hub / github.com/WasmEdge/WasmEdge / getCodes

Method getCodes

lib/llvm/jit.cpp:49–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47}
48
49std::vector<Symbol<void>> JITLibrary::getCodes(size_t Offset,
50 size_t Size) noexcept {
51 std::vector<Symbol<void>> Result;
52 Result.reserve(Size);
53 for (size_t I = 0; I < Size; ++I) {
54 const std::string Name = fmt::format("f{}"sv, I + Offset);
55 if (auto Symbol = J->lookup<void>(Name.c_str())) {
56 Result.push_back(createSymbol<void>(*Symbol));
57 } else {
58 spdlog::error("{}"sv, Symbol.error().message().string_view());
59 Result.emplace_back();
60 }
61 }
62
63 return Result;
64}
65
66Expect<std::shared_ptr<Executable>> JIT::load(Data D) noexcept {
67 OrcLLJIT J;

Callers 1

loadExecutableMethod · 0.45

Calls 4

c_strMethod · 0.80
errorFunction · 0.50
string_viewMethod · 0.45
messageMethod · 0.45

Tested by

no test coverage detected