Skip to content

Commit

Permalink
http2,perf_hooks: perf state using AliasedBuffer
Browse files Browse the repository at this point in the history
This is the portion of be2cbcc that is not in dea44b9.

Update performance_state to use AliasedBuffer and update usage sites.

Backport-PR-URL: #20456
PR-URL: #18300
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
kfarnung authored and MylesBorins committed May 2, 2018
1 parent dcc7f4d commit 9a4bac2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/node_http2.cc
Original file line number Diff line number Diff line change
Expand Up @@ -531,7 +531,8 @@ Http2Session::~Http2Session() {
}

inline bool HasHttp2Observer(Environment* env) {
uint32_t* observers = env->performance_state()->observers;
AliasedBuffer<uint32_t, v8::Uint32Array>& observers =
env->performance_state()->observers;
return observers[performance::NODE_PERFORMANCE_ENTRY_TYPE_HTTP2] != 0;
}

Expand Down

0 comments on commit 9a4bac2

Please sign in to comment.