Skip to content

Commit

Permalink
Revert "perf build: Warn for BPF skeletons if endian mismatches"
Browse files Browse the repository at this point in the history
This reverts commit 51924ae.

We need to better polish building with BPF skels, so revert back to
making it an experimental feature that has to be explicitely enabled
using BUILD_BPF_SKEL=1.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
  • Loading branch information
Arnaldo Carvalho de Melo committed May 6, 2023
1 parent 6c73f81 commit c3e6df9
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions tools/perf/Makefile.config
Original file line number Diff line number Diff line change
Expand Up @@ -663,17 +663,14 @@ ifndef NO_BPF_SKEL
$(call feature_check,clang-bpf-co-re)
ifeq ($(feature-clang-bpf-co-re), 0)
dummy := $(error: ERROR: BPF skeletons unsupported. clang too old/not installed or build with NO_BPF_SKEL=1.)
else
ifeq ($(filter -DHAVE_LIBBPF_SUPPORT, $(CFLAGS)),)
dummy := $(error: ERROR: BPF skeletons unsupported. BPF skeleton support requires libbpf or build with NO_BPF_SKEL=1.)
else
$(call detected,CONFIG_PERF_BPF_SKEL)
CFLAGS += -DHAVE_BPF_SKEL
endif
endif
ifeq ($(filter -DHAVE_LIBBPF_SUPPORT, $(CFLAGS)),)
dummy := $(error: ERROR: BPF skeletons unsupported. BPF skeleton support requires libbpf or build with NO_BPF_SKEL=1.)
endif
host_byte_order=$(echo ""|$(HOSTCC) -dM -E -|grep __BYTE_ORDER__)
target_byte_order=$(echo ""|$(CC) -dM -E -|grep __BYTE_ORDER__)
ifneq ($(host_byte_order), $(target_byte_order))
$(warning Possibly mismatched host and target endianness may break BPF skeletons)
endif
$(call detected,CONFIG_PERF_BPF_SKEL)
CFLAGS += -DHAVE_BPF_SKEL
endif

dwarf-post-unwind := 1
Expand Down

0 comments on commit c3e6df9

Please sign in to comment.