[crac] RFR: 8371337: [CRaC] Fastdebug build fails when calling OperatingSystemMxBean.getProcessCpuLoad after restore
Radim Vansa
rvansa at openjdk.org
Wed Nov 5 12:28:34 UTC 2025
A JVM that executed OperatingSystemImpl.getProcessCpuLoad() before checkpoint can fail with assertion failure after restore with:
java: /home/rvansa/work/zulu/src/jdk.management/linux/native/libmanagement_ext/UnixOperatingSystem.c:291: get_cpuload_internal: Assertion `pticks->usedKernel >= tmp.usedKernel' failed.
This is an assertion failure, therefore failing only in debug builds, and providing probably a non-sense value in release builds. We should remove the assertion and return a negative value (documented as value for ‘unavailable’) if this is detected.
-------------
Commit messages:
- 8371337: [CRaC] Fastdebug build fails when calling OperatingSystemMxBean.getProcessCpuLoad after restore
Changes: https://git.openjdk.org/crac/pull/274/files
Webrev: https://webrevs.openjdk.org/?repo=crac&pr=274&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8371337
Stats: 65 lines in 2 files changed: 62 ins; 3 del; 0 mod
Patch: https://git.openjdk.org/crac/pull/274.diff
Fetch: git fetch https://git.openjdk.org/crac.git pull/274/head:pull/274
PR: https://git.openjdk.org/crac/pull/274
More information about the crac-dev
mailing list