These will generally be used by backends and simply passed through the frontend/midend, so not much is needed here.
Perhaps some frontend passes (in particular, DoSimplifyControlFlow in frontends/p4/simplify.cpp) could be extended to understand these -- currently, any annotations on a block will inhibit combining the blocks, whereas @likely/@unlikely on a block should not inhibit combining it with a block with no annotation (the annotation should be on the resulting combined block).
These will generally be used by backends and simply passed through the frontend/midend, so not much is needed here.
Perhaps some frontend passes (in particular, DoSimplifyControlFlow in frontends/p4/simplify.cpp) could be extended to understand these -- currently, any annotations on a block will inhibit combining the blocks, whereas
@likely
/@unlikely
on a block should not inhibit combining it with a block with no annotation (the annotation should be on the resulting combined block).See discussion in https://github.com/p4lang/p4-spec/issues/1308