test-buffer-failed-alloc-typed-arrays test failures
Version
22.1.0
Platform
No response
Subsystem
No response
What steps will reproduce the bug?
No response
How often does it reproduce? Is there a required condition?
No response
What is the expected behavior? Why is that the expected behavior?
No response
What do you see instead?
crash on multiple architectures on openSUSE Tumbleweed
[ 327s] not ok 1180 parallel/test-buffer-failed-alloc-typed-arrays [ 327s] --- [ 327s] duration_ms: 45388.77800 [ 327s] severity: crashed [ 327s] exitcode: -9 [ 327s] stack: |- [ 327s] ...
Additional information
No response
It seems to be running out of memory ...
> /usr/bin/time ./node22 test/parallel/test-buffer-failed-alloc-typed-arrays.js
(node:20905) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use `node22 --trace-deprecation ...` to show where the warning was created)
3.30user 9.69system 0:12.93elapsed 100%CPU (0avgtext+0avgdata 19586856maxresident)k
0inputs+0outputs (0major+6511685minor)pagefaults 0swaps
This is a regression.
With nodejs 21.7.2, the test uses only normally expected amount of memory,
/usr/bin/time ./node21 test/parallel/test-buffer-failed-alloc-typed-arrays.js (node:15146) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead. (Use
node21 --trace-deprecation ...to show where the warning was created) 0.05user 0.01system 0:00.07elapsed 100%CPU (0avgtext+0avgdata 53176maxresident)k 0inputs+0outputs (0major+3173minor)pagefaults 0swaps
basically, 20G vs. 50M
https://github.com/nodejs/node/blob/4a54a80aa36dde4019f77ddab3cb419fc77bb90e/test/parallel/test-buffer-failed-alloc-typed-arrays.js#L15
The test tries to allocate a buffer of size 1e10. This used to fail but is now possible after a V8 update.
Looks like changing this to 1e20 will fix this issue and keep the test around.