From d38ccbb07fa06072fe44117bb79eebeadeb88a7b Mon Sep 17 00:00:00 2001 From: Anna Henningsen Date: Fri, 23 Mar 2018 15:53:54 +0100 Subject: [PATCH] src: use `unordered_map` for perf marks PR-URL: https://github.com/nodejs/node/pull/19558 Reviewed-By: Colin Ihrig Reviewed-By: Tiancheng "Timothy" Gu Reviewed-By: Trivikram Kamat Reviewed-By: James M Snell --- src/env-inl.h | 3 ++- src/env.h | 5 ++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/env-inl.h b/src/env-inl.h index 2dba28a32653d9..5860c5219696fd 100644 --- a/src/env-inl.h +++ b/src/env-inl.h @@ -526,7 +526,8 @@ inline performance::performance_state* Environment::performance_state() { return performance_state_.get(); } -inline std::map* Environment::performance_marks() { +inline std::unordered_map* + Environment::performance_marks() { return &performance_marks_; } diff --git a/src/env.h b/src/env.h index 2449cf31777b59..3f831e02a060ac 100644 --- a/src/env.h +++ b/src/env.h @@ -38,7 +38,6 @@ #include "node_http2_state.h" #include -#include #include #include #include @@ -625,7 +624,7 @@ class Environment { inline AliasedBuffer& scheduled_immediate_count(); inline performance::performance_state* performance_state(); - inline std::map* performance_marks(); + inline std::unordered_map* performance_marks(); inline void ThrowError(const char* errmsg); inline void ThrowTypeError(const char* errmsg); @@ -731,7 +730,7 @@ class Environment { AliasedBuffer scheduled_immediate_count_; std::unique_ptr performance_state_; - std::map performance_marks_; + std::unordered_map performance_marks_; #if HAVE_INSPECTOR std::unique_ptr inspector_agent_;