Skip to content

Commit

Permalink
perf build: Add build-test for debug-frame on arm/arm64
Browse files Browse the repository at this point in the history
Debug-frame for remote platforms is not related to the host platform, so
we should test each platform separately.

Signed-off-by: He Kuang <[email protected]>
Acked-by: Jiri Olsa <[email protected]>
Cc: Adrian Hunter <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Andi Kleen <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Ekaterina Tumanova <[email protected]>
Cc: Josh Poimboeuf <[email protected]>
Cc: Kan Liang <[email protected]>
Cc: Masami Hiramatsu <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Pekka Enberg <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Stephane Eranian <[email protected]>
Cc: Sukadev Bhattiprolu <[email protected]>
Cc: Wang Nan <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
  • Loading branch information
He Kuang authored and acmel committed May 11, 2016
1 parent b1d9600 commit f9be7ee
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tools/build/Makefile.feature
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ FEATURE_TESTS_EXTRA := \
libbabeltrace \
liberty \
liberty-z \
libunwind-debug-frame
libunwind-debug-frame \
libunwind-debug-frame-arm \
libunwind-debug-frame-aarch64

FEATURE_TESTS ?= $(FEATURE_TESTS_BASIC)

Expand Down
7 changes: 7 additions & 0 deletions tools/build/feature/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ FILES= \
test-libunwind-x86_64.bin \
test-libunwind-arm.bin \
test-libunwind-aarch64.bin \
test-libunwind-debug-frame-arm.bin \
test-libunwind-debug-frame-aarch64.bin \
test-pthread-attr-setaffinity-np.bin \
test-stackprotector-all.bin \
test-timerfd.bin \
Expand Down Expand Up @@ -119,6 +121,11 @@ $(OUTPUT)test-libunwind-arm.bin:
$(OUTPUT)test-libunwind-aarch64.bin:
$(BUILD) -lelf -lunwind-aarch64

$(OUTPUT)test-libunwind-debug-frame-arm.bin:
$(BUILD) -lelf -lunwind-arm

$(OUTPUT)test-libunwind-debug-frame-aarch64.bin:
$(BUILD) -lelf -lunwind-aarch64

$(OUTPUT)test-libaudit.bin:
$(BUILD) -laudit
Expand Down
16 changes: 16 additions & 0 deletions tools/build/feature/test-libunwind-debug-frame-aarch64.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#include <libunwind-aarch64.h>
#include <stdlib.h>

extern int
UNW_OBJ(dwarf_find_debug_frame) (int found, unw_dyn_info_t *di_debug,
unw_word_t ip, unw_word_t segbase,
const char *obj_name, unw_word_t start,
unw_word_t end);

#define dwarf_find_debug_frame UNW_OBJ(dwarf_find_debug_frame)

int main(void)
{
dwarf_find_debug_frame(0, NULL, 0, 0, NULL, 0, 0);
return 0;
}
16 changes: 16 additions & 0 deletions tools/build/feature/test-libunwind-debug-frame-arm.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#include <libunwind-arm.h>
#include <stdlib.h>

extern int
UNW_OBJ(dwarf_find_debug_frame) (int found, unw_dyn_info_t *di_debug,
unw_word_t ip, unw_word_t segbase,
const char *obj_name, unw_word_t start,
unw_word_t end);

#define dwarf_find_debug_frame UNW_OBJ(dwarf_find_debug_frame)

int main(void)
{
dwarf_find_debug_frame(0, NULL, 0, 0, NULL, 0, 0);
return 0;
}

0 comments on commit f9be7ee

Please sign in to comment.