Skip to content

reduce maximum memory usage

Thomas Weißschuh lkml 1 version Applied

Status from this message: The following commit has been merged into the objtool/core branch of tip:

Get series with b4
b4 am [email protected] change-id 20221216-objtool-memory-06db3b8bf111

Versions newest first

  1. v2 Latest8 patches 13 repliesApplied

Changes in v2 from the cover letter

- Warn on out of range values for reloc->type
- Also reduce size of struct special_alt
- Note: v1 did not make it to the lists, only to individual recipients

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/8objtool: make struct entries[] static and consttools/objtool/special.c+3 -30 replies
2/8objtool: make struct check_options statictools/objtool/builtin-check.c tools/objtool/include/objtool/builtin.h+1 -30 replies
3/8objtool: allocate multiple structures with calloc()tools/objtool/elf.c tools/objtool/include/objtool/elf.h+25 -211 reply
4/8objtool: introduce function elf_reloc_set_typetools/objtool/check.c tools/objtool/elf.c tools/objtool/include/objtool/elf.h+13 -60 replies
5/8objtool: reduce memory usage of struct reloctools/objtool/elf.c tools/objtool/include/objtool/elf.h+4 -15 replies
6/8objtool: optimize layout of struct symboltools/objtool/include/objtool/elf.h+2 -30 replies
7/8objtool: optimize layout of struct special_alttools/objtool/include/objtool/special.h+1 -10 replies
8/8objtool: explicitly cleanup resources on successtools/objtool/builtin-check.c+2 -01 reply

Reviews trailers per patch

1 of 8 patches has a Reviewed-by or Acked-by.

PatchRong Tao
1/8
2/8
3/8
4/8
5/8R-b
6/8
7/8
8/8

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/8] reduce maximum memory usage

The processing of vmlinux.o with objtool is the most memory-intensive step of a kernel build. By reducing the maximum memory usage here we can reduce the maximum memory usage of the whole kernel build.
Therefore memory pressure on memory starved machines is relieved during kernel builds and the build is faster as less swapping has to occur.

To: Josh Poimboeuf <[email protected]>
To: Peter Zijlstra <[email protected]>

---
Changes in v2:
- Warn on out of range values for reloc->type
- Also reduce size of struct special_alt
- Note: v1 did not make it to the lists, only to individual recipients

---
Thomas Weißschuh (8):
objtool: make struct entries[] static and const
objtool: make struct check_options static
objtool: allocate multiple structures with calloc()
objtool: introduce function elf_reloc_set_type
objtool: reduce memory usage of struct reloc
objtool: optimize layout of struct symbol
objtool: optimize layout of struct special_alt
objtool: explicitly cleanup resources on success

 tools/objtool/builtin-check.c           |  4 ++-
 tools/objtool/check.c                   |  6 ++--
 tools/objtool/elf.c                     | 56 +++++++++++++++++++--------------
 tools/objtool/include/objtool/builtin.h |  2 --
 tools/objtool/include/objtool/elf.h     | 13 +++++---
 tools/objtool/include/objtool/special.h |  2 +-
 tools/objtool/special.c                 |  6 ++--
 7 files changed, 51 insertions(+), 38 deletions(-)

---
base-commit: 1b929c02afd37871d5afb9d498426f83432e71c2
change-id: 20221216-objtool-memory-06db3b8bf111

Best regards,

Signature · 1 line
Thomas Weißschuh <[email protected]>