Hi Ilya, On Tue, Oct 10, 2023 at 1:49 PM Ilya Leoshkevich <iii@xxxxxxxxxxxxx> wrote: > [...] > > > > Thanks, > > Song > > > > PS: the root image from the CI is not easy to use. Hopefully you > > have something better than that. > > Hi, > > Thanks for posting the analysis and links to the artifacts, that saved > me quite some time. The crash is caused by a backchain issue in the > trampoline code and has nothing to do with your patch; I've posted the > fix here [1]. Thanks for the fix! Song > > The difference between compilers is most likely caused by different > inlining decisions around lookup_elem_raw(). When it's inlined, the > test becomes a no-op. > > Regarding GDB, Debian and Ubuntu have gdb-multiarch package. On Fedora > one has to build it from source; the magic binutils-gdb configure flag > is --enable-targets=all. > > Regarding the development environment, in this case I've sidestepped > the need for a proper image by putting everything into initramfs: > > workdir=$(mktemp -d) > tar -C "$workdir" -xf libbpf-vmtest-rootfs-2022.10.23-bullseye- > s390x.tar.zst > rsync -a selftests "$workdir" > (cd "$workdir" && find . | cpio -o --format=newc -R root:root) > >initrd.cpio > qemu-system-s390x -accel kvm -smp 2 -m 4G -kernel kbuild- > output/arch/s390/boot/bzImage -nographic -append 'nokaslr console=ttyS1 > rdinit=/bin/sh' -initrd initrd.cpio -s Nice trick! > For the regular development I have a different setup, with a > non-minimal Debian install inside the guest, and the testcases mounted > from the host using 9p. > > Best regards, > Ilya > > [1] > https://lore.kernel.org/bpf/20231010203512.385819-1-iii@xxxxxxxxxxxxx/