NMT and adjacent reserved regions

Thomas Stüfe thomas.stuefe at gmail.com
Thu May 14 17:15:21 UTC 2020


On Thu, May 14, 2020 at 7:06 PM Zhengyu Gu <zgu at redhat.com> wrote:

> >     Hi Thomas,
> >
> >     IIRC, we do intend to collapse neighboring reserved regions, iff
> >
> >     1) same memory type
> >     2) same allocation site
> >
> >
> > Hm okay. Something to keep in mind when splitting memory regions. My
> > original plan was to split the underlying NMT region into two, with both
> > keeping the original stack + flags. I guess I have to avoid doing that.
> >
> > Thinking about this I am not sure collapsing is worth the trouble
> > though. Lets say I were to reserve two regions with mtInternal, but the
> > reservation calls are hidden in deep call stacks, the call stacks would
> > be identical and look like the same allocation site to NMT, right? So it
> > could happen that two reservations are collapsed and the caller is not
> > aware of that. So, I later could not re-assign different flags to those
> > regions.
> >
> An option: not collapsing reserved regions internally, but collapsing
> them at reporting time?
>
> -Zhengyu
>
>
Good idea, that could work.

So separately reserved regions stay separated, as it is now by accident?
Then I can proceed as planned for the NMT patch for
os::split_reserved_memory.

And later we fix the detailed printer in a separate RFE.

Thanks, Thomas


More information about the hotspot-runtime-dev mailing list