RFR: 8349146: [REDO] Implement a better allocator for downcalls [v8]

Shaojin Wen swen at openjdk.org
Fri May 2 11:58:50 UTC 2025


On Fri, 2 May 2025 11:47:15 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

>> Also, not a big fan of records here -- it seems that many implementation details such as cleanup action, lock and slicing allocator are "leaked out" to the caller, that is now responsible to set things up correctly. I think a `PerThread` class with a constructor taking arena, size, alignment would make the code less coupled and more readable.
>
> And, if you do that, you then don't need the `of` factory -- clients can just use `new`

> any reason why you didn't use a lambda here?

I also think that CleanupAction should be changed to lambda

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/24829#discussion_r2071508856


More information about the core-libs-dev mailing list