Reduce non-sensical logs

This commit is contained in:
jpirnay
2026-05-20 10:57:46 +02:00
parent 375c73b03b
commit b1908587ee
2 changed files with 12 additions and 0 deletions
+6
View File
@@ -567,6 +567,12 @@ void FontDecompressor::resetStats() { stats = Stats{}; }
void FontDecompressor::logStats(const char* label) {
const uint32_t total = stats.cacheHits + stats.cacheMisses;
// Suppress the block entirely when the decompressor was untouched this phase
// (e.g. an SD-card font page — FontCacheManager early-returns before invoking us).
if (total == 0 && stats.pageBufferBytes == 0 && stats.decompressTimeMs == 0 && stats.getBitmapCalls == 0) {
resetStats();
return;
}
LOG_DBG("FDC", "[%s] hits=%lu misses=%lu (%.1f%% hit rate)", label, stats.cacheHits, stats.cacheMisses,
total > 0 ? 100.0f * stats.cacheHits / total : 0.0f);
LOG_DBG("FDC", "[%s] decompress=%lums groups_accessed=%u", label, stats.decompressTimeMs, stats.uniqueGroupsAccessed);