Merge changes I251a3ca6,Ia427d5e4
* changes:
tp: refactor code to split fuchsia_record and systrace_line
tp: move storage_full to importers_full
diff --git a/Android.bp b/Android.bp
index d01d33d..959f21e 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1972,16 +1972,19 @@
":perfetto_src_trace_processor_ftrace_descriptors",
":perfetto_src_trace_processor_importers_android_bugreport_android_bugreport",
":perfetto_src_trace_processor_importers_common_common",
+ ":perfetto_src_trace_processor_importers_common_trace_parser",
+ ":perfetto_src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":perfetto_src_trace_processor_importers_importers_full",
":perfetto_src_trace_processor_importers_memory_tracker_graph_processor",
":perfetto_src_trace_processor_importers_proto_storage_full",
":perfetto_src_trace_processor_importers_proto_storage_minimal",
+ ":perfetto_src_trace_processor_importers_systrace_systrace_line",
":perfetto_src_trace_processor_lib",
":perfetto_src_trace_processor_metatrace",
":perfetto_src_trace_processor_metrics_metrics",
":perfetto_src_trace_processor_sqlite_functions_functions",
":perfetto_src_trace_processor_sqlite_sqlite",
":perfetto_src_trace_processor_sqlite_sqlite_minimal",
- ":perfetto_src_trace_processor_storage_full",
":perfetto_src_trace_processor_storage_minimal",
":perfetto_src_trace_processor_storage_storage",
":perfetto_src_trace_processor_tables_tables",
@@ -9166,6 +9169,11 @@
],
}
+// GN: //src/trace_processor/importers/common:trace_parser
+filegroup {
+ name: "perfetto_src_trace_processor_importers_common_trace_parser",
+}
+
// GN: //src/trace_processor/importers/common:unittests
filegroup {
name: "perfetto_src_trace_processor_importers_common_unittests",
@@ -9181,6 +9189,14 @@
],
}
+// GN: //src/trace_processor/importers/fuchsia:fuchsia_record
+filegroup {
+ name: "perfetto_src_trace_processor_importers_fuchsia_fuchsia_record",
+ srcs: [
+ "src/trace_processor/importers/fuchsia/fuchsia_record.cc",
+ ],
+}
+
// GN: //src/trace_processor/importers:gen_cc_chrome_track_event_descriptor
genrule {
name: "perfetto_src_trace_processor_importers_gen_cc_chrome_track_event_descriptor",
@@ -9256,6 +9272,49 @@
],
}
+// GN: //src/trace_processor/importers:importers_full
+filegroup {
+ name: "perfetto_src_trace_processor_importers_importers_full",
+ srcs: [
+ "src/trace_processor/importers/additional_modules.cc",
+ "src/trace_processor/importers/ftrace/binder_tracker.cc",
+ "src/trace_processor/importers/ftrace/drm_tracker.cc",
+ "src/trace_processor/importers/ftrace/ftrace_module_impl.cc",
+ "src/trace_processor/importers/ftrace/ftrace_parser.cc",
+ "src/trace_processor/importers/ftrace/ftrace_tokenizer.cc",
+ "src/trace_processor/importers/ftrace/iostat_tracker.cc",
+ "src/trace_processor/importers/ftrace/rss_stat_tracker.cc",
+ "src/trace_processor/importers/ftrace/sched_event_tracker.cc",
+ "src/trace_processor/importers/ftrace/thread_state_tracker.cc",
+ "src/trace_processor/importers/ftrace/v4l2_tracker.cc",
+ "src/trace_processor/importers/ftrace/virtio_video_tracker.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc",
+ "src/trace_processor/importers/gzip/gzip_trace_parser.cc",
+ "src/trace_processor/importers/i2c/i2c_tracker.cc",
+ "src/trace_processor/importers/json/json_trace_parser.cc",
+ "src/trace_processor/importers/json/json_trace_tokenizer.cc",
+ "src/trace_processor/importers/proto/android_probes_module.cc",
+ "src/trace_processor/importers/proto/android_probes_parser.cc",
+ "src/trace_processor/importers/proto/android_probes_tracker.cc",
+ "src/trace_processor/importers/proto/content_analyzer.cc",
+ "src/trace_processor/importers/proto/frame_timeline_event_parser.cc",
+ "src/trace_processor/importers/proto/gpu_event_parser.cc",
+ "src/trace_processor/importers/proto/graphics_event_module.cc",
+ "src/trace_processor/importers/proto/graphics_frame_event_parser.cc",
+ "src/trace_processor/importers/proto/heap_graph_module.cc",
+ "src/trace_processor/importers/proto/system_probes_module.cc",
+ "src/trace_processor/importers/proto/system_probes_parser.cc",
+ "src/trace_processor/importers/proto/vulkan_memory_tracker.cc",
+ "src/trace_processor/importers/syscalls/syscall_tracker.cc",
+ "src/trace_processor/importers/systrace/systrace_line_parser.cc",
+ "src/trace_processor/importers/systrace/systrace_line_tokenizer.cc",
+ "src/trace_processor/importers/systrace/systrace_parser.cc",
+ "src/trace_processor/importers/systrace/systrace_trace_parser.cc",
+ ],
+}
+
// GN: //src/trace_processor/importers/memory_tracker:graph_processor
filegroup {
name: "perfetto_src_trace_processor_importers_memory_tracker_graph_processor",
@@ -9297,6 +9356,11 @@
],
}
+// GN: //src/trace_processor/importers/systrace:systrace_line
+filegroup {
+ name: "perfetto_src_trace_processor_importers_systrace_systrace_line",
+}
+
// GN: //src/trace_processor:lib
filegroup {
name: "perfetto_src_trace_processor_lib",
@@ -9632,50 +9696,6 @@
],
}
-// GN: //src/trace_processor:storage_full
-filegroup {
- name: "perfetto_src_trace_processor_storage_full",
- srcs: [
- "src/trace_processor/importers/additional_modules.cc",
- "src/trace_processor/importers/ftrace/binder_tracker.cc",
- "src/trace_processor/importers/ftrace/drm_tracker.cc",
- "src/trace_processor/importers/ftrace/ftrace_module_impl.cc",
- "src/trace_processor/importers/ftrace/ftrace_parser.cc",
- "src/trace_processor/importers/ftrace/ftrace_tokenizer.cc",
- "src/trace_processor/importers/ftrace/iostat_tracker.cc",
- "src/trace_processor/importers/ftrace/rss_stat_tracker.cc",
- "src/trace_processor/importers/ftrace/sched_event_tracker.cc",
- "src/trace_processor/importers/ftrace/thread_state_tracker.cc",
- "src/trace_processor/importers/ftrace/v4l2_tracker.cc",
- "src/trace_processor/importers/ftrace/virtio_video_tracker.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_record.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc",
- "src/trace_processor/importers/gzip/gzip_trace_parser.cc",
- "src/trace_processor/importers/i2c/i2c_tracker.cc",
- "src/trace_processor/importers/json/json_trace_parser.cc",
- "src/trace_processor/importers/json/json_trace_tokenizer.cc",
- "src/trace_processor/importers/proto/android_probes_module.cc",
- "src/trace_processor/importers/proto/android_probes_parser.cc",
- "src/trace_processor/importers/proto/android_probes_tracker.cc",
- "src/trace_processor/importers/proto/content_analyzer.cc",
- "src/trace_processor/importers/proto/frame_timeline_event_parser.cc",
- "src/trace_processor/importers/proto/gpu_event_parser.cc",
- "src/trace_processor/importers/proto/graphics_event_module.cc",
- "src/trace_processor/importers/proto/graphics_frame_event_parser.cc",
- "src/trace_processor/importers/proto/heap_graph_module.cc",
- "src/trace_processor/importers/proto/system_probes_module.cc",
- "src/trace_processor/importers/proto/system_probes_parser.cc",
- "src/trace_processor/importers/proto/vulkan_memory_tracker.cc",
- "src/trace_processor/importers/syscalls/syscall_tracker.cc",
- "src/trace_processor/importers/systrace/systrace_line_parser.cc",
- "src/trace_processor/importers/systrace/systrace_line_tokenizer.cc",
- "src/trace_processor/importers/systrace/systrace_parser.cc",
- "src/trace_processor/importers/systrace/systrace_trace_parser.cc",
- ],
-}
-
// GN: //src/trace_processor:storage_minimal
filegroup {
name: "perfetto_src_trace_processor_storage_minimal",
@@ -11191,11 +11211,15 @@
":perfetto_src_trace_processor_importers_android_bugreport_android_bugreport",
":perfetto_src_trace_processor_importers_android_bugreport_unittests",
":perfetto_src_trace_processor_importers_common_common",
+ ":perfetto_src_trace_processor_importers_common_trace_parser",
":perfetto_src_trace_processor_importers_common_unittests",
+ ":perfetto_src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":perfetto_src_trace_processor_importers_importers_full",
":perfetto_src_trace_processor_importers_memory_tracker_graph_processor",
":perfetto_src_trace_processor_importers_proto_storage_full",
":perfetto_src_trace_processor_importers_proto_storage_minimal",
":perfetto_src_trace_processor_importers_proto_unittests",
+ ":perfetto_src_trace_processor_importers_systrace_systrace_line",
":perfetto_src_trace_processor_lib",
":perfetto_src_trace_processor_metatrace",
":perfetto_src_trace_processor_metrics_metrics",
@@ -11207,7 +11231,6 @@
":perfetto_src_trace_processor_sqlite_sqlite",
":perfetto_src_trace_processor_sqlite_sqlite_minimal",
":perfetto_src_trace_processor_sqlite_unittests",
- ":perfetto_src_trace_processor_storage_full",
":perfetto_src_trace_processor_storage_minimal",
":perfetto_src_trace_processor_storage_storage",
":perfetto_src_trace_processor_tables_tables",
@@ -11833,9 +11856,13 @@
":perfetto_src_trace_processor_ftrace_descriptors",
":perfetto_src_trace_processor_importers_android_bugreport_android_bugreport",
":perfetto_src_trace_processor_importers_common_common",
+ ":perfetto_src_trace_processor_importers_common_trace_parser",
+ ":perfetto_src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":perfetto_src_trace_processor_importers_importers_full",
":perfetto_src_trace_processor_importers_memory_tracker_graph_processor",
":perfetto_src_trace_processor_importers_proto_storage_full",
":perfetto_src_trace_processor_importers_proto_storage_minimal",
+ ":perfetto_src_trace_processor_importers_systrace_systrace_line",
":perfetto_src_trace_processor_lib",
":perfetto_src_trace_processor_metatrace",
":perfetto_src_trace_processor_metrics_metrics",
@@ -11844,7 +11871,6 @@
":perfetto_src_trace_processor_sqlite_functions_functions",
":perfetto_src_trace_processor_sqlite_sqlite",
":perfetto_src_trace_processor_sqlite_sqlite_minimal",
- ":perfetto_src_trace_processor_storage_full",
":perfetto_src_trace_processor_storage_minimal",
":perfetto_src_trace_processor_storage_storage",
":perfetto_src_trace_processor_tables_tables",
@@ -12026,16 +12052,19 @@
":perfetto_src_trace_processor_ftrace_descriptors",
":perfetto_src_trace_processor_importers_android_bugreport_android_bugreport",
":perfetto_src_trace_processor_importers_common_common",
+ ":perfetto_src_trace_processor_importers_common_trace_parser",
+ ":perfetto_src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":perfetto_src_trace_processor_importers_importers_full",
":perfetto_src_trace_processor_importers_memory_tracker_graph_processor",
":perfetto_src_trace_processor_importers_proto_storage_full",
":perfetto_src_trace_processor_importers_proto_storage_minimal",
+ ":perfetto_src_trace_processor_importers_systrace_systrace_line",
":perfetto_src_trace_processor_lib",
":perfetto_src_trace_processor_metatrace",
":perfetto_src_trace_processor_metrics_metrics",
":perfetto_src_trace_processor_sqlite_functions_functions",
":perfetto_src_trace_processor_sqlite_sqlite",
":perfetto_src_trace_processor_sqlite_sqlite_minimal",
- ":perfetto_src_trace_processor_storage_full",
":perfetto_src_trace_processor_storage_minimal",
":perfetto_src_trace_processor_storage_storage",
":perfetto_src_trace_processor_tables_tables",
diff --git a/BUILD b/BUILD
index 054c5e0..0ecb3bc 100644
--- a/BUILD
+++ b/BUILD
@@ -1128,12 +1128,28 @@
"src/trace_processor/importers/common/slice_translation_table.h",
"src/trace_processor/importers/common/system_info_tracker.cc",
"src/trace_processor/importers/common/system_info_tracker.h",
- "src/trace_processor/importers/common/trace_parser.h",
"src/trace_processor/importers/common/track_tracker.cc",
"src/trace_processor/importers/common/track_tracker.h",
],
)
+# GN target: //src/trace_processor/importers/common:trace_parser
+perfetto_filegroup(
+ name = "src_trace_processor_importers_common_trace_parser",
+ srcs = [
+ "src/trace_processor/importers/common/trace_parser.h",
+ ],
+)
+
+# GN target: //src/trace_processor/importers/fuchsia:fuchsia_record
+perfetto_filegroup(
+ name = "src_trace_processor_importers_fuchsia_fuchsia_record",
+ srcs = [
+ "src/trace_processor/importers/fuchsia/fuchsia_record.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_record.h",
+ ],
+)
+
# GN target: //src/trace_processor/importers/memory_tracker:graph_processor
perfetto_filegroup(
name = "src_trace_processor_importers_memory_tracker_graph_processor",
@@ -1170,6 +1186,14 @@
],
)
+# GN target: //src/trace_processor/importers/systrace:systrace_line
+perfetto_filegroup(
+ name = "src_trace_processor_importers_systrace_systrace_line",
+ srcs = [
+ "src/trace_processor/importers/systrace/systrace_line.h",
+ ],
+)
+
# GN target: //src/trace_processor/importers:gen_cc_chrome_track_event_descriptor
perfetto_cc_proto_descriptor(
name = "src_trace_processor_importers_gen_cc_chrome_track_event_descriptor",
@@ -1225,6 +1249,83 @@
],
)
+# GN target: //src/trace_processor/importers:importers_full
+perfetto_filegroup(
+ name = "src_trace_processor_importers_importers_full",
+ srcs = [
+ "src/trace_processor/importers/additional_modules.cc",
+ "src/trace_processor/importers/additional_modules.h",
+ "src/trace_processor/importers/ftrace/binder_tracker.cc",
+ "src/trace_processor/importers/ftrace/binder_tracker.h",
+ "src/trace_processor/importers/ftrace/drm_tracker.cc",
+ "src/trace_processor/importers/ftrace/drm_tracker.h",
+ "src/trace_processor/importers/ftrace/ftrace_module_impl.cc",
+ "src/trace_processor/importers/ftrace/ftrace_module_impl.h",
+ "src/trace_processor/importers/ftrace/ftrace_parser.cc",
+ "src/trace_processor/importers/ftrace/ftrace_parser.h",
+ "src/trace_processor/importers/ftrace/ftrace_tokenizer.cc",
+ "src/trace_processor/importers/ftrace/ftrace_tokenizer.h",
+ "src/trace_processor/importers/ftrace/iostat_tracker.cc",
+ "src/trace_processor/importers/ftrace/iostat_tracker.h",
+ "src/trace_processor/importers/ftrace/rss_stat_tracker.cc",
+ "src/trace_processor/importers/ftrace/rss_stat_tracker.h",
+ "src/trace_processor/importers/ftrace/sched_event_tracker.cc",
+ "src/trace_processor/importers/ftrace/sched_event_tracker.h",
+ "src/trace_processor/importers/ftrace/thread_state_tracker.cc",
+ "src/trace_processor/importers/ftrace/thread_state_tracker.h",
+ "src/trace_processor/importers/ftrace/v4l2_tracker.cc",
+ "src/trace_processor/importers/ftrace/v4l2_tracker.h",
+ "src/trace_processor/importers/ftrace/virtio_video_tracker.cc",
+ "src/trace_processor/importers/ftrace/virtio_video_tracker.h",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.h",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h",
+ "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc",
+ "src/trace_processor/importers/gzip/gzip_trace_parser.cc",
+ "src/trace_processor/importers/gzip/gzip_trace_parser.h",
+ "src/trace_processor/importers/i2c/i2c_tracker.cc",
+ "src/trace_processor/importers/i2c/i2c_tracker.h",
+ "src/trace_processor/importers/json/json_trace_parser.cc",
+ "src/trace_processor/importers/json/json_trace_parser.h",
+ "src/trace_processor/importers/json/json_trace_tokenizer.cc",
+ "src/trace_processor/importers/json/json_trace_tokenizer.h",
+ "src/trace_processor/importers/proto/android_probes_module.cc",
+ "src/trace_processor/importers/proto/android_probes_module.h",
+ "src/trace_processor/importers/proto/android_probes_parser.cc",
+ "src/trace_processor/importers/proto/android_probes_parser.h",
+ "src/trace_processor/importers/proto/android_probes_tracker.cc",
+ "src/trace_processor/importers/proto/android_probes_tracker.h",
+ "src/trace_processor/importers/proto/content_analyzer.cc",
+ "src/trace_processor/importers/proto/content_analyzer.h",
+ "src/trace_processor/importers/proto/frame_timeline_event_parser.cc",
+ "src/trace_processor/importers/proto/frame_timeline_event_parser.h",
+ "src/trace_processor/importers/proto/gpu_event_parser.cc",
+ "src/trace_processor/importers/proto/gpu_event_parser.h",
+ "src/trace_processor/importers/proto/graphics_event_module.cc",
+ "src/trace_processor/importers/proto/graphics_event_module.h",
+ "src/trace_processor/importers/proto/graphics_frame_event_parser.cc",
+ "src/trace_processor/importers/proto/graphics_frame_event_parser.h",
+ "src/trace_processor/importers/proto/heap_graph_module.cc",
+ "src/trace_processor/importers/proto/heap_graph_module.h",
+ "src/trace_processor/importers/proto/system_probes_module.cc",
+ "src/trace_processor/importers/proto/system_probes_module.h",
+ "src/trace_processor/importers/proto/system_probes_parser.cc",
+ "src/trace_processor/importers/proto/system_probes_parser.h",
+ "src/trace_processor/importers/proto/vulkan_memory_tracker.cc",
+ "src/trace_processor/importers/proto/vulkan_memory_tracker.h",
+ "src/trace_processor/importers/syscalls/syscall_tracker.cc",
+ "src/trace_processor/importers/systrace/systrace_line_parser.cc",
+ "src/trace_processor/importers/systrace/systrace_line_parser.h",
+ "src/trace_processor/importers/systrace/systrace_line_tokenizer.cc",
+ "src/trace_processor/importers/systrace/systrace_line_tokenizer.h",
+ "src/trace_processor/importers/systrace/systrace_parser.cc",
+ "src/trace_processor/importers/systrace/systrace_parser.h",
+ "src/trace_processor/importers/systrace/systrace_trace_parser.cc",
+ "src/trace_processor/importers/systrace/systrace_trace_parser.h",
+ ],
+)
+
# GN target: //src/trace_processor/metrics/sql/android:android
perfetto_filegroup(
name = "src_trace_processor_metrics_sql_android_android",
@@ -1822,84 +1923,6 @@
],
)
-# GN target: //src/trace_processor:storage_full
-perfetto_filegroup(
- name = "src_trace_processor_storage_full",
- srcs = [
- "src/trace_processor/importers/additional_modules.cc",
- "src/trace_processor/importers/additional_modules.h",
- "src/trace_processor/importers/ftrace/binder_tracker.cc",
- "src/trace_processor/importers/ftrace/binder_tracker.h",
- "src/trace_processor/importers/ftrace/drm_tracker.cc",
- "src/trace_processor/importers/ftrace/drm_tracker.h",
- "src/trace_processor/importers/ftrace/ftrace_module_impl.cc",
- "src/trace_processor/importers/ftrace/ftrace_module_impl.h",
- "src/trace_processor/importers/ftrace/ftrace_parser.cc",
- "src/trace_processor/importers/ftrace/ftrace_parser.h",
- "src/trace_processor/importers/ftrace/ftrace_tokenizer.cc",
- "src/trace_processor/importers/ftrace/ftrace_tokenizer.h",
- "src/trace_processor/importers/ftrace/iostat_tracker.cc",
- "src/trace_processor/importers/ftrace/iostat_tracker.h",
- "src/trace_processor/importers/ftrace/rss_stat_tracker.cc",
- "src/trace_processor/importers/ftrace/rss_stat_tracker.h",
- "src/trace_processor/importers/ftrace/sched_event_tracker.cc",
- "src/trace_processor/importers/ftrace/sched_event_tracker.h",
- "src/trace_processor/importers/ftrace/thread_state_tracker.cc",
- "src/trace_processor/importers/ftrace/thread_state_tracker.h",
- "src/trace_processor/importers/ftrace/v4l2_tracker.cc",
- "src/trace_processor/importers/ftrace/v4l2_tracker.h",
- "src/trace_processor/importers/ftrace/virtio_video_tracker.cc",
- "src/trace_processor/importers/ftrace/virtio_video_tracker.h",
- "src/trace_processor/importers/fuchsia/fuchsia_record.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_parser.h",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h",
- "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc",
- "src/trace_processor/importers/gzip/gzip_trace_parser.cc",
- "src/trace_processor/importers/gzip/gzip_trace_parser.h",
- "src/trace_processor/importers/i2c/i2c_tracker.cc",
- "src/trace_processor/importers/i2c/i2c_tracker.h",
- "src/trace_processor/importers/json/json_trace_parser.cc",
- "src/trace_processor/importers/json/json_trace_parser.h",
- "src/trace_processor/importers/json/json_trace_tokenizer.cc",
- "src/trace_processor/importers/json/json_trace_tokenizer.h",
- "src/trace_processor/importers/proto/android_probes_module.cc",
- "src/trace_processor/importers/proto/android_probes_module.h",
- "src/trace_processor/importers/proto/android_probes_parser.cc",
- "src/trace_processor/importers/proto/android_probes_parser.h",
- "src/trace_processor/importers/proto/android_probes_tracker.cc",
- "src/trace_processor/importers/proto/android_probes_tracker.h",
- "src/trace_processor/importers/proto/content_analyzer.cc",
- "src/trace_processor/importers/proto/content_analyzer.h",
- "src/trace_processor/importers/proto/frame_timeline_event_parser.cc",
- "src/trace_processor/importers/proto/frame_timeline_event_parser.h",
- "src/trace_processor/importers/proto/gpu_event_parser.cc",
- "src/trace_processor/importers/proto/gpu_event_parser.h",
- "src/trace_processor/importers/proto/graphics_event_module.cc",
- "src/trace_processor/importers/proto/graphics_event_module.h",
- "src/trace_processor/importers/proto/graphics_frame_event_parser.cc",
- "src/trace_processor/importers/proto/graphics_frame_event_parser.h",
- "src/trace_processor/importers/proto/heap_graph_module.cc",
- "src/trace_processor/importers/proto/heap_graph_module.h",
- "src/trace_processor/importers/proto/system_probes_module.cc",
- "src/trace_processor/importers/proto/system_probes_module.h",
- "src/trace_processor/importers/proto/system_probes_parser.cc",
- "src/trace_processor/importers/proto/system_probes_parser.h",
- "src/trace_processor/importers/proto/vulkan_memory_tracker.cc",
- "src/trace_processor/importers/proto/vulkan_memory_tracker.h",
- "src/trace_processor/importers/syscalls/syscall_tracker.cc",
- "src/trace_processor/importers/systrace/systrace_line_parser.cc",
- "src/trace_processor/importers/systrace/systrace_line_parser.h",
- "src/trace_processor/importers/systrace/systrace_line_tokenizer.cc",
- "src/trace_processor/importers/systrace/systrace_line_tokenizer.h",
- "src/trace_processor/importers/systrace/systrace_parser.cc",
- "src/trace_processor/importers/systrace/systrace_parser.h",
- "src/trace_processor/importers/systrace/systrace_trace_parser.cc",
- "src/trace_processor/importers/systrace/systrace_trace_parser.h",
- ],
-)
-
# GN target: //src/trace_processor:storage_minimal
perfetto_filegroup(
name = "src_trace_processor_storage_minimal",
@@ -1911,7 +1934,6 @@
"src/trace_processor/importers/default_modules.h",
"src/trace_processor/importers/ftrace/ftrace_module.cc",
"src/trace_processor/importers/ftrace/ftrace_module.h",
- "src/trace_processor/importers/fuchsia/fuchsia_record.h",
"src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h",
"src/trace_processor/importers/json/json_utils.cc",
"src/trace_processor/importers/json/json_utils.h",
@@ -1965,7 +1987,6 @@
"src/trace_processor/importers/proto/translation_table_module.cc",
"src/trace_processor/importers/proto/translation_table_module.h",
"src/trace_processor/importers/syscalls/syscall_tracker.h",
- "src/trace_processor/importers/systrace/systrace_line.h",
"src/trace_processor/parser_types.h",
"src/trace_processor/trace_blob.cc",
"src/trace_processor/trace_processor_context.cc",
@@ -4360,16 +4381,19 @@
":src_trace_processor_ftrace_descriptors",
":src_trace_processor_importers_android_bugreport_android_bugreport",
":src_trace_processor_importers_common_common",
+ ":src_trace_processor_importers_common_trace_parser",
+ ":src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":src_trace_processor_importers_importers_full",
":src_trace_processor_importers_memory_tracker_graph_processor",
":src_trace_processor_importers_proto_storage_full",
":src_trace_processor_importers_proto_storage_minimal",
+ ":src_trace_processor_importers_systrace_systrace_line",
":src_trace_processor_lib",
":src_trace_processor_metatrace",
":src_trace_processor_metrics_metrics",
":src_trace_processor_sqlite_functions_functions",
":src_trace_processor_sqlite_sqlite",
":src_trace_processor_sqlite_sqlite_minimal",
- ":src_trace_processor_storage_full",
":src_trace_processor_storage_minimal",
":src_trace_processor_storage_storage",
":src_trace_processor_tables_tables",
@@ -4489,9 +4513,13 @@
":src_trace_processor_ftrace_descriptors",
":src_trace_processor_importers_android_bugreport_android_bugreport",
":src_trace_processor_importers_common_common",
+ ":src_trace_processor_importers_common_trace_parser",
+ ":src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":src_trace_processor_importers_importers_full",
":src_trace_processor_importers_memory_tracker_graph_processor",
":src_trace_processor_importers_proto_storage_full",
":src_trace_processor_importers_proto_storage_minimal",
+ ":src_trace_processor_importers_systrace_systrace_line",
":src_trace_processor_lib",
":src_trace_processor_metatrace",
":src_trace_processor_metrics_metrics",
@@ -4500,7 +4528,6 @@
":src_trace_processor_sqlite_functions_functions",
":src_trace_processor_sqlite_sqlite",
":src_trace_processor_sqlite_sqlite_minimal",
- ":src_trace_processor_storage_full",
":src_trace_processor_storage_minimal",
":src_trace_processor_storage_storage",
":src_trace_processor_tables_tables",
@@ -4677,16 +4704,19 @@
":src_trace_processor_ftrace_descriptors",
":src_trace_processor_importers_android_bugreport_android_bugreport",
":src_trace_processor_importers_common_common",
+ ":src_trace_processor_importers_common_trace_parser",
+ ":src_trace_processor_importers_fuchsia_fuchsia_record",
+ ":src_trace_processor_importers_importers_full",
":src_trace_processor_importers_memory_tracker_graph_processor",
":src_trace_processor_importers_proto_storage_full",
":src_trace_processor_importers_proto_storage_minimal",
+ ":src_trace_processor_importers_systrace_systrace_line",
":src_trace_processor_lib",
":src_trace_processor_metatrace",
":src_trace_processor_metrics_metrics",
":src_trace_processor_sqlite_functions_functions",
":src_trace_processor_sqlite_sqlite",
":src_trace_processor_sqlite_sqlite_minimal",
- ":src_trace_processor_storage_full",
":src_trace_processor_storage_minimal",
":src_trace_processor_storage_storage",
":src_trace_processor_tables_tables",
diff --git a/python/perfetto/trace_processor/metrics.descriptor b/python/perfetto/trace_processor/metrics.descriptor
index 165a2ab..ed386ba 100644
--- a/python/perfetto/trace_processor/metrics.descriptor
+++ b/python/perfetto/trace_processor/metrics.descriptor
Binary files differ
diff --git a/src/trace_processor/BUILD.gn b/src/trace_processor/BUILD.gn
index e82dcd7..db6cd1a 100644
--- a/src/trace_processor/BUILD.gn
+++ b/src/trace_processor/BUILD.gn
@@ -101,7 +101,6 @@
"importers/default_modules.h",
"importers/ftrace/ftrace_module.cc",
"importers/ftrace/ftrace_module.h",
- "importers/fuchsia/fuchsia_record.h",
"importers/fuchsia/fuchsia_trace_utils.h",
"importers/json/json_utils.cc",
"importers/json/json_utils.h",
@@ -157,7 +156,6 @@
"importers/proto/translation_table_module.cc",
"importers/proto/translation_table_module.h",
"importers/syscalls/syscall_tracker.h",
- "importers/systrace/systrace_line.h",
"parser_types.h",
"trace_blob.cc",
"trace_processor_context.cc",
@@ -179,8 +177,10 @@
"importers:gen_cc_statsd_atoms_descriptor",
"importers:gen_cc_track_event_descriptor",
"importers/common",
+ "importers/fuchsia:fuchsia_record",
"importers/memory_tracker:graph_processor",
"importers/proto:storage_minimal",
+ "importers/systrace:systrace_line",
"storage",
"tables",
"types",
@@ -219,109 +219,6 @@
}
}
-source_set("storage_full") {
- sources = [
- "importers/additional_modules.cc",
- "importers/additional_modules.h",
- "importers/ftrace/binder_tracker.cc",
- "importers/ftrace/binder_tracker.h",
- "importers/ftrace/drm_tracker.cc",
- "importers/ftrace/drm_tracker.h",
- "importers/ftrace/ftrace_module_impl.cc",
- "importers/ftrace/ftrace_module_impl.h",
- "importers/ftrace/ftrace_parser.cc",
- "importers/ftrace/ftrace_parser.h",
- "importers/ftrace/ftrace_tokenizer.cc",
- "importers/ftrace/ftrace_tokenizer.h",
- "importers/ftrace/iostat_tracker.cc",
- "importers/ftrace/iostat_tracker.h",
- "importers/ftrace/rss_stat_tracker.cc",
- "importers/ftrace/rss_stat_tracker.h",
- "importers/ftrace/sched_event_tracker.cc",
- "importers/ftrace/sched_event_tracker.h",
- "importers/ftrace/thread_state_tracker.cc",
- "importers/ftrace/thread_state_tracker.h",
- "importers/ftrace/v4l2_tracker.cc",
- "importers/ftrace/v4l2_tracker.h",
- "importers/ftrace/virtio_video_tracker.cc",
- "importers/ftrace/virtio_video_tracker.h",
- "importers/fuchsia/fuchsia_record.cc",
- "importers/fuchsia/fuchsia_trace_parser.cc",
- "importers/fuchsia/fuchsia_trace_parser.h",
- "importers/fuchsia/fuchsia_trace_tokenizer.cc",
- "importers/fuchsia/fuchsia_trace_tokenizer.h",
- "importers/fuchsia/fuchsia_trace_utils.cc",
- "importers/gzip/gzip_trace_parser.cc",
- "importers/gzip/gzip_trace_parser.h",
- "importers/i2c/i2c_tracker.cc",
- "importers/i2c/i2c_tracker.h",
- "importers/json/json_trace_parser.cc",
- "importers/json/json_trace_parser.h",
- "importers/json/json_trace_tokenizer.cc",
- "importers/json/json_trace_tokenizer.h",
- "importers/proto/android_probes_module.cc",
- "importers/proto/android_probes_module.h",
- "importers/proto/android_probes_parser.cc",
- "importers/proto/android_probes_parser.h",
- "importers/proto/android_probes_tracker.cc",
- "importers/proto/android_probes_tracker.h",
- "importers/proto/content_analyzer.cc",
- "importers/proto/content_analyzer.h",
- "importers/proto/frame_timeline_event_parser.cc",
- "importers/proto/frame_timeline_event_parser.h",
- "importers/proto/gpu_event_parser.cc",
- "importers/proto/gpu_event_parser.h",
- "importers/proto/graphics_event_module.cc",
- "importers/proto/graphics_event_module.h",
- "importers/proto/graphics_frame_event_parser.cc",
- "importers/proto/graphics_frame_event_parser.h",
- "importers/proto/heap_graph_module.cc",
- "importers/proto/heap_graph_module.h",
- "importers/proto/system_probes_module.cc",
- "importers/proto/system_probes_module.h",
- "importers/proto/system_probes_parser.cc",
- "importers/proto/system_probes_parser.h",
- "importers/proto/vulkan_memory_tracker.cc",
- "importers/proto/vulkan_memory_tracker.h",
- "importers/syscalls/syscall_tracker.cc",
- "importers/systrace/systrace_line_parser.cc",
- "importers/systrace/systrace_line_parser.h",
- "importers/systrace/systrace_line_tokenizer.cc",
- "importers/systrace/systrace_line_tokenizer.h",
- "importers/systrace/systrace_parser.cc",
- "importers/systrace/systrace_parser.h",
- "importers/systrace/systrace_trace_parser.cc",
- "importers/systrace/systrace_trace_parser.h",
- ]
- public_deps = [ ":storage_minimal" ]
- deps = [
- ":ftrace_descriptors",
- "../../include/perfetto/ext/base:base",
- "../../include/perfetto/ext/traced:sys_stats_counters",
- "../../protos/perfetto/common:zero",
- "../../protos/perfetto/trace:zero",
- "../../protos/perfetto/trace/android:zero",
- "../../protos/perfetto/trace/gpu:zero",
- "../../protos/perfetto/trace/interned_data:zero",
- "../protozero",
- "importers:gen_cc_trace_descriptor",
- "importers/android_bugreport",
- "importers/common",
- "importers/proto:storage_full",
- "importers/proto:storage_minimal",
- "storage",
- "tables",
- "types",
- "util",
- "util:gzip",
- "util:proto_profiler",
- "views",
- ]
- if (enable_perfetto_trace_processor_json) {
- deps += [ "../../gn:jsoncpp" ]
- }
-}
-
source_set("export_json") {
sources = [
"export_json.cc",
@@ -355,7 +252,6 @@
deps = [
":metatrace",
- ":storage_full",
"../../gn:default_deps",
"../../protos/perfetto/trace/ftrace:zero",
"../base",
@@ -363,6 +259,7 @@
"analysis",
"db",
"dynamic",
+ "importers:importers_full",
"importers/android_bugreport",
"importers/common",
"metrics",
@@ -447,7 +344,6 @@
]
deps = [
":gen_cc_test_messages_descriptor",
- ":storage_full",
"../../gn:default_deps",
"../../gn:gtest_and_gmock",
"../../protos/perfetto/common:cpp",
@@ -471,6 +367,7 @@
"containers:unittests",
"db:unittests",
"dynamic",
+ "importers:importers_full",
"importers/android_bugreport:unittests",
"importers/common",
"importers/common:unittests",
@@ -568,8 +465,8 @@
testonly = true
sources = [ "trace_parsing_fuzzer.cc" ]
deps = [
- ":storage_full",
"../../gn:default_deps",
"../base",
+ "importers:importers_full",
]
}
diff --git a/src/trace_processor/importers/BUILD.gn b/src/trace_processor/importers/BUILD.gn
index ae9b7be..d16cf68 100644
--- a/src/trace_processor/importers/BUILD.gn
+++ b/src/trace_processor/importers/BUILD.gn
@@ -14,6 +14,110 @@
import("../../../gn/perfetto_cc_proto_descriptor.gni")
+source_set("importers_full") {
+ sources = [
+ "additional_modules.cc",
+ "additional_modules.h",
+ "ftrace/binder_tracker.cc",
+ "ftrace/binder_tracker.h",
+ "ftrace/drm_tracker.cc",
+ "ftrace/drm_tracker.h",
+ "ftrace/ftrace_module_impl.cc",
+ "ftrace/ftrace_module_impl.h",
+ "ftrace/ftrace_parser.cc",
+ "ftrace/ftrace_parser.h",
+ "ftrace/ftrace_tokenizer.cc",
+ "ftrace/ftrace_tokenizer.h",
+ "ftrace/iostat_tracker.cc",
+ "ftrace/iostat_tracker.h",
+ "ftrace/rss_stat_tracker.cc",
+ "ftrace/rss_stat_tracker.h",
+ "ftrace/sched_event_tracker.cc",
+ "ftrace/sched_event_tracker.h",
+ "ftrace/thread_state_tracker.cc",
+ "ftrace/thread_state_tracker.h",
+ "ftrace/v4l2_tracker.cc",
+ "ftrace/v4l2_tracker.h",
+ "ftrace/virtio_video_tracker.cc",
+ "ftrace/virtio_video_tracker.h",
+ "fuchsia/fuchsia_trace_parser.cc",
+ "fuchsia/fuchsia_trace_parser.h",
+ "fuchsia/fuchsia_trace_tokenizer.cc",
+ "fuchsia/fuchsia_trace_tokenizer.h",
+ "fuchsia/fuchsia_trace_utils.cc",
+ "gzip/gzip_trace_parser.cc",
+ "gzip/gzip_trace_parser.h",
+ "i2c/i2c_tracker.cc",
+ "i2c/i2c_tracker.h",
+ "json/json_trace_parser.cc",
+ "json/json_trace_parser.h",
+ "json/json_trace_tokenizer.cc",
+ "json/json_trace_tokenizer.h",
+ "proto/android_probes_module.cc",
+ "proto/android_probes_module.h",
+ "proto/android_probes_parser.cc",
+ "proto/android_probes_parser.h",
+ "proto/android_probes_tracker.cc",
+ "proto/android_probes_tracker.h",
+ "proto/content_analyzer.cc",
+ "proto/content_analyzer.h",
+ "proto/frame_timeline_event_parser.cc",
+ "proto/frame_timeline_event_parser.h",
+ "proto/gpu_event_parser.cc",
+ "proto/gpu_event_parser.h",
+ "proto/graphics_event_module.cc",
+ "proto/graphics_event_module.h",
+ "proto/graphics_frame_event_parser.cc",
+ "proto/graphics_frame_event_parser.h",
+ "proto/heap_graph_module.cc",
+ "proto/heap_graph_module.h",
+ "proto/system_probes_module.cc",
+ "proto/system_probes_module.h",
+ "proto/system_probes_parser.cc",
+ "proto/system_probes_parser.h",
+ "proto/vulkan_memory_tracker.cc",
+ "proto/vulkan_memory_tracker.h",
+ "syscalls/syscall_tracker.cc",
+ "systrace/systrace_line_parser.cc",
+ "systrace/systrace_line_parser.h",
+ "systrace/systrace_line_tokenizer.cc",
+ "systrace/systrace_line_tokenizer.h",
+ "systrace/systrace_parser.cc",
+ "systrace/systrace_parser.h",
+ "systrace/systrace_trace_parser.cc",
+ "systrace/systrace_trace_parser.h",
+ ]
+ public_deps = [ "../:storage_minimal" ]
+ deps = [
+ ":gen_cc_trace_descriptor",
+ "../:ftrace_descriptors",
+ "../../../include/perfetto/ext/base:base",
+ "../../../include/perfetto/ext/traced:sys_stats_counters",
+ "../../../protos/perfetto/common:zero",
+ "../../../protos/perfetto/trace:zero",
+ "../../../protos/perfetto/trace/android:zero",
+ "../../../protos/perfetto/trace/gpu:zero",
+ "../../../protos/perfetto/trace/interned_data:zero",
+ "../../protozero",
+ "../storage",
+ "../tables",
+ "../types",
+ "../util",
+ "../util:gzip",
+ "../util:proto_profiler",
+ "../views",
+ "android_bugreport",
+ "common",
+ "fuchsia:fuchsia_record",
+ "proto:storage_full",
+ "proto:storage_minimal",
+ "systrace:systrace_line",
+ ]
+ if (enable_perfetto_trace_processor_json) {
+ deps += [ "../../../gn:jsoncpp" ]
+ }
+}
+
perfetto_cc_proto_descriptor("gen_cc_statsd_atoms_descriptor") {
descriptor_name = "atoms.descriptor"
descriptor_path = "./proto/atoms.descriptor"
diff --git a/src/trace_processor/importers/common/BUILD.gn b/src/trace_processor/importers/common/BUILD.gn
index eb33f16..8cf4ce0 100644
--- a/src/trace_processor/importers/common/BUILD.gn
+++ b/src/trace_processor/importers/common/BUILD.gn
@@ -39,11 +39,11 @@
"slice_translation_table.h",
"system_info_tracker.cc",
"system_info_tracker.h",
- "trace_parser.h",
"track_tracker.cc",
"track_tracker.h",
]
public_deps = [
+ ":trace_parser",
"../:gen_cc_config_descriptor",
"../../util:proto_to_args_parser",
"../../util:protozero_to_text",
@@ -61,6 +61,11 @@
]
}
+source_set("trace_parser") {
+ sources = [ "trace_parser.h" ]
+ deps = [ "../../../../gn:default_deps" ]
+}
+
source_set("unittests") {
sources = [
"args_translation_table_unittest.cc",
diff --git a/src/trace_processor/importers/fuchsia/BUILD.gn b/src/trace_processor/importers/fuchsia/BUILD.gn
new file mode 100644
index 0000000..65ca92d
--- /dev/null
+++ b/src/trace_processor/importers/fuchsia/BUILD.gn
@@ -0,0 +1,25 @@
+# Copyright (C) 2022 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+source_set("fuchsia_record") {
+ sources = [
+ "fuchsia_record.cc",
+ "fuchsia_record.h",
+ ]
+ deps = [
+ "../../../../gn:default_deps",
+ "../../../../include/perfetto/trace_processor:storage",
+ "../../containers",
+ ]
+}
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_record.cc b/src/trace_processor/importers/fuchsia/fuchsia_record.cc
index dfe70a6..2819e20 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_record.cc
+++ b/src/trace_processor/importers/fuchsia/fuchsia_record.cc
@@ -19,7 +19,7 @@
namespace perfetto {
namespace trace_processor {
-void FuchsiaRecord::InsertString(uint32_t index, StringId string_id) {
+void FuchsiaRecord::InsertString(uint32_t index, StringPool::Id string_id) {
StringTableEntry entry;
entry.index = index;
entry.string_id = string_id;
@@ -27,16 +27,15 @@
string_entries_.push_back(entry);
}
-StringId FuchsiaRecord::GetString(uint32_t index) {
+StringPool::Id FuchsiaRecord::GetString(uint32_t index) {
for (const auto& entry : string_entries_) {
if (entry.index == index)
return entry.string_id;
}
- return StringId();
+ return StringPool::Id();
}
-void FuchsiaRecord::InsertThread(uint32_t index,
- fuchsia_trace_utils::ThreadInfo info) {
+void FuchsiaRecord::InsertThread(uint32_t index, FuchsiaThreadInfo info) {
ThreadTableEntry entry;
entry.index = index;
entry.info = info;
@@ -44,12 +43,12 @@
thread_entries_.push_back(entry);
}
-fuchsia_trace_utils::ThreadInfo FuchsiaRecord::GetThread(uint32_t index) {
+FuchsiaThreadInfo FuchsiaRecord::GetThread(uint32_t index) {
for (const auto& entry : thread_entries_) {
if (entry.index == index)
return entry.info;
}
- return fuchsia_trace_utils::ThreadInfo();
+ return FuchsiaThreadInfo();
}
} // namespace trace_processor
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_record.h b/src/trace_processor/importers/fuchsia/fuchsia_record.h
index f90d039..a2b4dd4 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_record.h
+++ b/src/trace_processor/importers/fuchsia/fuchsia_record.h
@@ -18,14 +18,18 @@
#define SRC_TRACE_PROCESSOR_IMPORTERS_FUCHSIA_FUCHSIA_RECORD_H_
#include "perfetto/trace_processor/trace_blob_view.h"
-#include "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h"
-#include "src/trace_processor/storage/trace_storage.h"
+#include "src/trace_processor/containers/string_pool.h"
#include <vector>
namespace perfetto {
namespace trace_processor {
+struct FuchsiaThreadInfo {
+ uint64_t pid;
+ uint64_t tid;
+};
+
// Data from a trace provider that is necessary for interpreting a binary
// record. Namely, the record itself and the entries of the string table and the
// thread table that are referenced by the record. This enables understanding
@@ -37,19 +41,19 @@
struct StringTableEntry {
uint32_t index;
- StringId string_id;
+ StringPool::Id string_id;
};
struct ThreadTableEntry {
uint32_t index;
- fuchsia_trace_utils::ThreadInfo info;
+ FuchsiaThreadInfo info;
};
- void InsertString(uint32_t, StringId);
- StringId GetString(uint32_t);
+ void InsertString(uint32_t, StringPool::Id);
+ StringPool::Id GetString(uint32_t);
- void InsertThread(uint32_t, fuchsia_trace_utils::ThreadInfo);
- fuchsia_trace_utils::ThreadInfo GetThread(uint32_t);
+ void InsertThread(uint32_t, FuchsiaThreadInfo);
+ FuchsiaThreadInfo GetThread(uint32_t);
void set_ticks_per_second(uint64_t ticks_per_second) {
ticks_per_second_ = ticks_per_second;
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc b/src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc
index b84c383..e36da64 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc
+++ b/src/trace_processor/importers/fuchsia/fuchsia_trace_parser.cc
@@ -22,6 +22,7 @@
#include "src/trace_processor/importers/common/process_tracker.h"
#include "src/trace_processor/importers/common/slice_tracker.h"
#include "src/trace_processor/importers/common/track_tracker.h"
+#include "src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h"
#include "src/trace_processor/importers/proto/proto_trace_parser.h"
namespace perfetto {
@@ -106,7 +107,7 @@
context_->storage->IncrementStats(stats::fuchsia_invalid_event);
return;
}
- fuchsia_trace_utils::ThreadInfo tinfo;
+ FuchsiaThreadInfo tinfo;
if (fuchsia_trace_utils::IsInlineThread(thread_ref)) {
if (!cursor.ReadInlineThread(&tinfo)) {
context_->storage->IncrementStats(stats::fuchsia_invalid_event);
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc b/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc
index 209e918..204be80 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc
+++ b/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.cc
@@ -269,7 +269,7 @@
case kThread: {
uint32_t index = fuchsia_trace_utils::ReadField<uint32_t>(header, 16, 23);
if (index != 0) {
- fuchsia_trace_utils::ThreadInfo tinfo;
+ FuchsiaThreadInfo tinfo;
if (!cursor.ReadInlineThread(&tinfo)) {
context_->storage->IncrementStats(stats::fuchsia_invalid_event);
return;
@@ -514,7 +514,7 @@
return;
}
- fuchsia_trace_utils::ThreadInfo outgoing_thread;
+ FuchsiaThreadInfo outgoing_thread;
if (fuchsia_trace_utils::IsInlineThread(outgoing_thread_ref)) {
if (!cursor.ReadInlineThread(&outgoing_thread)) {
context_->storage->IncrementStats(stats::fuchsia_invalid_event);
@@ -524,7 +524,7 @@
outgoing_thread = current_provider_->thread_table[outgoing_thread_ref];
}
- fuchsia_trace_utils::ThreadInfo incoming_thread;
+ FuchsiaThreadInfo incoming_thread;
if (fuchsia_trace_utils::IsInlineThread(incoming_thread_ref)) {
if (!cursor.ReadInlineThread(&incoming_thread)) {
context_->storage->IncrementStats(stats::fuchsia_invalid_event);
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h b/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h
index be6f22f..3895d38 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h
+++ b/src/trace_processor/importers/fuchsia/fuchsia_trace_tokenizer.h
@@ -43,13 +43,13 @@
std::string name;
std::unordered_map<uint64_t, StringId> string_table;
- std::unordered_map<uint64_t, fuchsia_trace_utils::ThreadInfo> thread_table;
+ std::unordered_map<uint64_t, FuchsiaThreadInfo> thread_table;
uint64_t ticks_per_second = 1000000000;
};
struct RunningThread {
- fuchsia_trace_utils::ThreadInfo info;
+ FuchsiaThreadInfo info;
int64_t start_ts;
};
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc b/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc
index 6d993ba..d7879be 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc
+++ b/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.cc
@@ -126,7 +126,7 @@
return true;
}
-bool RecordCursor::ReadInlineThread(ThreadInfo* thread_out) {
+bool RecordCursor::ReadInlineThread(FuchsiaThreadInfo* thread_out) {
const uint8_t* thread_data;
if (!ReadWords(2, &thread_data)) {
return false;
diff --git a/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h b/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h
index 37dca54..f4ae231 100644
--- a/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h
+++ b/src/trace_processor/importers/fuchsia/fuchsia_trace_utils.h
@@ -23,17 +23,13 @@
#include "perfetto/ext/base/string_view.h"
#include "perfetto/trace_processor/trace_blob_view.h"
+#include "src/trace_processor/importers/fuchsia/fuchsia_record.h"
#include "src/trace_processor/storage/trace_storage.h"
namespace perfetto {
namespace trace_processor {
namespace fuchsia_trace_utils {
-struct ThreadInfo {
- uint64_t pid;
- uint64_t tid;
-};
-
template <class T>
T ReadField(uint64_t word, size_t begin, size_t end) {
return static_cast<T>((word >> begin) &
@@ -204,7 +200,7 @@
bool ReadTimestamp(uint64_t ticks_per_second, int64_t* ts_out);
bool ReadInlineString(uint32_t string_ref_or_len,
base::StringView* string_out);
- bool ReadInlineThread(ThreadInfo* thread_out);
+ bool ReadInlineThread(FuchsiaThreadInfo* thread_out);
bool ReadInt64(int64_t* out);
bool ReadUint64(uint64_t* out);
diff --git a/src/trace_processor/importers/systrace/BUILD.gn b/src/trace_processor/importers/systrace/BUILD.gn
new file mode 100644
index 0000000..28f82ba
--- /dev/null
+++ b/src/trace_processor/importers/systrace/BUILD.gn
@@ -0,0 +1,21 @@
+# Copyright (C) 2022 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+source_set("systrace_line") {
+ sources = [ "systrace_line.h" ]
+ deps = [
+ "../../../../gn:default_deps",
+ "../../containers",
+ ]
+}