RFR: 8330076: [NMT] add/make a mandatory MEMFLAGS argument to family of os::reserve/commit/uncommit memory API
Afshin Zafari
azafari at openjdk.org
Thu Apr 11 16:30:40 UTC 2024
On Thu, 11 Apr 2024 16:06:35 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
> Another idea: To alleviate the need to pass MEMFLAGS all the time, could we have something like a "active MEMFLAGS" state per Thread, and set that stack-based with a XXMark object? That way, one could say at the entrance of Metaspace, for instance, "whatever is allocated under the scope of this function, please mark with mtMetaspace".
Not sure if I understood your idea, the question is if a thread always uses only ONE type of memory and not mix of them? For example, CDS uses both mtClass and mtClassShared. If a Thread has an active MEMFLAG, it has to switch this flag between A and B whenever it uses type A or B.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18745#issuecomment-2050072695
More information about the shenandoah-dev
mailing list