RFR: JDK-8281274: deal with ActiveProcessorCount in os::Linux::print_container_info

David Holmes dholmes at openjdk.java.net
Fri Feb 4 22:10:12 UTC 2022


On Fri, 4 Feb 2022 17:54:25 GMT, Severin Gehwolf <sgehwolf at openjdk.org> wrote:

>> src/hotspot/os/linux/os_linux.cpp line 2178:
>> 
>>> 2176:   if (i > 0) {
>>> 2177:     if (ActiveProcessorCount > 0) {
>>> 2178:       st->print_cr("%d, but overwritten by flag ActiveProcessorCount: %d",
>> 
>> This will print the same number (processor count) twice. I'd suggest to only add a blurb like `" overridden by -XX:ActiveProcessorCount"` in case the flag is set and not print the blurb otherwise.
>
> Asserting the new output in the jtreg test would be good to have too.

This format is fine me with me. You want to see both the container processor count and the actual count being used.

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

PR: https://git.openjdk.java.net/jdk/pull/7354


More information about the hotspot-runtime-dev mailing list