On Fri, Aug 2, 2024 at 3:54 AM Thomas Weißschuh <linux@xxxxxxxxxxxxxx> wrote: > > On 2024-08-01 11:36:37+0000, Nathan Chancellor wrote: > > Hi Jose, > > > > On Thu, Aug 01, 2024 at 07:29:40AM -0600, Jose Fernandez wrote: > > > Add a new -debug package to the pacman PKGBUILD that will contain the > > > vmlinux image for debugging purposes. This package depends on the > > > -headers package and will be installed in /usr/src/debug/${pkgbase}. > > > > > > The vmlinux image is needed to debug core dumps with tools like crash. > > > > > > Signed-off-by: Jose Fernandez <jose.fernandez@xxxxxxxxx> > > > Reviewed-by: Peter Jung <ptr1337@xxxxxxxxxxx> > > > > This appears to add a non-trivial amount of time to the build when benchmarking > > with Arch Linux's configuration (I measure 9% with hyperfine): > > As nothing more is compiled, I guess this is just the additional > packaging. > > > Benchmark 1: pacman-pkg @ 21b136cc63d2 ("minmax: fix up min3() and max3() too") > > Time (mean ± σ): 579.541 s ± 0.585 s [User: 22156.731 s, System: 3681.698 s] > > Range (min … max): 578.894 s … 580.033 s 3 runs > > > > Benchmark 2: pacman-pkg @ c5af4db0563b ("kbuild: add debug package to pacman PKGBUILD") > > Time (mean ± σ): 633.419 s ± 0.972 s [User: 22247.886 s, System: 3673.879 s] > > Range (min … max): 632.302 s … 634.070 s 3 runs > > > > Summary > > pacman-pkg @ 21b136cc63d2 ("minmax: fix up min3() and max3() too") ran > > 1.09 ± 0.00 times faster than pacman-pkg @ c5af4db0563b ("kbuild: add debug package to pacman PKGBUILD") > > > > It would be nice to add some option to avoid building this package for > > developers who may not want it (I know I personally would not want it > > with that penalty because I do a lot of bisects) or maybe adding a > > target to build this package with the rest like 'pacman-pkg-with-dbg' or > > something? Also, couldn't vmlinux be obtained from vmlinuz that already > > exists in the main package via scripts/extract-vmlinux? > > Jose: > > In the vanilla PKGBUILD vmlinux is part of the linux-headers package: > linux-headers /usr/lib/modules/6.10.2-arch1-1/build/vmlinux > > Given that you already gate the new -debug package on CONFIG_MODULES, > why not add the file to that package? I do not know why CONFIG_MODULES controls the debug package. If this is really for debugging purposes, CONFIG_DEBUG_INFO is more suitable. Without CONFIG_DEBUG_INFO, vmlinux contains only limited amount of information. scripts/package/mkdebian use CONFIG_DEBUG_INFO to enable the debug package. -- Best Regards Masahiro Yamada