Thread (11 messages) flat view 11 messages, 5 authors, 2020-08-12

Re: eBPF CO-RE cross-compilation for 32-bit ARM platforms

From: Jakov Petrina <hidden>
Date: 2020-08-10 07:39:48
Also in: bpf

Hi,

On 07/08/2020 19:23, Jean-Philippe Brucker wrote:
Hi,

[Adding the linux-arm-kernel list on Cc]


It looks like this "__Poly8_t" type is internal to GCC (provided in
arm_neon.h) and clang has its own internals. I managed to reproduce this
with an arm64 allyesconfig kernel (+BTF), but don't know how to fix it at
the moment. Maybe libbpf should generate defines to translate these
intrinsics between clang and gcc? Not very elegant. I'll take another
look next week.
indeed, this has only been present in our arm64 kernel builds but I 
suppose it may surface for different configurations as well. Per 
Andrii's suggestion, I think blacklisting such types during the dump 
would be a safe bet for now.
I don't know if there is a room for improvement regarding your a) and b)
points, as I think the added complexity is inherent to cross-building. But
kernel crashes definitely need to be fixed, as well as the above problem.
If that is the case, I suppose an additional step would be to configure 
the kernel in such a way so that the generated header files result in 
the smallest possible file size, while retaining all structures that we 
require in our eBPF programs.

The kernel crash seems to elude our attempts to reproduce it; it occurs 
only on a target 32-bit platform device, but a reproducible program does 
not crash the kernel in a QEMU ARM environment. When we investigate this 
further we will definitely share our results.
Thanks,
Jean
Thanks,
-- 
Jakov Petrina

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help