All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Laight <david.laight.linux@gmail.com>
To: Nicolas Schier <n.schier@fritz.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	mm-commits@vger.kernel.org, thunder.leizhen@huawei.com,
	thomas.weissschuh@linutronix.de, rostedt@goodmis.org,
	pmladek@suse.com, olsajiri@gmail.com, nathan@kernel.org,
	mcgrof@kernel.org, masahiroy@kernel.org, ljs@kernel.org,
	kees@kernel.org, geert@linux-m68k.org, denis.benato@linux.dev,
	chewi@gentoo.org, andrey.grodzovsky@crowdstrike.com,
	abelvesa@kernel.org, jim.cromie@gmail.com
Subject: Re: + kallsyms-increase-marker-density-to-16-1-to-accelerate-lookups-fix.patch added to mm-nonmm-unstable branch
Date: Thu, 15 Oct 2026 19:43:15 +0100	[thread overview]
Message-ID: <20261015194315.518f75d7@pumpkin> (raw)
In-Reply-To: <20261015-curious-spiritual-buzzard-cd9aa8@l-nschier-aarch64>

On Thu, 15 Oct 2026 14:11:28 +0200
Nicolas Schier <n.schier@fritz.com> wrote:

> On Sun, Oct 11, 2026 at 03:44:01PM +0100, David Laight wrote:
> > On Sat, 10 Oct 2026 17:23:40 -0700
> > Andrew Morton <akpm@linux-foundation.org> wrote:
> >   
> > > The patch titled
> > >      Subject: kallsyms: copy constants from __KERNEL__ to user, drop the inclusion
> > > has been added to the -mm mm-nonmm-unstable branch.  Its filename is
> > >      kallsyms-increase-marker-density-to-16-1-to-accelerate-lookups-fix.patch  
> > 
> > There is a problem with the way this change in implemented.
> > Basically the kernel Makefile (etc) only builds scripts/kallsyms if it doesn't exist.  
> 
> Why do you think so?  Kbuild generates 
> $(objtree)/scripts/.kallsyms.o.cmd that should list all included header 
> files and other sources.  If any of them is touched, a rebuild will 
> happen next time the kernel build wants kallsyms binary.  It seems to 
> work exactly that way on my machine.  Or have I overlooked something 
> here?
> 

I've been doing a lot of test build through the kernel makefile.
They definitely weren't doing the correct rebuilds unless I deleted
both vmlinux.o and scripts/kallsyms, I didn't look why.

I wasn't booting the kernel, I just wanted the .S file to link with
a user program that included (most of) kernel/kallsyms.c and
kernel/kallsyms_seltests.c
(I've changed testing to do it differently most of the time.)

I'm nearly ready to submit some patches that speed the 'by name' lookup
by a factor of 12 with 256:1 markers and by 18 with 64:1.
They also reduce the compressed symbol table by about 10k for my 'normal'
kernel.
I've also run the selftests on the .S file from an x86-64 allyesconfig
kernel - don't try that with the current code regardless of the marker
density.

David

      reply	other threads:[~2026-10-15 18:43 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-11  0:23 + kallsyms-increase-marker-density-to-16-1-to-accelerate-lookups-fix.patch added to mm-nonmm-unstable branch Andrew Morton
2026-10-11 14:44 ` David Laight
2026-10-11 15:15   ` Andrew Morton
2026-10-12 10:14     ` David Laight
2026-10-12 22:39       ` jim.cromie
2026-10-13  8:51         ` David Laight
2026-10-15 12:11   ` Nicolas Schier
2026-10-15 18:43     ` David Laight [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261015194315.518f75d7@pumpkin \
    --to=david.laight.linux@gmail.com \
    --cc=abelvesa@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=andrey.grodzovsky@crowdstrike.com \
    --cc=chewi@gentoo.org \
    --cc=denis.benato@linux.dev \
    --cc=geert@linux-m68k.org \
    --cc=jim.cromie@gmail.com \
    --cc=kees@kernel.org \
    --cc=ljs@kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=mm-commits@vger.kernel.org \
    --cc=n.schier@fritz.com \
    --cc=nathan@kernel.org \
    --cc=olsajiri@gmail.com \
    --cc=pmladek@suse.com \
    --cc=rostedt@goodmis.org \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=thunder.leizhen@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.