All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH bpf-next 0/2] tools, bpftool: Define name arrays only once
@ 2020-06-22 14:00 Tobias Klauser
  2020-06-22 14:00 ` [PATCH bpf-next 1/2] tools, bpftool: Define prog_type_name array " Tobias Klauser
  2020-06-22 14:00 ` [PATCH bpf-next 2/2] tools, bpftool: Define attach_type_name " Tobias Klauser
  0 siblings, 2 replies; 8+ messages in thread
From: Tobias Klauser @ 2020-06-22 14:00 UTC (permalink / raw)
  To: Alexei Starovoitov, Daniel Borkmann; +Cc: Andrii Nakryiko, Quentin Monnet, bpf

Define the prog_type_name and attach_type_name only once by moving them
out of main.h. This slightly reduces the binary size of bpftool:

Before:

   text	   data	    bss	    dec	    hex	filename
 401032	  11936	1573160	1986128	 1e4e50	bpftool

After:

   text	   data	    bss	    dec	    hex	filename
 398256	  10880	1573160	1982296	 1e3f58	bpftool

Tobias Klauser (2):
  tools, bpftool: Define prog_type_name array only once
  tools, bpftool: Define attach_type_name array only once

 tools/bpf/bpftool/cgroup.c  | 36 +++++++++++++++++++
 tools/bpf/bpftool/feature.c |  4 +--
 tools/bpf/bpftool/link.c    |  4 +--
 tools/bpf/bpftool/main.h    | 69 ++-----------------------------------
 tools/bpf/bpftool/map.c     |  4 +--
 tools/bpf/bpftool/prog.c    | 34 ++++++++++++++++++
 6 files changed, 79 insertions(+), 72 deletions(-)

-- 
2.27.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-06-23  9:58 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-22 14:00 [PATCH bpf-next 0/2] tools, bpftool: Define name arrays only once Tobias Klauser
2020-06-22 14:00 ` [PATCH bpf-next 1/2] tools, bpftool: Define prog_type_name array " Tobias Klauser
2020-06-22 14:26   ` Quentin Monnet
2020-06-22 15:05     ` Tobias Klauser
2020-06-22 15:17       ` Quentin Monnet
2020-06-23  9:58         ` Tobias Klauser
2020-06-22 14:00 ` [PATCH bpf-next 2/2] tools, bpftool: Define attach_type_name " Tobias Klauser
2020-06-23  5:58   ` Andrii Nakryiko

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.