RFR: JDK-8320061: [nmt] Multiple issues with peak accounting
Thomas Stuefe
stuefe at openjdk.org
Fri Nov 24 16:15:06 UTC 2023
On Fri, 24 Nov 2023 15:23:22 GMT, Johan Sjölen <jsjolen at openjdk.org> wrote:
> Splitting this up into multiple loops would simplify the code significantly imho, no need for two boolean flags for a start.
If verbose=true, we print the haystack, with pattern matches marked. Your version omits printing for all lines until a needle is found, and only prints from the second needle on. Meaning, if the first pattern does not match, we don't see output. Arguably, that is the point where you need the output for test analysis.
Okay, I can give it a try.
> Also, what does the !verbose check do exactly? Doesn't seem like it would be print twice without it, to me.
If an error happened, we print diagnostic summary (which mimics the behavior of all other "shouldBlaBla()" functions). So, we print twice if we run with verbose and run into an error.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16675#discussion_r1404502525
More information about the hotspot-runtime-dev
mailing list