[jdk8u-dev] RFR: 8230305: Cgroups v2: Container awareness [v2]

Jonathan Dowland jdowland at openjdk.org
Thu Oct 27 10:26:45 UTC 2022


On Wed, 12 Oct 2022 10:35:01 GMT, Jonathan Dowland <jdowland at openjdk.org> wrote:

>> hotspot/src/os/linux/vm/cgroupV1Subsystem_linux.hpp line 103:
>> 
>>> 101:     CgroupV1Controller* _cpuset = NULL;
>>> 102:     CachingCgroupController* _cpu = NULL;
>>> 103:     CgroupV1Controller* _cpuacct = NULL;
>> 
>> For arm32 platform, if the c++ compiler version being used is earlier than 11, then the non-static member initialization will cause compilation failure.
>
> Thanks for pointing this out! I'll investigate how to best address that in this patch series.

I've spent some time trying to understand this issue, and this is my current understanding of it. ARM32 is the circumstance which surfaced the problem, but this is not an ARM32 problem. The syntax here was introduced in C++11. The minimal (GCC) compiler version stated for JDK8u is GCC 4.3, which has only partial, experimental support for C++11. You didn't state what compiler you were using but I'm going to assume it's one in the supported list for jdk8u. What I take from this is, JDK8u can't use all C++11 features, since some of the supported compiler-versions don't have all C++11 features; and in particular this feature.

These lines of code are unchanged in jdk mainline at the moment, however, jdk has moved forward the minimal supported compiler version. I doubt that a fix for this would be received favourably in jdk mainline, so we probably need to address it in jdk8u-dev directly (not via backport).

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

PR: https://git.openjdk.org/jdk8u-dev/pull/127


More information about the jdk8u-dev mailing list