[DTrace-devel] [PATCH 0/2 v6.12-rc1] CTF rework to work with modules.builtin.ranges

Nick Alcock nick.alcock at oracle.com
Tue Oct 1 17:12:50 UTC 2024


This rework (against 6.12-rc1) makes CTF work without any of Luis's
modules.builtin.objs patches.  For now, for ease of review, it's atop the
existing series -- obviously after review I'll squash it back into the
appropriate commits, so no sign of modules.builtin.objs remains.

We also fix the unfortunate problem whereby make ctf repeatedly rebuilds the
kernel every time it's done, and the bug causing a.out to get left in the
build tree. (And we also fix libctf detection with ld.lld, though it still
doesn't check that $(LD) can actually *deduplicate* CTF, so it'll misfire if
ld.lld and GCC are used together. In time I hope this will be fixed when
ld.lld gains the ability to dedup CTFv4, but that's waiting on the FSF
license people. For now, affected users can just override CONFIG_CTF's
defaults.)

The patch is much shorter than it seems, because the renaming of
modules_builtin.c to module_objnames.c confused git's rename detection: in
fact, the one file was renamed to the other and a bunch of code was removed
at the same time.

Pushed to nix/6.12-rc1/ctf-rejig on ca-tools4 dtrace-kernel.

Nick Alcock (2):
  ctf: rejig with better builtin object detection
  ctf: fix config test

 init/Kconfig                                  |   2 +-
 scripts/Makefile.ctfa                         |   2 +-
 scripts/Makefile.ctfa-toplevel                |  41 ++--
 scripts/ctf-module-objnames.sh                |  35 +++
 scripts/ctf/Makefile                          |   2 +-
 scripts/ctf/ctfarchive.c                      |  14 +-
 .../{modules_builtin.c => module_objnames.c}  |   2 +-
 .../{modules_builtin.h => module_objnames.h}  |   2 +-
 scripts/module_objnames.c                     | 160 ++++++++++++++
 .../{modules_builtin.h => module_objnames.h}  |  20 +-
 scripts/modules_builtin.c                     | 200 ------------------
 11 files changed, 236 insertions(+), 244 deletions(-)
 create mode 100755 scripts/ctf-module-objnames.sh
 rename scripts/ctf/{modules_builtin.c => module_objnames.c} (54%)
 rename scripts/ctf/{modules_builtin.h => module_objnames.h} (54%)
 create mode 100644 scripts/module_objnames.c
 rename scripts/{modules_builtin.h => module_objnames.h} (64%)
 delete mode 100644 scripts/modules_builtin.c

-- 
2.46.0.278.g36e3a12567




More information about the DTrace-devel mailing list