metrics: expose generic metrics computation api in trace processor
This allows clients to pass in the metrics they want to compute without
having to recompile trace processor.
This means that the metrics code has no dependencies on sql_metrics (i.e.
the builtin metrics compiled into trace processor using
gen_merged_sql_metrics), change that code to be passed the relevant
information.
Instead, this mapping is now done inside trace processor impl at the API
level with both old and new api calling down into the same metrics
pipeline.
Bug: 129747127
Change-Id: Icba8322ad3e0be1176d58206004e8dd339e91c45
diff --git a/src/trace_processor/metrics/BUILD.gn b/src/trace_processor/metrics/BUILD.gn
index b05d0cd..7bea83a 100644
--- a/src/trace_processor/metrics/BUILD.gn
+++ b/src/trace_processor/metrics/BUILD.gn
@@ -47,7 +47,6 @@
"metrics.h",
]
deps = [
- ":gen_merged_sql_metrics",
"../../../buildtools:sqlite",
"../../../gn:default_deps",
"../../../include/perfetto/trace_processor",
@@ -56,6 +55,9 @@
"../../../protos/perfetto/metrics/android:zero",
"../../protozero:protozero",
]
+ public_deps = [
+ ":gen_merged_sql_metrics",
+ ]
}
source_set("unittests") {