--
You received this message because you are subscribed to the Google Groups "dart-gsoc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dart-gsoc+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dart-gsoc/f4576022-e86a-4f17-9b06-566dfd392502n%40googlegroups.com.
Hi Mentors,
Following up on my previous introductory email, I’ve been closely following recent discussions around exposing native memory to DevTools—especially the thread involving Nourhan and Ben—which has been very helpful in shaping my approach.
I’ve started exploring the VM service implementation in runtime/vm/service.cc to understand how abstractions like MethodParameter and JSONStream are used to structure RPCs. Building on insights from my initial hex-grid prototype, I’m currently exploring the VM-side infrastructure that could support this kind of inspection safely. Key aspects I’m considering include:
My work with the prototype helped me understand how layout and alignment impact interpretation, and I’m eager to translate those insights into a robust VM-service-layer solution that preserves safety and stability.
I’d greatly appreciate any guidance or suggestions on whether this direction—utilizing a region-aware RPC to back a native memory inspector—aligns with the team’s vision, or if there are specific constraints or prior work I should prioritize in my exploration.
Thanks for your guidance!
Best regards,
Dheeraj Kumar Thota
Safety and Scoping: Instead of arbitrary address reads, I’m looking into restricting access to well-defined, VM-tracked regions. This includes not just internal heap pages, but also external/native allocations where the VM has visibility.
To view this discussion visit https://groups.google.com/d/msgid/dart-gsoc/6538cb8b-392f-4706-9852-51befc5c0e59n%40googlegroups.com.
Hi Daco,
Thank you for the previous guidance. Shifting my perspective made me look deeper into OS-level memory handling—specifically VirtualQuery and ReadProcessMemory on Windows, and /proc/self/maps with process_vm_readv() on Linux—which has significantly clarified my technical roadmap. For now, I am focusing exclusively on Windows.
Based on your suggestion, I’m treating the OS APIs as the source of truth for memory accessibility, using ReadProcessMemory (with partial read handling) as the authoritative mechanism.
I’m currently exploring improving the efficiency of the read engine by introducing a lightweight, page-aware cache derived from VirtualQuery, mainly to:
skip obviously invalid regions (e.g., MEM_RESERVE)
reduce unnecessary system calls during large scans
However, this cache would only serve as a heuristic for performance and not as a source of correctness—all final decisions would still rely on the actual results from OS read results, ReadProcessMemory.
Would you recommend using VirtualQuery strictly as a performance hint to skip obviously invalid regions, while relying entirely on ReadProcessMemory (with recovery logic) for correctness?
Thanks again for your guidance!
Best regards,
Dheeraj Kumar Thota
To view this discussion visit https://groups.google.com/d/msgid/dart-gsoc/0e7eacf2-2597-403f-9984-7d31ba925e52n%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dart-gsoc/f81fd428-489a-4764-82a9-aa2cd0bc2b46n%40googlegroups.com.