Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bpf: use register liveness information for func_states_equal
Liveness analysis DFA computes a conservative set of registers live before each instruction. Leverage this information to skip comparison of dead registers in func_states_equal(). This helps with convergance of iterator processing loops, as bpf_reg_state->live marks can't be used when loops are processed. This has certain performance impact for selftests, here is a veristat listing for bigger ones: File Program Insns (DIFF) States (DIFF) ---------------------------------- ----------------------------------- ---------------- -------------- iters.bpf.o checkpoint_states_deletion -16636 (-91.81%) -745 (-91.19%) iters.bpf.o iter_nested_deeply_iters -267 (-47.09%) -26 (-41.27%) iters.bpf.o iter_nested_iters -181 (-22.26%) -17 (-21.52%) iters.bpf.o iter_subprog_iters -339 (-33.80%) -24 (-28.92%) iters.bpf.o loop_state_deps2 -349 (-48.14%) -27 (-42.86%) pyperf600_iter.bpf.o on_event -795 (-6.59%) +239 (+65.30%) The pyperf600_iter is curious, as it shows an increase in number of processed states. The reason for this is: <TBD> Signed-off-by: Eduard Zingerman <[email protected]>
- Loading branch information