Mark `allocate_new_tlab` and `unsafe_max_tlab_alloc` of `CollectedHeap` as `pure virtual`

Guoxiong Li lgxbslgx at gmail.com
Thu Mar 21 07:22:06 UTC 2024


Hi all,

I noticed the methods `CollectedHeap::allocate_new_tlab` and
`CollectedHeap::unsafe_max_tlab_alloc` only have the statement
`guarantee(false, ...)`.
They are never run and overridden by subclasses.
Should we mark them as `pure virtual` instead of giving an implementation?

I am going to submit a patch to change them.
But it is good to discuss it firstly and avoid the unnecessary ticket and
PR.

Any ideas are appreciated. Thanks.


Best Regards,
-- Guoxiong
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/hotspot-gc-dev/attachments/20240321/39dc3c85/attachment.htm>


More information about the hotspot-gc-dev mailing list