Skip to content

[v8.x] Fix abi break

This addresses the inadvertent ABI-incompatible change in #21269. The first commit reverts the ABI breaking part of d868eb78. Unfortunately doing so will may reintroduce a memory bug (#21021 (closed)). This is where the second commit adds back the functionality in an ABI-safe way and then uses it from within core.

Native modules that use AdjustAmountOfExternalAllocatedMemory may still miss the CheckMemoryPressure path. This is unfortunate, but there is no easy way to do so in an ABI compatible way. Going forward, it would be good if V8 was to avoid implementation in the v8.h file as that can lead to ABI issues like this where we can't fix the memory issue in an ABI compatible way. Such modules can use the 8.x specific AdjustAmountOfExternalAllocatedMemoryCustom, but would require a recompilation.

  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

CI: https://ci.nodejs.org/job/node-test-pull-request/18778/ V8-CI: https://ci.nodejs.org/view/All/job/node-test-commit-v8-linux/1887/

Merge request reports

Loading