| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 64c89d2 commit 9e41032
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -272,6 +272,9 @@ void MarkGarbageCollectionEnd(Isolate* isolate, | |||
| 272 | 272 | v8::GCCallbackFlags flags, | |
| 273 | 273 | void* data) { | |
| 274 | 274 | Environment* env = static_cast<Environment*>(data); | |
| 275 | + // If no one is listening to gc performance entries, do not create them. | ||
| 276 | + if (!env->performance_state()->observers[NODE_PERFORMANCE_ENTRY_TYPE_GC]) | ||
| 277 | + return; | ||
| 275 | 278 | GCPerformanceEntry* entry = | |
| 276 | 279 | new GCPerformanceEntry(env, | |
| 277 | 280 | static_cast<PerformanceGCKind>(type), | |
| Back | FazBrowse Home | New Git URL |
0 commit comments