You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While porting the canvas package to NAPI, I found the canvas code calls Nan::AdjustExternalMemory() in a few places, to give some hints to the V8 GC. That NAN API is a wrapper around v8::Isolate::AdjustAmountOfExternalAllocatedMemory(). It's not critical for the functionality, but I assume it improves GC behavior significantly when working with large amounts of externally-allocated memory (image buffers in the case of canvas).
This is a V8-specific API; JSRT does not appear to have an equivalent. Do we need to expose it in NAPI? Possibly it could be implemented as a no-op on other engines.
The text was updated successfully, but these errors were encountered:
While porting the canvas package to NAPI, I found the canvas code calls
Nan::AdjustExternalMemory()
in a few places, to give some hints to the V8 GC. That NAN API is a wrapper aroundv8::Isolate::AdjustAmountOfExternalAllocatedMemory()
. It's not critical for the functionality, but I assume it improves GC behavior significantly when working with large amounts of externally-allocated memory (image buffers in the case of canvas).This is a V8-specific API; JSRT does not appear to have an equivalent. Do we need to expose it in NAPI? Possibly it could be implemented as a no-op on other engines.
The text was updated successfully, but these errors were encountered: