RFR: 8300645: Revert julong changes from 8194232 after 8292083

Severin Gehwolf sgehwolf at openjdk.org
Mon Feb 13 19:03:30 UTC 2023


On Mon, 13 Feb 2023 18:15:24 GMT, Ioi Lam <iklam at openjdk.org> wrote:

> Why is this changed from julong to jlong?

Because `GET_CONTAINER_INFO` might log lines such as these (with `-Xlog:os+container=trace`):

Swappiness is: 18446744073709551614

... on systems where for example `swapaccount=0` is being set on the kernel comandline. That is actually `-2`, i.e. `OS_CONTAINER_ERROR`. Which is just very confusing.

That file, `memory.swappiness`, actually contains small numbers (if it exists). So there is really no need to read this in as `julong`. With this change it would print on `swapaccount=0` systems:


Swappiness is: -2


There is really no need to read as `julong`.

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

PR: https://git.openjdk.org/jdk/pull/12166


More information about the hotspot-runtime-dev mailing list