simpleperf: add SIMPLE_PERF_RECORD_TRACE_DATA record type.
PERF_RECORD_TRACE_DATA can't have record size >= 64K. This causes
some aborts when recording tracepoint events, as in
https://github.com/android-ndk/ndk/issues/493.
So fix this by adding a custom type SIMPLE_PERF_RECORD_TRACING_DATA,
which isn't limited by 64K.
Also fix an error parsing formats of tracepoing events.
Bug: http://b/75278602
Test: run simpleperf_unit_test.
Change-Id: Ib5ebd0b6f981b00c2a256d17cdfd0e725d75a272
diff --git a/simpleperf/cmd_report_test.cpp b/simpleperf/cmd_report_test.cpp
index 28f226d..6ebbf31 100644
--- a/simpleperf/cmd_report_test.cpp
+++ b/simpleperf/cmd_report_test.cpp
@@ -486,6 +486,11 @@
ASSERT_TRUE(found);
}
+TEST_F(ReportCommandTest, report_big_trace_data) {
+ Report(PERF_DATA_WITH_BIG_TRACE_DATA);
+ ASSERT_TRUE(success);
+}
+
#if defined(__linux__)
#include "event_selection_set.h"