summaryrefslogtreecommitdiff
path: root/node.gyp
diff options
context:
space:
mode:
authorMike Kaufman <mike.kaufman@microsoft.com>2017-08-25 12:45:00 -0700
committerAnna Henningsen <anna@addaleax.net>2017-09-13 17:44:24 +0200
commit35a526c1d4702d54c464510f448879f096a97321 (patch)
treed5147ecaf5e86bc429af38f01d994d4b2edd5fdf /node.gyp
parent2ac7b433b42dd44b319e1113e045dda8df20a4f8 (diff)
downloadnode-new-35a526c1d4702d54c464510f448879f096a97321.tar.gz
http2,async-wrap: introduce AliasedBuffer class
This change introduces an AliasedBuffer class and updates asytnc-wrap and http2 to use this class. A common technique to optimize performance is to create a native buffer and then map that native buffer to user space via JS array. The runtime can efficiently write to the native buffer without having to route though JS, and the values being written are accessible from user space. While efficient, this technique allows modifications to user space memory w/out going through JS type system APIs, effectively bypassing any monitoring the JS VM has in place to track program state modifications. The result is that monitors have an incorrect view of prorgram state. The AliasedBuffer class provides a future placeholder where this technique can be used, but writes can still be observed. To achieve this, the node-chakra-core fork will add in appropriate tracking logic in the AliasedBuffer's SetValue() method. Going forward, this class can evolve to support more sophisticated mechanisms if necessary. PR-URL: https://github.com/nodejs/node/pull/15077 Reviewed-By: Trevor Norris <trev.norris@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'node.gyp')
-rw-r--r--node.gyp4
1 files changed, 4 insertions, 0 deletions
diff --git a/node.gyp b/node.gyp
index 79d9e0a68d..17f2356414 100644
--- a/node.gyp
+++ b/node.gyp
@@ -228,6 +228,7 @@
'src/util.cc',
'src/uv.cc',
# headers to make for a more pleasant IDE experience
+ 'src/aliased_buffer.h',
'src/async-wrap.h',
'src/async-wrap-inl.h',
'src/base-object.h',
@@ -246,6 +247,7 @@
'src/node_constants.h',
'src/node_debug_options.h',
'src/node_http2.h',
+ 'src/node_http2_state.h',
'src/node_internals.h',
'src/node_javascript.h',
'src/node_mutex.h',
@@ -650,6 +652,8 @@
'sources': [
'src/node_platform.cc',
'src/node_platform.h',
+ 'test/cctest/node_test_fixture.cc',
+ 'test/cctest/test_aliased_buffer.cc',
'test/cctest/test_base64.cc',
'test/cctest/test_environment.cc',
'test/cctest/test_util.cc',