diff options
Diffstat (limited to 'llvm/lib/IR/IntrinsicInst.cpp')
-rw-r--r-- | llvm/lib/IR/IntrinsicInst.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/llvm/lib/IR/IntrinsicInst.cpp b/llvm/lib/IR/IntrinsicInst.cpp index 787889934d8..43a93890a61 100644 --- a/llvm/lib/IR/IntrinsicInst.cpp +++ b/llvm/lib/IR/IntrinsicInst.cpp @@ -32,10 +32,11 @@ using namespace llvm; //===----------------------------------------------------------------------===// -/// DbgInfoIntrinsic - This is the common base class for debug info intrinsics +/// DbgVariableIntrinsic - This is the common base class for debug info +/// intrinsics for variables. /// -Value *DbgInfoIntrinsic::getVariableLocation(bool AllowNullOp) const { +Value *DbgVariableIntrinsic::getVariableLocation(bool AllowNullOp) const { Value *Op = getArgOperand(0); if (AllowNullOp && !Op) return nullptr; @@ -45,14 +46,11 @@ Value *DbgInfoIntrinsic::getVariableLocation(bool AllowNullOp) const { return V->getValue(); // When the value goes to null, it gets replaced by an empty MDNode. - assert((isa<DbgLabelInst>(this) - || !cast<MDNode>(MD)->getNumOperands()) - && "DbgValueInst Expected an empty MDNode"); - + assert(!cast<MDNode>(MD)->getNumOperands() && "Expected an empty MDNode"); return nullptr; } -Optional<uint64_t> DbgInfoIntrinsic::getFragmentSizeInBits() const { +Optional<uint64_t> DbgVariableIntrinsic::getFragmentSizeInBits() const { if (auto Fragment = getExpression()->getFragmentInfo()) return Fragment->SizeInBits; return getVariable()->getSizeInBits(); |