From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.6 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9F4EFC2D0EF for ; Tue, 31 Mar 2020 19:47:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7445920842 for ; Tue, 31 Mar 2020 19:47:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="d6ldevC9" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727955AbgCaTrU (ORCPT ); Tue, 31 Mar 2020 15:47:20 -0400 Received: from mail-qk1-f195.google.com ([209.85.222.195]:37801 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727768AbgCaTrT (ORCPT ); Tue, 31 Mar 2020 15:47:19 -0400 Received: by mail-qk1-f195.google.com with SMTP id x3so24458911qki.4; Tue, 31 Mar 2020 12:47:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=GFR2ebeelxrsVQaEHaa7H8HXE+7opSWH7ZpASGlERsM=; b=d6ldevC9PQKwwsqzRi0EN6gl2z2VxBKwgrNgIFhrmLCCkWMMQOzTLAprn1kcPZuZ10 XjFbX2SZCT4fSbmuGB3jzdYOZjQZwW5sBw2P3L/jbb+kMuIDsRkMAvqAC1EK90GjznwP kKs+hCV7J508TWxufgCB7rStezN2Chjy5XqJ9vfE2a9oFSNwFIEoCknByW92N7+VRHgD Uwby5nPHwvDQ2fxfs6WZpczVUGOla1Kt8jhdeXaMyurrDKS1c5vVuEQhXmQpsxUlXGjY P0BAEWX3aOtaMWvr7CwjSgnxgCkpFO5oxWBZxZ9ZAYbAA1X19Of7FCxgNwGhOpp7WfPV guRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=GFR2ebeelxrsVQaEHaa7H8HXE+7opSWH7ZpASGlERsM=; b=kCQtwahfduetiH8hDmGzWxo3b/6jQkSqVfDer8qs6tbOpZxxP93z/6vudfAp6PphQD zf2WYQ/tM+rFUQDRYCoQbMMV+SLjijzr5w8b0aU8m9YIkdpqzpzsiOJ2MKeNJvofpBCO c8zX5sfBx51iNNSvGplyOrDqtynvuBU47Bwg21LfIVNOIZkdyKSlq6NMy3M9rtSwyon2 K2NOcf4BZUcgnH8wCQnvdPwYJZuUgNpyiErTznH4dbMLcS6kdAGn/ZZ/J52Lwvq6lXOk iu3eVvbM7LqQ95CP6RCVkTn5OfNUwQfXvSny6kpMzGVVesw6UmSEE5gr+qcbeSlNmAQ5 pfpg== X-Gm-Message-State: ANhLgQ1YD+zxjbCcs5J7LwGA2u2IlA+eKSFBYEwx5Ts+CF9H2zwoBVc0 BhHRkDkiIMI3+idr0dBGSEDmTunX20RPOCEyCHM= X-Google-Smtp-Source: ADFU+vsQeYFXMaujLW5040JH0lik5W1Ur57xYxu1+p18j3/IegQJuXKTpgoGz15sWUV8DbDW4cpOi/iH0bqVmJdwakE= X-Received: by 2002:a37:6411:: with SMTP id y17mr6917618qkb.437.1585684038877; Tue, 31 Mar 2020 12:47:18 -0700 (PDT) MIME-Version: 1.0 References: <60b05d23-6352-b978-3bf7-5a86466bb297@cn.fujitsu.com> <84a70348-62e3-728b-d934-28e902d40fd0@cn.fujitsu.com> <7705ca15-0d63-2e17-b947-51852c196c4b@cn.fujitsu.com> In-Reply-To: <7705ca15-0d63-2e17-b947-51852c196c4b@cn.fujitsu.com> From: Andrii Nakryiko Date: Tue, 31 Mar 2020 12:47:07 -0700 Message-ID: Subject: Re: runqslower build failed on Debian9 To: Liu Yiding Cc: Andrii Nakryiko , "open list:KERNEL SELFTEST FRAMEWORK" , "bpf@vger.kernel.org" , Philip Li Content-Type: text/plain; charset="UTF-8" Sender: bpf-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org On Mon, Mar 30, 2020 at 5:19 PM Liu Yiding wrote: > > > On 3/30/20 2:09 PM, Andrii Nakryiko wrote: > > On 3/29/20 5:48 PM, Liu Yiding wrote: > >> Add attachment. > >> > > > > Your BTF seems to be invalid. It has struct perf_ibs, which has a > > first field `struct pmu pmu` field with valid-looking size of 296 > > bytes, **but** the type that field points to is not a complete `struct > > pmu` definition, but rather just forward declaration. The way it is it > > shouldn't be even compilable, because forward declaration of a struct > > doesn't specify the size of a struct, so compiler should have rejected > > it. So it must be that either DWARF generated by compiler isn't > > correct, or there is DWARF -> BTF conversion bug somewhere. Are you > > using any special DWARF Kconfig settings? Maybe you can share your > > full .config and I might try to repro it on my machine. > > > > >> Are you using any special DWARF Kconfig settings? > > Sorry, i'm a newbie at this. I don't know which settings are related to > DWARF. > > Just search keywords. > > ``` > > liuyd@localhost:~$ cat config-5.6.0-rc5 | grep DWARF > # CONFIG_DEBUG_INFO_DWARF4 is not set > > ``` > > I built attached config on a clear ubuntu machine. Error could be > reproduced. So you are right, there is a conflict between kconfigs. > > > >> Maybe you can share your full .config and I might try to repro it on > my machine. > > Thanks a lot. I attached the broken config. Thanks a lot! I think it's due to DEBUG_INFO_REDUCED which produces not entirely correct DWARF. I'm asking Slava to disable this config when BTF is requested in [0]. [0] https://lore.kernel.org/bpf/CAEf4BzadnfAwfa1D0jZb=01Ou783GpK_U7PAYeEJca-L9kdnVA@mail.gmail.com > > > > But either way, that warning you get is a valid one, it should be > > illegal to have non-pointer forward-declared struct as a type for a > > struct member. > > > >> > >> On 3/30/20 8:46 AM, Liu Yiding wrote: > >>> Something wrong with my smtp and this email missed. > >>> > >>> Send again. > >>> > >>> > >>> On 3/27/20 11:09 AM, Liu Yiding wrote: > >>>> Hi, Andrii. > >>>> > >>>> Thanks for your prompt reply! > >>>> > >>>> Please check attatchment for my_btf.bin. > >>>> > >>>> > >>>> On 3/27/20 4:28 AM, Andrii Nakryiko wrote: > >>>>> Would you be able to share BTF of vmlinux that is used to generate > >>>>> vmlinux.h? Please run in verbose mode: `make V=1` and search for > >>>>> `bpftool btf dump file` command. It should point either to > >>>>> /sys/kernel/btf/vmlinux or some other location, depending on how > >>>>> things are set up on your side. > >>>>> > >>>>> If it's /sys/kernel/btf/vmlinux, you can just `cat > >>>>> /sys/kernel/btf/vmlinux > my_btf.bin`. If it's some other file, > >>>>> easiest would be to just share that file. If not, it's possible to > >>>>> extract .BTF ELF section, let me know if you need help with that. > >>>> > > > > > > > -- > Best Regards. > Liu Yiding > > >