| 801 | } |
| 802 | |
| 803 | void writeNativeLibraries(Buffer* buf) { |
| 804 | if (_recorded_lib_count < 0) return; |
| 805 | |
| 806 | Profiler* profiler = Profiler::instance(); |
| 807 | CodeCacheArray& native_libs = profiler->_native_libs; |
| 808 | int native_lib_count = native_libs.count(); |
| 809 | |
| 810 | for (int i = _recorded_lib_count; i < native_lib_count; i++) { |
| 811 | flushIfNeeded(buf, RECORDING_BUFFER_LIMIT - MAX_STRING_LENGTH); |
| 812 | int start = buf->skip(5); |
| 813 | buf->put8(T_NATIVE_LIBRARY); |
| 814 | buf->putVar64(_start_ticks); |
| 815 | buf->putUtf8(native_libs[i]->name()); |
| 816 | buf->putVar64((uintptr_t) native_libs[i]->minAddress()); |
| 817 | buf->putVar64((uintptr_t) native_libs[i]->maxAddress()); |
| 818 | buf->putVar32(start, buf->offset() - start); |
| 819 | } |
| 820 | |
| 821 | _recorded_lib_count = native_lib_count; |
| 822 | } |
| 823 | |
| 824 | void writeCpool(Buffer* buf) { |
| 825 | buf->skip(5); // size will be patched later |
nothing calls this directly
no test coverage detected