Trace Redaction - Broadphase Filtering
Previously, whole packets were dropped when they did not pass the
allow-list check. This meant important information abount
packet-to-packet timing and data-loss was removed.
This CL changes all broadphase filtering code to use a mask. This
is applied at the packet level and at the ftrace event packet.
This has shown important differences when viewing traces as additional
CPU time used by the target process increases.
A side effect of this change is non-target timeline information has
also showed up. An additional change will be needed to address the
timeline information.
Change-Id: I0d042b48a0c9cc4086e1c07f3072807593ba99dc
diff --git a/Android.bp b/Android.bp
index 09433f2..53cabd1 100644
--- a/Android.bp
+++ b/Android.bp
@@ -13603,10 +13603,10 @@
filegroup {
name: "perfetto_src_trace_redaction_trace_redaction",
srcs: [
+ "src/trace_redaction/broadphase_packet_filter.cc",
"src/trace_redaction/collect_frame_cookies.cc",
"src/trace_redaction/collect_system_info.cc",
"src/trace_redaction/collect_timeline_events.cc",
- "src/trace_redaction/filter_packet_using_allowlist.cc",
"src/trace_redaction/filtering.cc",
"src/trace_redaction/find_package_uid.cc",
"src/trace_redaction/merge_threads.cc",
@@ -13631,11 +13631,10 @@
filegroup {
name: "perfetto_src_trace_redaction_unittests",
srcs: [
+ "src/trace_redaction/broadphase_packet_filter_unittest.cc",
"src/trace_redaction/collect_frame_cookies_unittest.cc",
"src/trace_redaction/collect_system_info_unittest.cc",
"src/trace_redaction/collect_timeline_events_unittest.cc",
- "src/trace_redaction/filter_ftrace_using_allowlist_unittest.cc",
- "src/trace_redaction/filter_packet_using_allowlist_unittest.cc",
"src/trace_redaction/filter_sched_waking_events_unittest.cc",
"src/trace_redaction/find_package_uid_unittest.cc",
"src/trace_redaction/process_thread_timeline_unittest.cc",