[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1545259460-13376-14-git-send-email-jiong.wang@netronome.com>
Date: Wed, 19 Dec 2018 17:44:20 -0500
From: Jiong Wang <jiong.wang@...ronome.com>
To: ast@...nel.org, daniel@...earbox.net
Cc: netdev@...r.kernel.org, oss-drivers@...ronome.com,
Jiong Wang <jiong.wang@...ronome.com>
Subject: [PATH bpf-next 13/13] selftests: bpf: makefile support sub-register code-gen test mode
Add a new BPF_SELFTEST_32BIT variable to enable sub-register code-gen test
mode. For example:
make BPF_SELFTEST_32BIT=1 -C tools/testing/selftests/bpf run_tests
will compile all bpf C program with sub-register code-gen enabled, ALU32
and JMP32 instructions will be used.
Signed-off-by: Jiong Wang <jiong.wang@...ronome.com>
---
tools/testing/selftests/bpf/Makefile | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests/bpf/Makefile
index 73aa6d8..70bccf6 100644
--- a/tools/testing/selftests/bpf/Makefile
+++ b/tools/testing/selftests/bpf/Makefile
@@ -146,6 +146,10 @@ endif
endif
endif
+ifneq ($(BPF_SELFTEST_32BIT),)
+ LLC_FLAGS += -mattr=alu32
+endif
+
# Have one program compiled without "-target bpf" to test whether libbpf loads
# it successfully
$(OUTPUT)/test_xdp.o: test_xdp.c
--
2.7.4
Powered by blists - more mailing lists