| 547 | } |
| 548 | |
| 549 | void Profiler::tryResetCounters() { |
| 550 | // Reset counters only for non-JFR recording, otherwise resetting may cause missing stack traces for some |
| 551 | // allocation events and skewed incorrect number of samples. |
| 552 | // In JFR recording, each sample is recorded individually, so accumulated counters are not actually used. |
| 553 | if (!_jfr.active()) { |
| 554 | _call_trace_storage.resetCounters(); |
| 555 | } |
| 556 | } |
| 557 | |
| 558 | void Profiler::writeLog(LogLevel level, const char* message) { |
| 559 | _jfr.recordLog(level, message, strlen(message)); |
no test coverage detected