On Tue, 9 Feb 2021 17:56:15 GMT, Aleksey Shipilev <[email protected]> wrote:
> > There's an existing test that explicitly tests both `-XX:+CompactStrings` > > and `-XX:-CompactStrings`. Maybe we can do the same thing? > > No, I don't think we can. In other tests, the conflict between > `-XX:+CompactStrings` and `-XX:-CompactStrings` would select one of the > modes, so both test configurations would degenerate into one config (run > twice). I tried running `jtreg -vmoptions:-XX:+CompactStrings TestMethodNames.java` and the log file shows: (the first @test) -XX:+CompactStrings \ -XX:+CompactStrings \ com.sun.javatest.regtest.agent.MainWrapper /jdk2/tmp/jtreg/work/runtime/CompactStrings/TestMethodNames.d/main.0.jta (the second @test) -XX:+CompactStrings \ -XX:-CompactStrings \ com.sun.javatest.regtest.agent.MainWrapper /jdk2/tmp/jtreg/work/runtime/CompactStrings/TestMethodNames.d/main.1.jta The VM options specified by the `@test` line are appended after the options specified by `-vmoptions`. So this test is executed in two different configurations (not twice in the same configuration). ------------- PR: https://git.openjdk.java.net/jdk/pull/2355
