third_party.pigweed.src/pw_metric/size_report/BUILD
Keir Mierle 9b51cdf629 pw_metric: Add size report
This adds a size report for pw_metric, not including the RPC service.
The report shows the impact of having a few metrics, of dumping, and of
adding more metrics.

At this time, the flash usage on Cortex-M4 is unexpectedly large due to
the creation of large static constructors. This will require followup
CLs to address.

This CL also moves a few inlined methods from the .h file into the .cc
to reduce code size.

Change-Id: Ie0cb041a6e1e5e77c921e9078adea2eaabccdd43
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/16300
Commit-Queue: Keir Mierle <keir@google.com>
Reviewed-by: Alexei Frolov <frolv@google.com>
2020-08-20 22:46:37 +00:00

66 lines
1.5 KiB
Python

# Copyright 2020 The Pigweed Authors
#
# 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
#
# https://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.
load(
"//pw_build:pigweed.bzl",
"pw_cc_binary",
)
package(default_visibility = ["//visibility:public"])
licenses(["notice"]) # Apache License 2.0
pw_cc_binary(
name = "base",
srcs = ["base.cc"],
deps = [
"//pw_bloat:bloat_this_binary",
"//pw_log",
"//pw_assert",
],
)
pw_cc_binary(
name = "one_metric",
srcs = ["one_metric.cc"],
deps = [
"//pw_bloat:bloat_this_binary",
"//pw_metric",
"//pw_log",
"//pw_assert",
],
)
pw_cc_binary(
name = "dump",
srcs = ["dump.cc"],
deps = [
"//pw_bloat:bloat_this_binary",
"//pw_metric",
"//pw_log",
"//pw_assert",
],
)
pw_cc_binary(
name = "more_metrics",
srcs = ["more_metrics.cc"],
deps = [
"//pw_bloat:bloat_this_binary",
"//pw_metric",
"//pw_log",
"//pw_assert",
],
)