Skip to content

Lockdep: Reduce stack trace memory usage

Bart Van Assche lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4locking/lockdep: Make it clear that what lock_class::key points at is not modifiedinclude/linux/lockdep.h kernel/locking/lockdep.c kernel/locking/lockdep_internals.h +1 more+5 -40 replies
2/4stacktrace: Constify 'entries' argumentsinclude/linux/stacktrace.h kernel/stacktrace.c+4 -40 replies
3/4locking/lockdep: Reduce space occupied by stack tracesinclude/linux/lockdep.h kernel/locking/lockdep.c kernel/locking/lockdep_internals.h+95 -442 replies
4/4locking/lockdep: Report more stack trace statisticskernel/locking/lockdep.c kernel/locking/lockdep_internals.h kernel/locking/lockdep_proc.c+39 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] Lockdep: Reduce stack trace memory usage

Hi Peter,

An unfortunate side effect of commit 669de8bda87b ("kernel/workqueue: Use dynamic lockdep keys for workqueues") is that all stack traces associated with the lockdep key are leaked when a workqueue is destroyed. Fix this by storing each unique stack trace once. Please consider this patch series for Linux kernel v5.4.

Thanks,

Bart.

Bart Van Assche (4):
locking/lockdep: Make it clear that what lock_class::key points at is
not modified
stacktrace: Constify 'entries' arguments
locking/lockdep: Reduce space occupied by stack traces locking/lockdep: Report more stack trace statistics

 include/linux/lockdep.h            |  11 +-
 include/linux/stacktrace.h         |   4 +-
 kernel/locking/lockdep.c           | 159 ++++++++++++++++++++++-------
 kernel/locking/lockdep_internals.h |   9 +-
 kernel/locking/lockdep_proc.c      |   8 +-
 kernel/stacktrace.c                |   4 +-
 6 files changed, 143 insertions(+), 52 deletions(-)
Signature · 1 line
2.22.0.657.g960e92d24f-goog