Skip to content

Commit da45b6c

Browse files
authored
[RemoveDIs][NFC] Remove dbg intrinsic version of calculateFragmentIntersect (llvm#153378)
1 parent b4c31dc commit da45b6c

File tree

2 files changed

+2
-30
lines changed

2 files changed

+2
-30
lines changed

llvm/include/llvm/IR/DebugInfo.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -223,11 +223,6 @@ LLVM_ABI void deleteAll(Function *F);
223223
///
224224
/// Result contains a zero-sized fragment if there's no intersect.
225225
LLVM_ABI bool
226-
calculateFragmentIntersect(const DataLayout &DL, const Value *Dest,
227-
uint64_t SliceOffsetInBits, uint64_t SliceSizeInBits,
228-
const DbgAssignIntrinsic *DbgAssign,
229-
std::optional<DIExpression::FragmentInfo> &Result);
230-
LLVM_ABI bool
231226
calculateFragmentIntersect(const DataLayout &DL, const Value *Dest,
232227
uint64_t SliceOffsetInBits, uint64_t SliceSizeInBits,
233228
const DbgVariableRecord *DVRAssign,

llvm/lib/IR/DebugInfo.cpp

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1927,12 +1927,9 @@ void at::deleteAll(Function *F) {
19271927
}
19281928
}
19291929

1930-
/// FIXME: Remove this wrapper function and call
1931-
/// DIExpression::calculateFragmentIntersect directly.
1932-
template <typename T>
1933-
bool calculateFragmentIntersectImpl(
1930+
bool at::calculateFragmentIntersect(
19341931
const DataLayout &DL, const Value *Dest, uint64_t SliceOffsetInBits,
1935-
uint64_t SliceSizeInBits, const T *AssignRecord,
1932+
uint64_t SliceSizeInBits, const DbgVariableRecord *AssignRecord,
19361933
std::optional<DIExpression::FragmentInfo> &Result) {
19371934
// No overlap if this DbgRecord describes a killed location.
19381935
if (AssignRecord->isKillAddress())
@@ -1961,26 +1958,6 @@ bool calculateFragmentIntersectImpl(
19611958
BitExtractOffsetInBits, VarFrag, Result, OffsetFromLocationInBits);
19621959
}
19631960

1964-
/// FIXME: Remove this wrapper function and call
1965-
/// DIExpression::calculateFragmentIntersect directly.
1966-
bool at::calculateFragmentIntersect(
1967-
const DataLayout &DL, const Value *Dest, uint64_t SliceOffsetInBits,
1968-
uint64_t SliceSizeInBits, const DbgAssignIntrinsic *DbgAssign,
1969-
std::optional<DIExpression::FragmentInfo> &Result) {
1970-
return calculateFragmentIntersectImpl(DL, Dest, SliceOffsetInBits,
1971-
SliceSizeInBits, DbgAssign, Result);
1972-
}
1973-
1974-
/// FIXME: Remove this wrapper function and call
1975-
/// DIExpression::calculateFragmentIntersect directly.
1976-
bool at::calculateFragmentIntersect(
1977-
const DataLayout &DL, const Value *Dest, uint64_t SliceOffsetInBits,
1978-
uint64_t SliceSizeInBits, const DbgVariableRecord *DVRAssign,
1979-
std::optional<DIExpression::FragmentInfo> &Result) {
1980-
return calculateFragmentIntersectImpl(DL, Dest, SliceOffsetInBits,
1981-
SliceSizeInBits, DVRAssign, Result);
1982-
}
1983-
19841961
/// Update inlined instructions' DIAssignID metadata. We need to do this
19851962
/// otherwise a function inlined more than once into the same function
19861963
/// will cause DIAssignID to be shared by many instructions.

0 commit comments

Comments
 (0)