class PassPlugin

Declaration

class PassPlugin { /* full declaration omitted */ };

Description

A loaded pass plugin. An instance of this class wraps a loaded pass plugin and gives access to its interface defined by the \c PassPluginLibraryInfo it exposes.

Declared at: llvm/include/llvm/Passes/PassPlugin.h:60

Member Variables

private std::string Filename
private sys::DynamicLibrary Library
private llvm::PassPluginLibraryInfo Info

Method Overview

Methods

static Expected<llvm::PassPlugin> Load(
    const std::string& Filename)

Description

Attempts to load a pass plugin from a given file.

Declared at: llvm/include/llvm/Passes/PassPlugin.h:67

Parameters

const std::string& Filename

Returns

Returns an error if either the library cannot be found or loaded, there is no public entry point, or the plugin implements the wrong API version.

PassPlugin(const std::string& Filename,
           const sys::DynamicLibrary& Library)

Declared at: llvm/include/llvm/Passes/PassPlugin.h:87

Parameters

const std::string& Filename
const sys::DynamicLibrary& Library

uint32_t getAPIVersion() const

Description

Get the plugin API version

Declared at: llvm/include/llvm/Passes/PassPlugin.h:79

llvm::StringRef getFilename() const

Description

Get the filename of the loaded plugin.

Declared at: llvm/include/llvm/Passes/PassPlugin.h:70

llvm::StringRef getPluginName() const

Description

Get the plugin name

Declared at: llvm/include/llvm/Passes/PassPlugin.h:73

llvm::StringRef getPluginVersion() const

Description

Get the plugin version

Declared at: llvm/include/llvm/Passes/PassPlugin.h:76

void registerPassBuilderCallbacks(
    llvm::PassBuilder& PB) const

Description

Invoke the PassBuilder callback registration

Declared at: llvm/include/llvm/Passes/PassPlugin.h:82

Parameters

llvm::PassBuilder& PB