[v25.x] v8: changing total_allocated_bytes to avoid ABI changes
As noted by @targos in https://github.com/nodejs/node/pull/60429#issuecomment-3547655449, the implementation of total_allocated_bytes changes the ABI. This PR changes original V8 implementation to a version where there's no addition of HeapStatistics::total_allocated_bytes_ to V8's HeapStatistics, and instead we get such values using Isolate::GetTotalAllocatedBytes. This also changes code introduced by https://github.com/nodejs/node/pull/60573 to use this new API on either v8.getHeapStatistics() and Worker::GetHeapStatistics. The goal here is to make total_allocated_bytes back portable to previous versions, but keeping the v8.getHeapStatistics() API stable once users transition from v25 to future versions. It also solves the ABI change introduced by https://github.com/nodejs/node/pull/60429/files
There's also a fix on documentation text with missing . and updating the code snippet to include total_allocated_bytes on output.
Review requested:
- [ ] @nodejs/gyp
- [ ] @nodejs/security-wg
- [ ] @nodejs/v8-update
CI: https://ci.nodejs.org/job/node-test-pull-request/70277/
Hi all, could someone help me trigger CI again, please?
Up
CI: https://ci.nodejs.org/job/node-test-pull-request/70419/
I'm getting permission errors to look what is failing on CI. Probably it already expired. Does any of you have permission to see what's failing?