On Fri, May 24, 2019 at 12:35:15PM +0100, Jiong Wang wrote: > x86_64 and AArch64 perhaps are two arches that running bpf testsuite > frequently, however the zero extension insertion pass is not enabled for > them because of their hardware support. > > It is critical to guarantee the pass correction as it is supposed to be > enabled at default for a couple of other arches, for example PowerPC, > SPARC, arm, NFP etc. Therefore, it would be very useful if there is a way > to test this pass on for example x86_64. > > The test methodology employed by this set is "poisoning" useless bits. High > 32-bit of a definition is randomized if it is identified as not used by any > later insn. Such randomization is only enabled under testing mode which is > gated by the new bpf prog load flags "BPF_F_TEST_RND_HI32". > > Suggested-by: Alexei Starovoitov <ast@xxxxxxxxxx> > Signed-off-by: Jiong Wang <jiong.wang@xxxxxxxxxxxxx> > --- > include/uapi/linux/bpf.h | 18 ++++++++++++++++++ > kernel/bpf/syscall.c | 4 +++- > tools/include/uapi/linux/bpf.h | 18 ++++++++++++++++++ > 3 files changed, 39 insertions(+), 1 deletion(-) one more nit: could you please split this patch into two? Our mostly automatic sync of kernel/libbpf into github/libbpf will fail when tools/../bpf.h is not a separate commit.