On 12/13/2018 07:52 PM, Jakub Kicinski wrote:
> On Thu, 13 Dec 2018 16:17:37 +0100, Daniel Borkmann wrote:
>> Could we rather extend the test_verifier infrastructure in order to
>> be able to define data input for bpf_prog_test_run()? I think this
>> would be very useful for future tests there as well and avoid having
>> to duplicate or split functionality into test_progs.c instead.
> 
> No strong feelings but if it's called test_verifier, and the sample puts
> no stress on the verifier it feels weird to put it there..  But okay, I
> will respin.. at some point :)

Well, test_verifier is running every program that passes the verifier
via bpf_prog_test_run() anyway to increase test coverage also for JIT
and runtime rather than just plain verification itself. In that sense
it includes testing what verifier has been rewritten, for example. I
just noticed we already have this feature via 93731ef086ce ("bpf:
migrate ebpf ld_abs/ld_ind tests to test_verifier"). ;-) So just adding
the test code there should suffice.

Reply via email to