Add a new CMake option, LIBBPF_EMBEDDED, to switch between the
embedded version and the system version (searched via pkg-config)
of libbpf. Set the embedded version as the default.
Signed-off-by: Luca Boccassi <bluca@debian.org>
Cc: dwarves@vger.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Get latest changes and fixes for libbpf. Most importantly it pulls in
enum fwd resolution in btf_dedup().
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Cc: Alexei Starovoitov <ast@fb.com>
Cc: Yonghong Song <yhs@fb.com>
Cc: dwarves@vger.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Latest version of libbpf has btf_dedup() fixes preventing it from stucking
in a loop on allyesconfig kernels.
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Cc: Alexei Starovoitov <ast@fb.com>
Cc: Yonghong Song <yhs@fb.com>
Cc: andrii.nakryiko@gmail.com
Cc: bpf@vger.kernel.org
Cc: dwarves@vger.kernel.org
[ Fixed up to get the right upstream commit, the originally submitted wasn't at the github repo ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Bring in latest changes from libbpf which allow to use btf__dedup() for
big binaries (e.g., linux kernel image).
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Cc: Alexei Starovoitov <ast@fb.com>
Cc: bpf@vger.kernel.org
Cc: dwarves@vger.kernel.org
Cc: kernel-team@fb.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This change allows to use libbpf definitions and APIs from pahole.
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Cc: Alexei Starovoitov <ast@fb.com>
Cc: Martin KaFai Lau <kafai@fb.com>
Cc: Yonghong Song <yhs@fb.com>
Cc: dwarves@vger.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Now that ctracer generates systemtap scripts lets drop this file, its
misleading for casual readers.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
In the Linux kernel, currently the only target, we can't probe the
functions in kernel/{kprobe,relay}.c.
When systemtap starts supporting uprobes, there may be other cases that
require blacklisting CUs.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Now that we keep base type typedefs we need their definition in both the ostra
converter and the kernel collector, so moving them to a separate file and
including gets us the typedef definitions.
This paves the way for atomic_t and other types being also collected, once I
get some pluggable data dictionary definiton on how to collect non-base types
to avoid making all of ctracer kernel specific.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Fixing problems found in the fedora packaging review. There are still problems,
but lets get what works out of the door so that it gets into a distro and we
can see what is more important to work on from now on.
The OLS paper will be included as soon as it is published by the OLS organizers.
Signed-off-by: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
So that we can go on adding more config knobs without requiring adding new
parameters to lots of functions.
Signed-off-by: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
1. We now use relayfs
2. ostra-cg is shipped and used in the Makefile
3. README.ctracer has all the details
I followed README.ctracer and the result, in my workstation, was this one:
http://oops.ghostprotocols.net:81/acme/dwarves/callgraphs/acme_eating_his_dog_food/6.html
I've started on the 6th page as it is more interesting, having tcp and netlink
callchains, don't be disappointed by some pages having just one level of
nesting, that is just the lack of containers and aliases (to follow tcp_sock,
skb->sk, etc) from the OSTRA days, but it's getting there! :-)
Ah, it is collecting all the base types in the specified struct by doing a
struct "view", i.e. trimming the struct to have just members that are
"reducible" to basic types (int, long, char, signed and unsigned), then
reorganizing it with the code introduced in pahole --reorganize to get it to
the best layout possible, reducing the size of the entry probe points trace
entries.
Updated rpms are available at the usual place:
http://oops.ghostprotocols.net:81/acme/dwarves/rpm/
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
So that we don't have to do all the code emission inside ctracer.c, add
a Makefile too that uses the kernel rpm files shipped by your distro to
easily build a module for your workstation, see README.ctracer, that was
updated to describe the steps needed to have ctracer running in your
machine.
Now to polish the relay code.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>