Chromium Code Reviews| Index: gpu/config/gpu_control_list.cc |
| diff --git a/gpu/config/gpu_control_list.cc b/gpu/config/gpu_control_list.cc |
| index 5eb09c489f166345f9c8d3f5e3eabc206f5a86dd..9548884ca6dd14fea413811e68abd32e4ab47665 100644 |
| --- a/gpu/config/gpu_control_list.cc |
| +++ b/gpu/config/gpu_control_list.cc |
| @@ -10,6 +10,7 @@ |
| #include "base/strings/string_number_conversions.h" |
| #include "base/strings/string_split.h" |
| #include "base/strings/string_util.h" |
| +#include "base/strings/stringprintf.h" |
| #include "base/sys_info.h" |
| #include "gpu/config/gpu_info.h" |
| #include "gpu/config/gpu_util.h" |
| @@ -1036,6 +1037,12 @@ GpuControlList::GpuControlListEntry::StringToMultiGpuCategory( |
| return kMultiGpuCategoryNone; |
| } |
| +void GpuControlList::GpuControlListEntry::LogBlacklistMatch() const { |
| + static const char kDisabledFeaturesMessage[] = |
| + "Blacklist match for rule #%u."; |
| + LOG(INFO) << base::StringPrintf(kDisabledFeaturesMessage, id_); |
|
gab
2013/08/27 22:24:12
Used this to debug locally and via try jobs along
Zhenyao Mo
2013/08/27 22:50:41
Use LogControlListMatch() instead and also the mes
gab
2013/08/28 20:20:39
Done.
|
| +} |
| + |
| bool GpuControlList::GpuControlListEntry::Contains( |
| OsType os_type, const std::string& os_version, |
| const GPUInfo& gpu_info) const { |
| @@ -1189,7 +1196,8 @@ bool GpuControlList::GpuControlListEntry::StringToFeature( |
| } |
| GpuControlList::GpuControlList() |
| - : max_entry_id_(0), |
| + : blacklist_logging_enabled_(false), |
| + max_entry_id_(0), |
| contains_unknown_fields_(false), |
| needs_more_info_(false), |
| supports_feature_type_all_(false) { |
| @@ -1309,6 +1317,8 @@ std::set<int> GpuControlList::MakeDecision( |
| for (size_t i = 0; i < entries_.size(); ++i) { |
| if (entries_[i]->Contains(os, os_version, gpu_info)) { |
| if (!entries_[i]->disabled()) { |
| + if (blacklist_logging_enabled_) |
|
Zhenyao Mo
2013/08/27 22:50:41
same, control_list_logging_enabled_ instead.
gab
2013/08/28 20:20:39
Done.
|
| + entries_[i]->LogBlacklistMatch(); |
| MergeFeatureSets(&possible_features, entries_[i]->features()); |
| if (!entries_[i]->NeedsMoreInfo(gpu_info)) |
| MergeFeatureSets(&features, entries_[i]->features()); |