mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
add a pass that can extract all kinds of global values, not just functions. Update llvm-extract to use it and optionally extract a global variable if you want it too
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48015 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -24,6 +24,7 @@ class ModulePass;
|
||||
class Pass;
|
||||
class Function;
|
||||
class BasicBlock;
|
||||
class GlobalValue;
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
//
|
||||
@@ -85,6 +86,14 @@ ModulePass *createGlobalDCEPass();
|
||||
ModulePass *createFunctionExtractionPass(Function *F, bool deleteFn = false,
|
||||
bool relinkCallees = false);
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
/// createGVExtractionPass - If deleteFn is true, this pass deletes as
|
||||
/// the specified global values. Otherwise, it deletes as much of the module as
|
||||
/// possible, except for the global values specified.
|
||||
///
|
||||
ModulePass *createGVExtractionPass(std::vector<GlobalValue*>& GVs, bool
|
||||
deleteFn = false,
|
||||
bool relinkCallees = false);
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
/// createFunctionInliningPass - Return a new pass object that uses a heuristic
|
||||
|
Reference in New Issue
Block a user