Home
last modified time | relevance | path

Searched refs:GlobalVariable (Results 1 – 25 of 199) sorted by relevance

12345678

/external/llvm/include/llvm/IR/
DGlobalVariable.h35 class GlobalVariable : public GlobalObject, public ilist_node<GlobalVariable> {
36 friend class SymbolTableListTraits<GlobalVariable, Module>;
38 void operator=(const GlobalVariable &) = delete;
39 GlobalVariable(const GlobalVariable &) = delete;
57 GlobalVariable(Type *Ty, bool isConstant, LinkageTypes Linkage,
63 GlobalVariable(Module &M, Type *Ty, bool isConstant,
65 const Twine &Name = "", GlobalVariable *InsertBefore = nullptr,
69 ~GlobalVariable() override { in ~GlobalVariable()
179 struct OperandTraits<GlobalVariable> :
180 public OptionalOperandTraits<GlobalVariable> {
[all …]
DModule.h55 template<> struct ilist_traits<GlobalVariable>
56 : public SymbolTableListTraits<GlobalVariable, Module> {
58 GlobalVariable *createSentinel() const {
59 return static_cast<GlobalVariable*>(&Sentinel);
61 static void destroySentinel(GlobalVariable*) {}
63 GlobalVariable *provideInitialHead() const { return createSentinel(); }
64 GlobalVariable *ensureHead(GlobalVariable*) const { return createSentinel(); }
65 static void noteHead(GlobalVariable*, GlobalVariable*) {}
67 mutable ilist_node<GlobalVariable> Sentinel;
119 typedef iplist<GlobalVariable> GlobalListType;
[all …]
/external/llvm/lib/Transforms/IPO/
DConstantMerge.cpp49 bool hasKnownAlignment(GlobalVariable *GV) const;
53 unsigned getAlignment(GlobalVariable *GV) const;
67 static void FindUsedValues(GlobalVariable *LLVMUsed, in FindUsedValues()
80 static bool IsBetterCanonical(const GlobalVariable &A, in IsBetterCanonical()
81 const GlobalVariable &B) { in IsBetterCanonical()
91 unsigned ConstantMerge::getAlignment(GlobalVariable *GV) const { in getAlignment()
106 DenseMap<Constant *, GlobalVariable *> CMap; in runOnModule()
109 SmallVector<std::pair<GlobalVariable*, GlobalVariable*>, 32> Replacements; in runOnModule()
122 GlobalVariable *GV = GVI++; in runOnModule()
148 GlobalVariable *&Slot = CMap[Init]; in runOnModule()
[all …]
DLowerBitSets.cpp62 const DenseMap<GlobalVariable *, uint64_t> &GlobalLayout, Value *V, in containsValue() argument
64 if (auto GV = dyn_cast<GlobalVariable>(V)) { in containsValue()
183 GlobalVariable *ByteArray;
213 const DenseMap<GlobalVariable *, uint64_t> &GlobalLayout);
220 GlobalVariable *CombinedGlobal,
221 const DenseMap<GlobalVariable *, uint64_t> &GlobalLayout);
223 const std::vector<GlobalVariable *> &Globals);
266 const DenseMap<GlobalVariable *, uint64_t> &GlobalLayout) { in buildBitSet() argument
274 auto OpGlobal = cast<GlobalVariable>( in buildBitSet()
308 auto ByteArrayGlobal = new GlobalVariable( in createByteArray()
[all …]
DGlobalOpt.cpp84 bool ProcessGlobal(GlobalVariable *GV,Module::global_iterator &GVI);
85 bool ProcessInternalGlobal(GlobalVariable *GV,Module::global_iterator &GVI,
105 static bool isLeakCheckerRoot(GlobalVariable *GV) { in isLeakCheckerRoot()
183 static bool CleanupPointerRootUsers(GlobalVariable *GV, in CleanupPointerRootUsers()
222 GlobalVariable *MemSrc = dyn_cast<GlobalVariable>(MTI->getSource()); in CleanupPointerRootUsers()
472 static GlobalVariable *SRAGlobal(GlobalVariable *GV, const DataLayout &DL) { in SRAGlobal()
481 std::vector<GlobalVariable*> NewGlobals; in SRAGlobal()
495 GlobalVariable *NGV = new GlobalVariable(STy->getElementType(i), false, in SRAGlobal()
496 GlobalVariable::InternalLinkage, in SRAGlobal()
528 GlobalVariable *NGV = new GlobalVariable(STy->getElementType(), false, in SRAGlobal()
[all …]
/external/llvm/lib/IR/
DGlobals.cpp126 if (const GlobalVariable *GV = dyn_cast<GlobalVariable>(this)) in isDeclaration()
142 GlobalVariable::GlobalVariable(Type *Ty, bool constant, LinkageTypes Link, in GlobalVariable() function in GlobalVariable
147 OperandTraits<GlobalVariable>::op_begin(this), in GlobalVariable()
159 GlobalVariable::GlobalVariable(Module &M, Type *Ty, bool constant, in GlobalVariable() function in GlobalVariable
161 const Twine &Name, GlobalVariable *Before, in GlobalVariable()
165 OperandTraits<GlobalVariable>::op_begin(this), in GlobalVariable()
182 void GlobalVariable::setParent(Module *parent) { in setParent()
186 void GlobalVariable::removeFromParent() { in removeFromParent()
190 void GlobalVariable::eraseFromParent() { in eraseFromParent()
194 void GlobalVariable::replaceUsesOfWithOnConstant(Value *From, Value *To, in replaceUsesOfWithOnConstant()
[all …]
DModule.cpp41 template class llvm::SymbolTableListTraits<GlobalVariable, Module>;
122 Function *New = Function::Create(Ty, GlobalVariable::ExternalLinkage, Name); in getOrInsertFunction()
203 GlobalVariable *Module::getGlobalVariable(StringRef Name, bool AllowLocal) { in getGlobalVariable()
204 if (GlobalVariable *Result = in getGlobalVariable()
205 dyn_cast_or_null<GlobalVariable>(getNamedValue(Name))) in getGlobalVariable()
219 GlobalVariable *GV = dyn_cast_or_null<GlobalVariable>(getNamedValue(Name)); in getOrInsertGlobal()
222 GlobalVariable *New = in getOrInsertGlobal()
223 new GlobalVariable(*this, Ty, false, GlobalVariable::ExternalLinkage, in getOrInsertGlobal()
451 for (GlobalVariable &GV : globals()) in dropAllReferences()
/external/llvm/lib/CodeGen/
DGlobalMerge.cpp105 bool doMerge(SmallVectorImpl<GlobalVariable*> &Globals,
111 bool isMustKeepGlobalVariable(const GlobalVariable *GV) const { in isMustKeepGlobalVariable()
123 SmallPtrSet<const GlobalVariable *, 16> MustKeepGlobalVariables;
155 bool GlobalMerge::doMerge(SmallVectorImpl<GlobalVariable*> &Globals, in doMerge()
159 [this](const GlobalVariable *GV1, const GlobalVariable *GV2) { in doMerge()
184 GlobalVariable *TheFirstExternal = 0; in doMerge()
212 GlobalVariable *MergedGV = new GlobalVariable( in doMerge()
216 nullptr, GlobalVariable::NotThreadLocal, AddrSpace); in doMerge()
248 const GlobalVariable *GV = M.getGlobalVariable("llvm.used"); in collectUsedGlobalVariables()
255 if (const GlobalVariable *G = in collectUsedGlobalVariables()
[all …]
/external/llvm/unittests/IR/
DValueTest.cpp52 GlobalVariable *Dummy0 in TEST()
53 = new GlobalVariable(*M, in TEST()
60 GlobalVariable::NotThreadLocal, in TEST()
74 GlobalVariable *DummyCast0 in TEST()
75 = new GlobalVariable(*M, in TEST()
82 GlobalVariable::NotThreadLocal, in TEST()
97 GlobalVariable *Var = in TEST()
98 new GlobalVariable(*M, Int32Ty, true, GlobalValue::ExternalLinkage, in TEST()
100 GlobalVariable::NotThreadLocal, 1); in TEST()
/external/llvm/lib/Transforms/Instrumentation/
DInstrProfiling.cpp52 DenseMap<GlobalVariable *, GlobalVariable *> RegionCounters;
83 void lowerCoverageData(GlobalVariable *CoverageData);
89 GlobalVariable *getOrCreateRegionCounters(InstrProfIncrementInst *Inc);
129 if (GlobalVariable *Coverage = M.getNamedGlobal("__llvm_coverage_mapping")) { in runOnModule()
144 GlobalVariable *Counters = getOrCreateRegionCounters(Inc); in lowerIncrement()
155 void InstrProfiling::lowerCoverageData(GlobalVariable *CoverageData) { in lowerCoverageData()
170 assert(isa<GlobalVariable>(V) && "Missing reference to function name"); in lowerCoverageData()
171 GlobalVariable *Name = cast<GlobalVariable>(V); in lowerCoverageData()
191 GlobalVariable *
193 GlobalVariable *Name = Inc->getName(); in getOrCreateRegionCounters()
[all …]
DSanitizerCoverage.cpp135 GlobalVariable *GuardArray;
136 GlobalVariable *EightBitCounterArray;
193 new GlobalVariable(M, Int32Ty, false, GlobalValue::ExternalLinkage, in runOnModule()
197 new GlobalVariable(M, Int8Ty, false, GlobalVariable::ExternalLinkage, in runOnModule()
208 GlobalVariable *RealGuardArray = new GlobalVariable( in runOnModule()
218 GlobalVariable *RealEightBitCounterArray; in runOnModule()
224 RealEightBitCounterArray = new GlobalVariable( in runOnModule()
236 GlobalVariable *ModuleName = in runOnModule()
237 new GlobalVariable(M, ModNameStrConst->getType(), true, in runOnModule()
312 GlobalVariable *CalleeCache = new GlobalVariable( in InjectCoverageForIndirectCalls()
/external/llvm/include/llvm/ExecutionEngine/Orc/
DCloneSubModule.h25 class GlobalVariable; variable
32 typedef std::function<void(GlobalVariable &, const GlobalVariable &,
43 void copyGVInitializer(GlobalVariable &New, const GlobalVariable &Orig,
/external/llvm/unittests/ExecutionEngine/
DExecutionEngineTest.cpp41 GlobalVariable *NewExtGlobal(Type *T, const Twine &Name) { in NewExtGlobal()
42 return new GlobalVariable(*M, T, false, // Not constant. in NewExtGlobal()
52 GlobalVariable *G1 = in TEST_F()
66 GlobalVariable *G2 = in TEST_F()
79 GlobalVariable *G1 = in TEST_F()
90 GlobalVariable *G2 = in TEST_F()
107 GlobalVariable *G1 = in TEST_F()
118 GlobalVariable *G2 = in TEST_F()
127 GlobalVariable *G1 = in TEST_F()
/external/llvm/lib/Transforms/Utils/
DCtorUtils.cpp30 void removeGlobalCtors(GlobalVariable *GCL, const BitVector &CtorsToRemove) { in removeGlobalCtors()
50 GlobalVariable *NGV = in removeGlobalCtors()
51 new GlobalVariable(CA->getType(), GCL->isConstant(), GCL->getLinkage(), in removeGlobalCtors()
68 std::vector<Function *> parseGlobalCtors(GlobalVariable *GV) { in parseGlobalCtors()
83 GlobalVariable *findGlobalCtors(Module &M) { in findGlobalCtors()
84 GlobalVariable *GV = M.getGlobalVariable("llvm.global_ctors"); in findGlobalCtors()
122 GlobalVariable *GlobalCtors = findGlobalCtors(M); in optimizeGlobalCtorsList()
DCloneModule.cpp48 GlobalVariable *GV = new GlobalVariable(*New, in CloneModule()
52 (GlobalVariable*) nullptr, in CloneModule()
85 GlobalVariable *GV = cast<GlobalVariable>(VMap[I]); in CloneModule()
/external/llvm/lib/ExecutionEngine/Orc/
DCloneSubModule.cpp10 void copyGVInitializer(GlobalVariable &New, const GlobalVariable &Orig, in copyGVInitializer()
43 GlobalVariable *GV = new GlobalVariable( in CloneSubModule()
45 (Constant *)nullptr, I->getName(), (GlobalVariable *)nullptr, in CloneSubModule()
76 GlobalVariable &GV = *cast<GlobalVariable>(VMap[I]); in CloneSubModule()
/external/clang/lib/CodeGen/
DCGVTables.h94 llvm::GlobalVariable *
97 llvm::GlobalVariable::LinkageTypes Linkage,
102 llvm::GlobalVariable *GetAddrOfVTT(const CXXRecordDecl *RD);
105 void EmitVTTDefinition(llvm::GlobalVariable *VTT,
106 llvm::GlobalVariable::LinkageTypes Linkage,
DSanitizerMetadata.h21 class GlobalVariable; variable
40 void reportGlobalToASan(llvm::GlobalVariable *GV, const VarDecl &D,
42 void reportGlobalToASan(llvm::GlobalVariable *GV, SourceLocation Loc,
45 void disableSanitizerForGlobal(llvm::GlobalVariable *GV);
DCGVTT.cpp21 static llvm::GlobalVariable *
25 llvm::GlobalVariable::LinkageTypes Linkage, in GetAddrOfVTTVTable()
42 CodeGenVTables::EmitVTTDefinition(llvm::GlobalVariable *VTT, in EmitVTTDefinition()
43 llvm::GlobalVariable::LinkageTypes Linkage, in EmitVTTDefinition()
51 SmallVector<llvm::GlobalVariable *, 8> VTables; in EmitVTTDefinition()
64 llvm::GlobalVariable *VTable = VTables[i->VTableIndex]; in EmitVTTDefinition()
104 llvm::GlobalVariable *CodeGenVTables::GetAddrOfVTT(const CXXRecordDecl *RD) { in GetAddrOfVTT()
122 llvm::GlobalVariable *GV = in GetAddrOfVTT()
/external/llvm/lib/Target/NVPTX/
DNVPTXGenericToNVVM.cpp49 Value *getOrInsertCVTA(Module *M, Function *F, GlobalVariable *GV,
60 typedef ValueMap<GlobalVariable *, GlobalVariable *> GVMapTy;
84 GlobalVariable *GV = I++; in runOnModule()
88 GlobalVariable *NewGV = new GlobalVariable( in runOnModule()
146 GlobalVariable *GV = I->first; in runOnModule()
147 GlobalVariable *NewGV = I->second; in runOnModule()
170 GlobalVariable *GV, in getOrInsertCVTA()
222 if (isa<GlobalVariable>(C)) { in remapConstant()
231 GVMapTy::iterator I = GVMap.find(cast<GlobalVariable>(C)); in remapConstant()
/external/llvm/lib/Target/XCore/
DXCoreLowerThreadLocal.cpp49 bool lowerGlobal(GlobalVariable *GV);
161 static bool rewriteNonInstructionUses(GlobalVariable *GV, Pass *P) { in rewriteNonInstructionUses()
180 bool XCoreLowerThreadLocal::lowerGlobal(GlobalVariable *GV) { in lowerGlobal()
197 GlobalVariable *NewGV = in lowerGlobal()
198 new GlobalVariable(*M, NewType, GV->isConstant(), GV->getLinkage(), in lowerGlobal()
200 GlobalVariable::NotThreadLocal, in lowerGlobal()
230 SmallVector<GlobalVariable *, 16> ThreadLocalGlobals; in runOnModule()
233 GlobalVariable *GV = GVI; in runOnModule()
/external/lldb/source/Expression/
DIRForTarget.cpp492 GlobalVariable *result_global = dyn_cast<GlobalVariable>(result_value); in CreateResultVariable()
614 GlobalVariable *new_result_global = new GlobalVariable((*m_module), in CreateResultVariable()
721 IRForTarget::RewriteObjCConstString (llvm::GlobalVariable *ns_str, in RewriteObjCConstString()
722 llvm::GlobalVariable *cstr) in RewriteObjCConstString()
854 GlobalVariable *nsstring_global = dyn_cast<GlobalVariable>(nsstring_value); in RewriteObjCConstStrings()
950 GlobalVariable *cstr_global = dyn_cast<GlobalVariable>(nsstring_cstr); in RewriteObjCConstStrings()
1032 GlobalVariable *gv = dyn_cast<GlobalVariable>(vi->second); in RewriteObjCConstStrings()
1056 GlobalVariable *global_variable = dyn_cast<GlobalVariable>(value); in IsObjCSelectorRef()
1087GlobalVariable *_objc_selector_references_ = dyn_cast<GlobalVariable>(load->getPointerOperand()); in RewriteObjCSelector()
1106 GlobalVariable *_objc_meth_var_name_ = dyn_cast<GlobalVariable>(osr_initializer_base); in RewriteObjCSelector()
[all …]
/external/llvm/lib/Linker/
DLinkModules.cpp409 GlobalVariable *NewGV; // New aggregate global in dest module.
451 const GlobalVariable *&GVar);
489 bool linkAppendingVarProto(GlobalVariable *DstGV,
490 const GlobalVariable *SrcGV);
497 void linkGlobalInit(GlobalVariable &Dst, GlobalVariable &Src);
550 static GlobalVariable *copyGlobalVariableProto(TypeMapTy &TypeMap, Module &DstM, in copyGlobalVariableProto()
551 const GlobalVariable *SGVar) { in copyGlobalVariableProto()
555 GlobalVariable *NewDGV = new GlobalVariable( in copyGlobalVariableProto()
587 if (auto *SGVar = dyn_cast<GlobalVariable>(SGV)) in copyGlobalValueProto()
616 const GlobalVariable *&GVar) { in getComdatLeader()
[all …]
/external/llvm/lib/LTO/
DLTOModule.cpp266 if (GlobalVariable *gvn = dyn_cast<GlobalVariable>(op)) { in objcClassNameFromExpression()
280 void LTOModule::addObjCClass(const GlobalVariable *clgv) { in addObjCClass()
314 void LTOModule::addObjCCategory(const GlobalVariable *clgv) { in addObjCCategory()
337 void LTOModule::addObjCClassRef(const GlobalVariable *clgv) { in addObjCClassRef()
396 if (const GlobalVariable *gv = dyn_cast<GlobalVariable>(v)) { in addDefinedDataSymbol()
403 if (const GlobalVariable *gv = dyn_cast<GlobalVariable>(v)) { in addDefinedDataSymbol()
410 if (const GlobalVariable *gv = dyn_cast<GlobalVariable>(v)) { in addDefinedDataSymbol()
443 const GlobalVariable *gv = dyn_cast<GlobalVariable>(def); in addDefinedSymbol()
617 if (isa<GlobalVariable>(GV)) { in parseSymbols()
/external/llvm/lib/Target/
DTargetMachine.cpp94 case GlobalVariable::NotThreadLocal: in getSelectedTLSModel()
97 case GlobalVariable::GeneralDynamicTLSModel: in getSelectedTLSModel()
99 case GlobalVariable::LocalDynamicTLSModel: in getSelectedTLSModel()
101 case GlobalVariable::InitialExecTLSModel: in getSelectedTLSModel()
103 case GlobalVariable::LocalExecTLSModel: in getSelectedTLSModel()

12345678