Gets or creates a unique heap ID for an allocation.
String getHeapId(String typeName, int offset) { final key = '$typeName@$offset'; return _heapIds.putIfAbsent(key, () => '$typeName#${_heapCounter++}'); }