On Thu, 30 Mar 2023 17:11:33 GMT, Serguei Spitsyn <[email protected]> wrote:
>> test/hotspot/jtreg/serviceability/jvmti/vthread/ToggleNotifyJvmtiTest/ToggleNotifyJvmtiTest.java
>> line 157:
>>
>>> 155:
>>> 156: if (args.length > 0 && args[0].equals("attach")) { // agent
>>> loaded into running VM case
>>> 157: String arg = args.length == 2 ? args[1] : "";
>>
>> I don't see any args being passed in other than "attach"? What might `arg`
>> be set to?
>
> Only "attach" can be passed in args.
So if args[0] is "attach", then arg will always be set to "attach", which
means it could be passed in as a literal to loadAgentLibrary() below. But even
that doesn't seem to be necessary since the agent doesn't seem to look at the
args passed in.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/13133#discussion_r1153836810