Commit 720413e7 authored by Wez's avatar Wez Committed by Commit Bot

Set is_asan_build also in DCHECK-enabled binaries.

SystemProfile.is_asan_build was previously only set for ASAN builds. In
general we care about whether a build is standard, versus instrumented,
regardless of the kind of instrumentation, so we re-use this field to
also indicate DCHECK-enabled builds.

The field will be renamed to is_instrumented_build up-stream, to better
reflect its intended meaning.

Bug: 889105
Change-Id: Ieb0c54dcf53db298a101d29447987791e9b085e1
Reviewed-on: https://chromium-review.googlesource.com/c/1260516Reviewed-by: default avatarAlexei Svitkine <asvitkine@chromium.org>
Commit-Queue: Wez <wez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#596720}
parent 58266dad
......@@ -150,7 +150,9 @@ void MetricsLog::RecordCoreSystemProfile(MetricsServiceClient* client,
system_profile->set_channel(client->GetChannel());
system_profile->set_application_locale(client->GetApplicationLocale());
#if defined(ADDRESS_SANITIZER)
#if defined(ADDRESS_SANITIZER) || DCHECK_IS_ON()
// Set if a build is instrumented (e.g. built with ASAN, or with DCHECKs).
// TODO(889105): Field will be renamed to is_instrumented_build up-stream.
system_profile->set_is_asan_build(true);
#endif
......
......@@ -137,7 +137,8 @@ TEST_F(MetricsLogTest, BasicRecord) {
system_profile->set_channel(client.GetChannel());
system_profile->set_application_locale(client.GetApplicationLocale());
#if defined(ADDRESS_SANITIZER)
#if defined(ADDRESS_SANITIZER) || DCHECK_IS_ON()
// TODO(889105): Field will be renamed to is_instrumented_build up-stream.
system_profile->set_is_asan_build(true);
#endif
metrics::SystemProfileProto::Hardware* hardware =
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment