From: Ilya Leoshkevich <iii@linux.ibm.com>
To: "Jose E. Marchesi" <jose.marchesi@oracle.com>
Cc: Daniel Borkmann <daniel@iogearbox.net>,
Alexei Starovoitov <ast@kernel.org>,
bpf@vger.kernel.org, Heiko Carstens <heiko.carstens@de.ibm.com>,
Vasily Gorbik <gor@linux.ibm.com>
Subject: Re: [PATCH bpf-next] selftests/bpf: add bpf-gcc support
Date: Wed, 11 Sep 2019 12:12:00 +0100 [thread overview]
Message-ID: <70986114-761C-425A-B04F-B9B402023BDA@linux.ibm.com> (raw)
In-Reply-To: <8736h3nn6g.fsf@oracle.com>
> Am 11.09.2019 um 11:30 schrieb Jose E. Marchesi <jose.marchesi@oracle.com>:
>
>
> Hi Ilya.
>
> Now that binutils and gcc support for BPF is upstream, make use of it in
> BPF selftests using alu32-like approach. Share as much as possible of
> CFLAGS calculation with clang.
>
> In order to activate the new bpf-gcc support, one needs to configure
> binutils and gcc with --target=bpf and make them available in $PATH. In
> particular, gcc must be installed as `bpf-gcc`, which is the default.
>
> Right now with binutils 25a2915e8dba and gcc r275589 only a handful of
> tests work:
>
> # ./test_progs_bpf_gcc
> Summary: 5/39 PASSED, 1 SKIPPED, 100 FAILED
>
> The reason is that a lot of progs fail to build with the following
> errors:
>
> error: indirect call in function, which are not supported by eBPF
> error: too many function arguments for eBPF
>
> The next step is to understand those issues and fix them.
>
> Will install your patch and take a look.
>
> Maybe GCC is not inlining something it should be inlining, or clang may
> be silently generating callx %reg instructions, or maybe there are bugs
> in my diagnostics... in any case this is useful feedback :)
>
> Thanks!
Hi Jose,
I have realised this morning that I must have missed what you said
yesterday about bpf-helpers.h -- using gcc version of this header clears
a lot of errors, but the remaning ones are more curious. I plan to
post a v2 of this patch today or tomorrow with more details on the
remaining failures.
Thanks!
Ilya
prev parent reply other threads:[~2019-09-11 11:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-10 23:41 [PATCH bpf-next] selftests/bpf: add bpf-gcc support Ilya Leoshkevich
2019-09-11 10:30 ` Jose E. Marchesi
2019-09-11 11:12 ` Ilya Leoshkevich [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=70986114-761C-425A-B04F-B9B402023BDA@linux.ibm.com \
--to=iii@linux.ibm.com \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=gor@linux.ibm.com \
--cc=heiko.carstens@de.ibm.com \
--cc=jose.marchesi@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).