LLVM 20.0.0git
Macros | Functions | Variables
GlobalDCE.cpp File Reference
#include "llvm/Transforms/IPO/GlobalDCE.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/Analysis/TypeMetadataUtils.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/Module.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Transforms/IPO.h"
#include "llvm/Transforms/Utils/CtorUtils.h"
#include "llvm/Transforms/Utils/GlobalStatus.h"

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "globaldce"
 

Functions

 STATISTIC (NumAliases, "Number of global aliases removed")
 
 STATISTIC (NumFunctions, "Number of functions removed")
 
 STATISTIC (NumIFuncs, "Number of indirect functions removed")
 
 STATISTIC (NumVariables, "Number of global variables removed")
 
 STATISTIC (NumVFuncs, "Number of virtual functions removed")
 
static bool isEmptyFunction (Function *F)
 Returns true if F is effectively empty.
 

Variables

static cl::opt< boolClEnableVFE ("enable-vfe", cl::Hidden, cl::init(true), cl::desc("Enable virtual function elimination"))
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "globaldce"

Definition at line 31 of file GlobalDCE.cpp.

Function Documentation

◆ isEmptyFunction()

static bool isEmptyFunction ( Function F)
static

Returns true if F is effectively empty.

Definition at line 44 of file GlobalDCE.cpp.

References F, and I.

Referenced by llvm::GlobalDCEPass::run().

◆ STATISTIC() [1/5]

STATISTIC ( NumAliases  ,
"Number of global aliases removed"   
)

◆ STATISTIC() [2/5]

STATISTIC ( NumFunctions  ,
"Number of functions removed"   
)

◆ STATISTIC() [3/5]

STATISTIC ( NumIFuncs  ,
"Number of indirect functions removed"   
)

◆ STATISTIC() [4/5]

STATISTIC ( NumVariables  ,
"Number of global variables removed"   
)

◆ STATISTIC() [5/5]

STATISTIC ( NumVFuncs  ,
"Number of virtual functions removed"   
)

Variable Documentation

◆ ClEnableVFE

cl::opt< bool > ClEnableVFE("enable-vfe", cl::Hidden, cl::init(true), cl::desc("Enable virtual function elimination")) ( "enable-vfe"  ,
cl::Hidden  ,
cl::init(true ,
cl::desc("Enable virtual function elimination")   
)
static