Re: [PATCH dwarves 4/4] btf: add support for split BTF loading and encoding

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On November 11, 2020 3:27:58 PM GMT-03:00, Andrii Nakryiko <andrii.nakryiko@xxxxxxxxx> wrote:
>On Wed, Nov 11, 2020 at 3:56 AM Arnaldo Carvalho de Melo
><acme@xxxxxxxxxx> wrote:
>>
>> Em Thu, Nov 05, 2020 at 09:25:49PM -0800, Andrii Nakryiko escreveu:
>> > Add support for generating split BTF, in which there is a
>designated base
>> > BTF, containing a base set of types, and a split BTF, which extends
>main BTF
>> > with extra types, that can reference types and strings from the
>main BTF.
>>
>> > This is going to be used to generate compact BTFs for kernel
>modules, with
>> > vmlinux BTF being a main BTF, which all kernel modules are based
>off of.
>>
>> > These changes rely on patch set [0] to be present in libbpf
>submodule.
>>
>> >   [0]
>https://patchwork.kernel.org/project/netdevbpf/list/?series=377859&state=*
>>
>> So, applied and added this:
>
>Awesome, thanks! Do you plan to release v1.19 soon?

Yes

>
>>
>> diff --git a/man-pages/pahole.1 b/man-pages/pahole.1
>> index 4b5e0a1bf5462b28..20ee91fc911d4b39 100644
>> --- a/man-pages/pahole.1
>> +++ b/man-pages/pahole.1
>> @@ -185,6 +185,10 @@ Do not encode VARs in BTF.
>>  .B \-\-btf_encode_force
>>  Ignore those symbols found invalid when encoding BTF.
>>
>> +.TP
>> +.B \-\-btf_base
>> +Path to the base BTF file, for instance: vmlinux when encoding
>kernel module BTF information.
>> +
>>  .TP
>>  .B \-l, \-\-show_first_biggest_size_base_type_member
>>  Show first biggest size base_type member.
>>
>> ---------------
>>
>> The entry for btf_encode/-J is missing, I'll add in a followup patch.
>>
>> Also I had to fixup ARGP_btf_base to 321 as I added this, to simplify
>> the kernel scripts and Makefiles:
>>
>>   $ pahole --numeric_version
>>   118
>>   $
>
>Oh, this is nice! Can't really use it with Kbuild now due to backwards
>compatibility, but maybe someday.

Well, if it fails with --numeric_version, then it is old and the warning about the minimal version being v1.19 should be emitted :)

- Arnaldo
>
>>
>> Now to test this all by applying the kernel patches and the encoding
>> module BTF, looking at it, etc.
>>
>> - Arnaldo
>>
>
>[...]

-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux