4 ms·
That's interesting. For 2GB of logs, 17s is somewhat slow but 0.08s seems straight up impossible; what makes ccusage slow and your approach fast?
by stratos123 8mo ago
That's interesting. For 2GB of logs, 17s is somewhat slow but 0.08s seems straight up impossible; what makes ccusage slow and your approach fast?
- hanbu97 8mo agoGood question – the 0.08s is warm cache. First run parses everything in parallel and caches by file mtime (~0.73s vs 17s, about 23x). After that it just loads cached counts, so you only pay for new/changed files (~0.08s vs 17s, 214x). ccusage re-parses from scratch every time with no caching, hence the gap.