• Home
  • Raw
  • Download

Lines Matching refs:GV

132 void *CodeEmitter::UpdateGlobalMapping(const llvm::GlobalValue *GV, void *Addr) {  in UpdateGlobalMapping()  argument
135 GlobalAddressMapTy::iterator I = mGlobalAddressMap.find(GV); in UpdateGlobalMapping()
148 void *&CurVal = mGlobalAddressMap[GV]; in UpdateGlobalMapping()
568 const llvm::GlobalVariable *GV = in GetConstantValue() local
571 GetOrEmitGlobalVariable(const_cast<llvm::GlobalVariable*>(GV)); in GetConstantValue()
880 const llvm::GlobalValue *GV = GA->resolveAliasedGlobal(false); in GetPointerToGlobal() local
882 switch (GV->getValueID()) { in GetPointerToGlobal()
887 static_cast<const llvm::Function*>(GV), in GetPointerToGlobal()
894 if (void *P = mGlobalAddressMap[GV]) in GetPointerToGlobal()
897 llvm::GlobalVariable *GVar = (llvm::GlobalVariable*) GV; in GetPointerToGlobal()
900 return mGlobalAddressMap[GV]; in GetPointerToGlobal()
1019 void *CodeEmitter::GetOrEmitGlobalVariable(llvm::GlobalVariable *GV) { in GetOrEmitGlobalVariable() argument
1020 void *Ptr = GetPointerToGlobalIfAvailable(GV); in GetOrEmitGlobalVariable()
1024 if (GV->isDeclaration() || GV->hasAvailableExternallyLinkage()) { in GetOrEmitGlobalVariable()
1026 Ptr = GetPointerToNamedSymbol(GV->getName().str(), true); in GetOrEmitGlobalVariable()
1027 AddGlobalMapping(GV, Ptr); in GetOrEmitGlobalVariable()
1031 Ptr = GetMemoryForGV(GV); in GetOrEmitGlobalVariable()
1032 AddGlobalMapping(GV, Ptr); in GetOrEmitGlobalVariable()
1033 EmitGlobalVariable(GV); in GetOrEmitGlobalVariable()
1042 void *CodeEmitter::GetMemoryForGV(llvm::GlobalVariable *GV) { in GetMemoryForGV() argument
1045 llvm::Type *GlobalType = GV->getType()->getElementType(); in GetMemoryForGV()
1047 size_t A = mpTD->getPreferredAlignment(GV); in GetMemoryForGV()
1049 if (GV->isThreadLocal()) { in GetMemoryForGV()
1078 void CodeEmitter::EmitGlobalVariable(llvm::GlobalVariable *GV) { in EmitGlobalVariable() argument
1079 void *GA = GetPointerToGlobalIfAvailable(GV); in EmitGlobalVariable()
1081 if (GV->isThreadLocal()) in EmitGlobalVariable()
1087 GA = GetMemoryForGV(GV); in EmitGlobalVariable()
1088 AddGlobalMapping(GV, GA); in EmitGlobalVariable()
1091 InitializeConstantToMemory(GV->getInitializer(), GA); in EmitGlobalVariable()
1314 void CodeEmitter::startGVStub(const llvm::GlobalValue *GV, unsigned StubSize, in startGVStub() argument
1320 BufferBegin = CurBufferPtr = mpMemMgr->allocateStub(GV, StubSize, in startGVStub()
1352 void *CodeEmitter::allocIndirectGV(const llvm::GlobalValue *GV, in allocIndirectGV() argument
1355 uint8_t *IndGV = mpMemMgr->allocateStub(GV, Size, Alignment); in allocIndirectGV()