News for hackers. Stuff that matters.
Re:Fast Code Is Easy. Measuring It Is Hard by omgtehlion on Sunday July 06, 2025 @04:30AM (#44478884)
In HFT context (as in the article) measurement is quite easy: you tap incoming and outgoing network fibers and measure this time. Also you can do this in production, as this kind of measurement does not impact latency at all
Re:Fast Code Is Easy. Measuring It Is Hard by dmurray on Sunday July 06, 2025 @07:53AM (#44479926)
The article also touches on some reasons this isn't enough. You might want to test outside of production, you might want to measure the latency when you decide to send no order, and you might want to profile your code at a more granular level than the full lifecycle of market data to order.
Re:Fast Code Is Easy. Measuring It Is Hard by omgtehlion on Sunday July 06, 2025 @10:57AM (#44481297)
All internal parts are usually measured by low-overhead logger (which materializes log messages in a separate thread, and uses rdtsc in the hot path to record timestamps)