[Lldb-commits] [lldb] r305111 - [VMRange] Remove unused FindRangeIndexThatContainsValue().
Davide Italiano via lldb-commits
lldb-commits at lists.llvm.org
Fri Jun 9 14:01:55 PDT 2017
Author: davide
Date: Fri Jun 9 16:01:55 2017
New Revision: 305111
URL: http://llvm.org/viewvc/llvm-project?rev=305111&view=rev
Log:
[VMRange] Remove unused FindRangeIndexThatContainsValue().
Modified:
lldb/trunk/include/lldb/Utility/VMRange.h
lldb/trunk/source/Utility/VMRange.cpp
Modified: lldb/trunk/include/lldb/Utility/VMRange.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Utility/VMRange.h?rev=305111&r1=305110&r2=305111&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Utility/VMRange.h (original)
+++ lldb/trunk/include/lldb/Utility/VMRange.h Fri Jun 9 16:01:55 2017
@@ -111,11 +111,6 @@ public:
static bool ContainsRange(const VMRange::collection &coll,
const VMRange &range);
- // Returns a valid index into coll when a match is found, else UINT32_MAX
- // is returned
- static size_t FindRangeIndexThatContainsValue(const VMRange::collection &coll,
- lldb::addr_t value);
-
protected:
lldb::addr_t m_base_addr;
lldb::addr_t m_byte_size;
Modified: lldb/trunk/source/Utility/VMRange.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Utility/VMRange.cpp?rev=305111&r1=305110&r2=305111&view=diff
==============================================================================
--- lldb/trunk/source/Utility/VMRange.cpp (original)
+++ lldb/trunk/source/Utility/VMRange.cpp Fri Jun 9 16:01:55 2017
@@ -34,17 +34,6 @@ bool VMRange::ContainsRange(const VMRang
return llvm::find_if(coll, in_range_predicate) != coll.end();
}
-size_t VMRange::FindRangeIndexThatContainsValue(const VMRange::collection &coll,
- lldb::addr_t value) {
- ValueInRangeUnaryPredicate in_range_predicate(value);
- VMRange::const_iterator begin = coll.begin();
- VMRange::const_iterator end = coll.end();
- VMRange::const_iterator pos = std::find_if(begin, end, in_range_predicate);
- if (pos != end)
- return std::distance(begin, pos);
- return UINT32_MAX;
-}
-
void VMRange::Dump(Stream *s, lldb::addr_t offset, uint32_t addr_width) const {
s->AddressRange(offset + GetBaseAddress(), offset + GetEndAddress(),
addr_width);
More information about the lldb-commits
mailing list