4 ms·
"Since the Erlang unit tests are in the same files as the implementation, it’s hard to know exactly how many lines long it is. It gets worse since it implements
by hlieberman 11y ago
"Since the Erlang unit tests are in the same files as the implementation, it’s hard to know exactly how many lines long it is. It gets worse since it implements most of MQTT, the D implementation essentially only implements what’s necessary to run the benchmarks."
Benchmarking the entire spec versus only the minimal set is almost certainly part of the problem here. If you want to benchmark implementations against each other, you should probably make sure they implement the same thing!
- atilaneves 11y agoNo, not really. I understand why you'd think that but knowing the MQTT spec and the benchmark, it shouldn't make any difference at all.
- xixi77 11y agoAre you sure about that one? I am thinking about the situation where presence of alternative code paths that never actually get executed can lead to fairly large differences in timings, particularly for tight loops. (At least in computational code; I'd expect it to be much less common for protocol handling benchmarks like these...)
- atilaneves 11y agoPretty sure yeah, I looked at a lot of profiling logs.