Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion clang/lib/CodeGen/BackendUtil.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ using namespace clang;
using namespace llvm;

#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"

namespace llvm {
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Frontend/FrontendActions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ constexpr llvm::StringLiteral timingIdBackend =

// Declare plugin extension function declarations.
#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"

/// Save the given \c mlirModule to a temporary .mlir file, in a location
Expand Down
4 changes: 2 additions & 2 deletions llvm/docs/WritingAnLLVMNewPMPass.rst
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ See the definition of ``add_llvm_pass_plugin`` for more CMake details.
The pass must provide at least one of two entry points for the new pass manager,
one for static registration and one for dynamically loaded plugins:

- ``llvm::PassPluginLibraryInfo get##Name##PluginInfo();``
- ``LLVM_ABI llvm::PassPluginLibraryInfo get##Name##PluginInfo();``
- ``extern "C" ::llvm::PassPluginLibraryInfo llvmGetPassPluginInfo() LLVM_ATTRIBUTE_WEAK;``

Pass plugins are compiled and linked dynamically by default. Setting
Expand All @@ -268,7 +268,7 @@ To make ``PassBuilder`` aware of statically linked pass plugins:
.. code-block:: c++

// Declare plugin extension function declarations.
#define HANDLE_EXTENSION(Ext) llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#define HANDLE_EXTENSION(Ext) LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"

...
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Extensions/Extensions.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "llvm/Passes/PassPlugin.h"
#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"


Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/LTO/LTOBackend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ Error Config::addSaveTemps(std::string OutputFileName, bool UseInputModulePath,
}

#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"
#undef HANDLE_EXTENSION

Expand Down
2 changes: 1 addition & 1 deletion llvm/tools/bugpoint/bugpoint.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ class AddToDriver : public legacy::FunctionPassManager {
}

#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"

int main(int argc, char **argv) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/tools/opt/NewPMDriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ static void registerEPCallbacks(PassBuilder &PB) {
}

#define HANDLE_EXTENSION(Ext) \
llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo get##Ext##PluginInfo();
#include "llvm/Support/Extension.def"
#undef HANDLE_EXTENSION

Expand Down
4 changes: 3 additions & 1 deletion polly/include/polly/RegisterPasses.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
#ifndef POLLY_REGISTER_PASSES_H
#define POLLY_REGISTER_PASSES_H

#include "llvm/Support/Compiler.h"

namespace llvm {
class PassRegistry;
class PassBuilder;
Expand All @@ -27,6 +29,6 @@ void initializePollyPasses(llvm::PassRegistry &Registry);
void registerPollyPasses(llvm::PassBuilder &PB);
} // namespace polly

llvm::PassPluginLibraryInfo getPollyPluginInfo();
LLVM_ABI llvm::PassPluginLibraryInfo getPollyPluginInfo();

#endif