mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2025-12-31 20:36:25 +00:00
This is a simple cache that keeps x,y pairs for use when drawing visualizers. To keep this generic, and save on memory, we simply store the x,y coordinates as floats between 0.0 and 1.0. This saves us roughly 50% on each data point over the 2 8-byte numbers we would otherwise store. Obviously, we could take this further and make some fancy index storage with run-length-encode values, but this should work for now and allow us to get more exotic later.