LLVM
12.0.0git
|
Lower @llvm.global_dtors. More...
#include "WebAssembly.h"
#include "llvm/ADT/MapVector.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Transforms/Utils/ModuleUtils.h"
Go to the source code of this file.
Macros | |
#define | DEBUG_TYPE "wasm-lower-global-dtors" |
Functions | |
INITIALIZE_PASS (LowerGlobalDtors, DEBUG_TYPE, "Lower @llvm.global_dtors for WebAssembly", false, false) ModulePass *llvm | |
Lower @llvm.global_dtors.
WebAssembly doesn't have a builtin way to invoke static destructors. Implement @llvm.global_dtors by creating wrapper functions that are registered in @llvm.global_ctors and which contain a call to __cxa_atexit
to register their destructor functions.
Definition in file WebAssemblyLowerGlobalDtors.cpp.
#define DEBUG_TYPE "wasm-lower-global-dtors" |
Definition at line 31 of file WebAssemblyLowerGlobalDtors.cpp.
INITIALIZE_PASS | ( | LowerGlobalDtors | , |
DEBUG_TYPE | , | ||
"Lower @llvm.global_dtors for WebAssembly" | , | ||
false | , | ||
false | |||
) |
Definition at line 53 of file WebAssemblyLowerGlobalDtors.cpp.