================ @@ -6252,3 +6243,188 @@ Status Process::WriteMemoryTags(lldb::addr_t addr, size_t len, return DoWriteMemoryTags(addr, len, tag_manager->GetAllocationTagType(), *packed_tags); } + +// Create a CoreFileMemoryRange from a MemoryRegionInfo +static Process::CoreFileMemoryRange +CreateCoreFileMemoryRange(const MemoryRegionInfo ®ion) { + const addr_t addr = region.GetRange().GetRangeBase(); + llvm::AddressRange range(addr, addr + region.GetRange().GetByteSize()); ---------------- clayborg wrote:
This is an llvm::AddressRange here. We also have lldb_private::AddressRange which contains a lldb_private::Address (section offset address) + byte size. The llvm::AddressRange just has a start address and end address. I could add accessors to MemoryRegionInfo for these, but as Jason already eluded to we have llvm::AddressRange and lldb_private::AddressRange and if we include both header files in MemoryRegionInfo.h, we might end up with more qualifications needed on bare `AddressRange` types in source files. https://github.com/llvm/llvm-project/pull/71772 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits