On Sat, 30 Dec 2023 17:37:25 GMT, Markus KARG <d...@openjdk.org> wrote:

>> Done. Can we somehow modify the test to make it white-box one? Maybe it's 
>> possible to measure memory allocation before and after method invocation in 
>> the way that we could use the difference as a proof of non-allocating 
>> invocation for trusted OutputStreams?
>
> I assume you mean "to make it a blackbox"? Actually I do not see how we could 
> do that *reliably*, as I already wrote recently.

`com.sun.management.ThreadMXBean#getCurrentThreadAllocatedBytes` is reliable, 
isn't it?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/16879#discussion_r1438666817

Reply via email to