RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]
Vladimir Kozlov
kvn at openjdk.org
Wed Apr 3 20:03:11 UTC 2024
On Wed, 3 Apr 2024 17:55:38 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:
>> No, `CodeCache::blob_count()` uses different macro `FOR_ALL_HEAPS(heap)` because it looks for all code blobs, not only nmethods.
>>
>> `CodeCache::nmethod_count()` is the only place where `FOR_ALL_NMETHOD_HEAPS ` was used. So I decided to remove the macro.
>
> I didn't say that blob_count used `FOR_ALL_NMETHODS_HEAP`. I wrote "one of these macros". I still think this adds an inconsistency to the code that I don't think is beneficial.
>
> With that said, can't this be written as:
>
> for (CodeHeap* heap : *_nmethod_heaps) {
>
>
> Maybe yet another opportunity for cleanups.
I like it and will do it in JDK-8329628.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/18554#discussion_r1550378690
More information about the serviceability-dev
mailing list