LLVM 24.0.0git
JITLinkDylib.h
Go to the documentation of this file.
1//===-- JITLinkDylib.h - JITLink Dylib type ---------------------*- C++ -*-===//
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//
9// Defines the JITLinkDylib API.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_EXECUTIONENGINE_JITLINK_JITLINKDYLIB_H
14#define LLVM_EXECUTIONENGINE_JITLINK_JITLINKDYLIB_H
15
18
19#include <string>
20
21namespace llvm::jitlink {
22
24
25/// Represents a JITDylib as seen by JITLink.
27public:
28 JITLinkDylib(std::string Name) : Name(std::move(Name)) {}
29
31
32 /// Get the name for this JITLinkDylib.
33 const std::string &getName() const { return Name; }
34
35 /// Register a JITLinkMemoryManager to be notified when this JITLinkDylib
36 /// is destroyed.
38 ToNotifyOnDestruction.push_back(&MemMgr);
39 }
40
41private:
42 std::string Name;
43 SmallVector<JITLinkMemoryManager *> ToNotifyOnDestruction;
44};
45
46} // namespace llvm::jitlink
47
48#endif // LLVM_EXECUTIONENGINE_JITLINK_JITLINKDYLIB_H
#define LLVM_ABI
Definition Compiler.h:215
This file defines the SmallVector class.
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Definition STLExtras.h:1917
Implement std::hash so that hash_code can be used in STL containers.
Definition BitVector.h:878