From bcdd228f90b3e9e428b584814e7d52627616456a Mon Sep 17 00:00:00 2001 From: James M Snell Date: Mon, 7 Jan 2019 11:36:35 -0800 Subject: perf_hooks: implement histogram based api Add a sampling-based event loop delay monitor. ```js const { monitorEventLoopDelay } = require('perf_hooks'); const h = monitorEventLoopDelay(); h.enable(); h.disable(); console.log(h.percentiles); console.log(h.min); console.log(h.max); console.log(h.mean); console.log(h.stddev); console.log(h.percentile(50)); ``` PR-URL: https://github.com/nodejs/node/pull/25378 Reviewed-By: Matteo Collina Reviewed-By: Gireesh Punathil Reviewed-By: Stephen Belanger Reviewed-By: Richard Lau Reviewed-By: Anna Henningsen --- node.gypi | 1 + 1 file changed, 1 insertion(+) (limited to 'node.gypi') diff --git a/node.gypi b/node.gypi index d4b3c9c8d7d..7d6ff06128a 100644 --- a/node.gypi +++ b/node.gypi @@ -233,6 +233,7 @@ [ 'OS=="aix"', { 'defines': [ '_LINUX_SOURCE_COMPAT', + '__STDC_FORMAT_MACROS' ], 'conditions': [ [ 'force_load=="true"', { -- cgit v1.2.3