Percona-Lab / query-playback

Query Playback
Other
106 stars 47 forks source link

slowlog: speedup accurate mode #30

Closed undingen closed 7 years ago

undingen commented 7 years ago

This two patches together lower the preparation time for replying a slowlog in accurate mode by about 5x (e.g. one test I did from 1min to 10secs). Most of the speedup comes from caching the thread id. But this adds 8 bytes of additional memory overhead to every query entry - this is why I created the second commit which lowers it by 16 bytes per query so both commits together will lower it by 8 (=32 bytes overhead per query from now on).