Lines Matching refs:DVR

623   for (auto *DVR : DPUsers)  in replaceDbgUsesWithUndef()  local
624 DVR->setKillLocation(); in replaceDbgUsesWithUndef()
1591 for (auto *DVR : DbgVariableRecords) { in PhiHasDebugValue() local
1592 assert(is_contained(DVR->location_ops(), APN)); in PhiHasDebugValue()
1593 if ((DVR->getVariable() == DIVar) && (DVR->getExpression() == DIExpr)) in PhiHasDebugValue()
1634 static bool valueCoversEntireFragment(Type *ValTy, DbgVariableRecord *DVR) { in valueCoversEntireFragment() argument
1635 const DataLayout &DL = DVR->getModule()->getDataLayout(); in valueCoversEntireFragment()
1638 DVR->getExpression()->getActiveBits(DVR->getVariable())) in valueCoversEntireFragment()
1644 if (DVR->isAddressOfVariable()) { in valueCoversEntireFragment()
1646 assert(DVR->getNumVariableLocationOps() == 1 && in valueCoversEntireFragment()
1649 dyn_cast_or_null<AllocaInst>(DVR->getVariableLocationOp(0))) { in valueCoversEntireFragment()
1767 void llvm::ConvertDebugDeclareToDebugValue(DbgVariableRecord *DVR, in ConvertDebugDeclareToDebugValue() argument
1769 assert(DVR->isAddressOfVariable() || DVR->isDbgAssign()); in ConvertDebugDeclareToDebugValue()
1770 auto *DIVar = DVR->getVariable(); in ConvertDebugDeclareToDebugValue()
1772 auto *DIExpr = DVR->getExpression(); in ConvertDebugDeclareToDebugValue()
1775 DebugLoc NewLoc = getDebugValueLoc(DVR); in ConvertDebugDeclareToDebugValue()
1791 valueCoversEntireFragment(DV->getType(), DVR)); in ConvertDebugDeclareToDebugValue()
1800 LLVM_DEBUG(dbgs() << "Failed to convert dbg.declare to dbg.value: " << *DVR in ConvertDebugDeclareToDebugValue()
1848 void llvm::ConvertDebugDeclareToDebugValue(DbgVariableRecord *DVR, LoadInst *LI, in ConvertDebugDeclareToDebugValue() argument
1850 auto *DIVar = DVR->getVariable(); in ConvertDebugDeclareToDebugValue()
1851 auto *DIExpr = DVR->getExpression(); in ConvertDebugDeclareToDebugValue()
1854 if (!valueCoversEntireFragment(LI->getType(), DVR)) { in ConvertDebugDeclareToDebugValue()
1859 << *DVR << '\n'); in ConvertDebugDeclareToDebugValue()
1863 DebugLoc NewLoc = getDebugValueLoc(DVR); in ConvertDebugDeclareToDebugValue()
1888 void llvm::ConvertDebugDeclareToDebugValue(DbgVariableRecord *DVR, PHINode *APN, in ConvertDebugDeclareToDebugValue() argument
1890 auto *DIVar = DVR->getVariable(); in ConvertDebugDeclareToDebugValue()
1891 auto *DIExpr = DVR->getExpression(); in ConvertDebugDeclareToDebugValue()
1897 if (!valueCoversEntireFragment(APN->getType(), DVR)) { in ConvertDebugDeclareToDebugValue()
1902 << *DVR << '\n'); in ConvertDebugDeclareToDebugValue()
1909 DebugLoc NewLoc = getDebugValueLoc(DVR); in ConvertDebugDeclareToDebugValue()
1931 for (DbgVariableRecord &DVR : filterDbgVars(BI.getDbgRecordRange())) { in LowerDbgDeclare()
1932 if (DVR.getType() == DbgVariableRecord::LocationType::Declare) in LowerDbgDeclare()
1933 DVRs.push_back(&DVR); in LowerDbgDeclare()
2019 for (DbgVariableRecord &DVR : filterDbgVars(I.getDbgRecordRange())) { in insertDbgVariableRecordsForPHIs()
2020 for (Value *V : DVR.location_ops()) in insertDbgVariableRecordsForPHIs()
2022 DbgValueMap.insert({Loc, &DVR}); in insertDbgVariableRecordsForPHIs()
2162 DbgVariableRecord *DVR, in updateOneDbgValueForAlloca() argument
2181 assert(DVR); in updateOneDbgValueForAlloca()
2182 DVR->setExpression(DIExpr); in updateOneDbgValueForAlloca()
2183 DVR->replaceVariableLocationOp(0u, NewAddress); in updateOneDbgValueForAlloca()
2200 for (DbgVariableRecord *DVR : DPUsers) in replaceDbgValueForAlloca()
2201 updateOneDbgValueForAlloca(DVR->getDebugLoc(), DVR->getVariable(), in replaceDbgValueForAlloca()
2202 DVR->getExpression(), NewAllocaAddress, nullptr, in replaceDbgValueForAlloca()
2203 DVR, Builder, Offset); in replaceDbgValueForAlloca()
2320 for (auto *DVR : DPUsers) { in salvageDebugInfoForDbgValues() local
2321 if (DVR->isDbgAssign()) { in salvageDebugInfoForDbgValues()
2322 if (DVR->getAddress() == &I) { in salvageDebugInfoForDbgValues()
2323 salvageDbgAssignAddress(DVR); in salvageDebugInfoForDbgValues()
2326 if (DVR->getValue() != &I) in salvageDebugInfoForDbgValues()
2334 DVR->getType() != DbgVariableRecord::LocationType::Declare; in salvageDebugInfoForDbgValues()
2335 auto DVRLocation = DVR->location_ops(); in salvageDebugInfoForDbgValues()
2345 DIExpression *SalvagedExpr = DVR->getExpression(); in salvageDebugInfoForDbgValues()
2364 DVR->replaceVariableLocationOp(&I, Op0); in salvageDebugInfoForDbgValues()
2368 DVR->setExpression(SalvagedExpr); in salvageDebugInfoForDbgValues()
2369 } else if (DVR->getType() != DbgVariableRecord::LocationType::Declare && in salvageDebugInfoForDbgValues()
2371 DVR->getNumVariableLocationOps() + AdditionalValues.size() <= in salvageDebugInfoForDbgValues()
2373 DVR->addVariableLocationOps(AdditionalValues, SalvagedExpr); in salvageDebugInfoForDbgValues()
2379 DVR->setKillLocation(); in salvageDebugInfoForDbgValues()
2381 LLVM_DEBUG(dbgs() << "SALVAGE: " << DVR << '\n'); in salvageDebugInfoForDbgValues()
2391 for (auto *DVR : DPUsers) in salvageDebugInfoForDbgValues() local
2392 DVR->setKillLocation(); in salvageDebugInfoForDbgValues()
2608 function_ref<DbgValReplacement(DbgVariableRecord &DVR)> RewriteDVRExpr) { in rewriteDebugUsers()
2640 for (auto *DVR : DPUsers) { in rewriteDebugUsers() local
2641 Instruction *MarkedInstr = DVR->getMarker()->MarkedInstr; in rewriteDebugUsers()
2648 LLVM_DEBUG(dbgs() << "MOVE: " << *DVR << '\n'); in rewriteDebugUsers()
2649 DVR->removeFromParent(); in rewriteDebugUsers()
2651 DomPoint.getParent()->insertDbgRecordAfter(DVR, &DomPoint); in rewriteDebugUsers()
2654 UndefOrSalvageDVR.insert(DVR); in rewriteDebugUsers()
2673 for (auto *DVR : DPUsers) { in rewriteDebugUsers() local
2674 if (UndefOrSalvageDVR.count(DVR)) in rewriteDebugUsers()
2677 DbgValReplacement DVRepl = RewriteDVRExpr(*DVR); in rewriteDebugUsers()
2681 DVR->replaceVariableLocationOp(&From, &To); in rewriteDebugUsers()
2682 DVR->setExpression(*DVRepl); in rewriteDebugUsers()
2683 LLVM_DEBUG(dbgs() << "REWRITE: " << DVR << '\n'); in rewriteDebugUsers()
2735 auto IdentityDVR = [&](DbgVariableRecord &DVR) -> DbgValReplacement { in replaceAllDbgUsesWith() argument
2736 return DVR.getExpression(); in replaceAllDbgUsesWith()
2773 auto SignOrZeroExtDVR = [&](DbgVariableRecord &DVR) -> DbgValReplacement { in replaceAllDbgUsesWith() argument
2774 DILocalVariable *Var = DVR.getVariable(); in replaceAllDbgUsesWith()
2782 return DIExpression::appendExt(DVR.getExpression(), ToBits, FromBits, in replaceAllDbgUsesWith()
3613 for (auto *DVR : DPUsers) in dropDebugUsers() local
3614 DVR->eraseFromParent(); in dropDebugUsers()
3715 for (DbgVariableRecord &DVR : filterDbgVars(Inst->getDbgRecordRange())) { in remapDebugVariable()
3716 RemapDebugOperands(&DVR, DVR.location_ops()); in remapDebugVariable()
3717 if (DVR.isDbgAssign()) in remapDebugVariable()
3718 RemapAssignAddress(&DVR); in remapDebugVariable()