RFR: JDK-8318671: Potential uninitialized uintx value after JDK-8317683
Thomas Stuefe
stuefe at openjdk.org
Tue Oct 24 12:29:39 UTC 2023
On Tue, 24 Oct 2023 10:26:32 GMT, David Holmes <dholmes at openjdk.org> wrote:
> If "omitting value means 'collect'" then why do we not simply set value = (uintx)MemStatAction::collect ? Otherwise what is that message supposed to mean?
We only enter this function if a value for this command had been given (`-XX:CompileCommand=<command>,<method>[,<value>]`). The default case is handled somewhere else (CompilerOracle::parse_from_line).
> Ternary return values are unpleasant.
As, on a general base? You don't like the number three :-) ?
Here, we have to distinguish between:
- not handled, its not a command option that accepts enum strings
- handled, with two variants: handled, had an error, and handled, had no error. Only in the latter case we want to register the command.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16335#discussion_r1370078348
More information about the hotspot-compiler-dev
mailing list