diff options
author | Eduard Zingerman <eddyz87@gmail.com> | 2023-10-24 03:09:16 +0300 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2023-10-24 07:49:32 +0300 |
commit | 64870feebecb7130291a55caf0ce839a87405a70 (patch) | |
tree | ccce1bb46ed7a2690431d43bdf0563d00c4e6249 /drivers | |
parent | 2a0992829ea3864939d917a5c7b48be6629c6217 (diff) | |
download | linux-64870feebecb7130291a55caf0ce839a87405a70.tar.xz |
selftests/bpf: test if state loops are detected in a tricky case
A convoluted test case for iterators convergence logic that
demonstrates that states with branch count equal to 0 might still be
a part of not completely explored loop.
E.g. consider the following state diagram:
initial Here state 'succ' was processed first,
| it was eventually tracked to produce a
V state identical to 'hdr'.
.---------> hdr All branches from 'succ' had been explored
| | and thus 'succ' has its .branches == 0.
| V
| .------... Suppose states 'cur' and 'succ' correspond
| | | to the same instruction + callsites.
| V V In such case it is necessary to check
| ... ... whether 'succ' and 'cur' are identical.
| | | If 'succ' and 'cur' are a part of the same loop
| V V they have to be compared exactly.
| succ <- cur
| |
| V
| ...
| |
'----'
Signed-off-by: Eduard Zingerman <eddyz87@gmail.com>
Link: https://lore.kernel.org/r/20231024000917.12153-7-eddyz87@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'drivers')
0 files changed, 0 insertions, 0 deletions