This PR tries to make the merge() step in the pipeline more efficient (and also the execute() step a bit).
The most drastic (and functional) change is that I tried removing the condition-mechanism in Searcher. It seems to me like we might as well always "use :skip"? In that case the searcher will try to avoid skipping anyway and only skip if necessary. The only effect of the condition-mechanism is that if we don't skip when find_execute_key() is called in Runner.merge() then we're not allowed to skip in Runner.execute(). I can't actually come up with a situation where this would be the case.
Benchmark: I ran 20000.times { pipeline } with both versions, feeding them touchpad events that I had recorded for a couple of hours. The results show a ~10% speedup.
This PR tries to make the
merge()
step in the pipeline more efficient (and also theexecute()
step a bit).The most drastic (and functional) change is that I tried removing the condition-mechanism in
Searcher
. It seems to me like we might as well always "use:skip
"? In that case the searcher will try to avoid skipping anyway and only skip if necessary. The only effect of the condition-mechanism is that if we don't skip whenfind_execute_key()
is called inRunner.merge()
then we're not allowed to skip inRunner.execute()
. I can't actually come up with a situation where this would be the case.Benchmark: I ran
20000.times { pipeline }
with both versions, feeding them touchpad events that I had recorded for a couple of hours. The results show a ~10% speedup.