RFR: 8372135: clang compilation error

Jan Kratochvil jkratochvil at openjdk.org
Wed Nov 19 08:08:25 UTC 2025


clang-20.1.8-4.fc42.x86_64

src/hotspot/os/linux/cgroupV1Subsystem_linux.hpp:212:10: error: 'is_containerized' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
  212 |     bool is_containerized();
      |          ^       
src/hotspot/os/linux/cgroupSubsystem_linux.hpp:284:18: note: overridden virtual function is here
  284 |     virtual bool is_containerized() = 0;
      |                  ^
In file included from src/hotspot/os/linux/cgroupSubsystem_linux.cpp:27:
src/hotspot/os/linux/cgroupV1Subsystem_linux.hpp:214:18: error: 'container_type' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
  214 |     const char * container_type() {
      |                  ^
src/hotspot/os/linux/cgroupSubsystem_linux.hpp:288:26: note: overridden virtual function is here
  288 |     virtual const char * container_type() = 0;
      |                          ^
In file included from src/hotspot/os/linux/cgroupSubsystem_linux.cpp:27:
src/hotspot/os/linux/cgroupV1Subsystem_linux.hpp:217:54: error: 'memory_controller' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
  217 |     CachingCgroupController<CgroupMemoryController>* memory_controller() { return _memory; }
      |                                                      ^
src/hotspot/os/linux/cgroupSubsystem_linux.hpp:289:62: note: overridden virtual function is here
  289 |     virtual CachingCgroupController<CgroupMemoryController>* memory_controller() = 0;
      |                                                              ^
In file included from src/hotspot/os/linux/cgroupSubsystem_linux.cpp:27:
src/hotspot/os/linux/cgroupV1Subsystem_linux.hpp:218:51: error: 'cpu_controller' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
  218 |     CachingCgroupController<CgroupCpuController>* cpu_controller() { return _cpu; }
      |                                                   ^
src/hotspot/os/linux/cgroupSubsystem_linux.hpp:290:59: note: overridden virtual function is here
  290 |     virtual CachingCgroupController<CgroupCpuController>* cpu_controller() = 0;
      |                                                           ^
In file included from src/hotspot/os/linux/cgroupSubsystem_linux.cpp:27:
src/hotspot/os/linux/cgroupV1Subsystem_linux.hpp:219:30: error: 'cpuacct_controller' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override  219 |     CgroupCpuacctController* cpuacct_controller() { return _cpuacct; }
      |                              ^
src/hotspot/os/linux/cgroupSubsystem_linux.hpp:291:38: note: overridden virtual function is here
  291 |     virtual CgroupCpuacctController* cpuacct_controller() = 0;
      |                                      ^
5 errors generated.                          
gmake[3]: *** [lib/CompileJvm.gmk:180: build/fastdebug-default-clang/hotspot/variant-server/libjvm/objs/cgroupSubsystem_linux.o] Error 1

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

Commit messages:
 - 8372135: clang compilation error

Changes: https://git.openjdk.org/jdk/pull/28384/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=28384&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8372135
  Stats: 5 lines in 1 file changed: 0 ins; 0 del; 5 mod
  Patch: https://git.openjdk.org/jdk/pull/28384.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/28384/head:pull/28384

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


More information about the hotspot-runtime-dev mailing list