Node: v8::ArrayBuffer::New() without a BackingStore is deprecated in V8 8.0

Created on 18 Nov 2019  路  6Comments  路  Source: nodejs/node

The new API is present in V8 7.9, so we can already migrate to it:

https://github.com/nodejs/node/blob/b551c6570059ede6d5f90a2b4d5234db1f508b52/deps/v8/include/v8.h#L5007-L5043

There is an upstream issue to gather feedback: v8:9908.

C++ V8 Engine buffer

Most helpful comment

@thangktran Yeah, thanks for reporting that :+1:

All 6 comments

I would like to work on this issue.

@thangktran Cool! This is quite C++-heavy, so it helps if you鈥檙e familiar with that. I would recommend starting by looking at ArrayBuffer::New() calls in our C++ code in src/, picking one that uses ArrayBufferCreationMode::kInternalized (that鈥檚 the easier case), and then trying to convert it to the new ArrayBuffer::NewBackingStore()-based API.

If you have any questions or need help getting started, feel free to comment here, or ask the #node-dev channel on Freenode IRC (or to ping me there).

@addaleax Thank you for your suggestion.

EDIT: I figured it out. I'll test it and keep you update.

There appears to be a bug in v8.
I've reported to them https://bugs.chromium.org/p/v8/issues/detail?id=9908

@thangktran Yeah, thanks for reporting that :+1:

Was this page helpful?
0 / 5 - 0 ratings