MCPcopy Create free account
hub / github.com/facebook/react / js_perf_counters_init

Function js_perf_counters_init

scripts/perf-counters/src/jsc-perf.cpp:79–95  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77}
78
79static JSValueRef js_perf_counters_init(
80 JSContextRef context,
81 JSObjectRef object,
82 JSObjectRef thisObject,
83 size_t argumentCount,
84 const JSValueRef arguments[],
85 JSValueRef *exception
86) {
87 // TODO: Allow customizing recorded events
88 bool enable = true;
89 std::string events = "";
90 bool recordSubprocesses = false;
91 HardwareCounter::Init(enable, events, recordSubprocesses);
92 HardwareCounter::s_counter.getCheck();
93
94 return JSValueMakeUndefined(context);
95}
96
97static JSValueRef js_perf_counters_get_counters(
98 JSContextRef context,

Callers

nothing calls this directly

Calls 2

InitFunction · 0.85
getCheckMethod · 0.45

Tested by

no test coverage detected