Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(222)

Side by Side Diff: content/browser/gpu/gpu_data_manager_impl_private.cc

Issue 2781833003: Only use overlays on windows 10 anniversary update and later. (Closed)
Patch Set: rebase Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « base/win/windows_version.cc ('k') | gpu/ipc/service/direct_composition_surface_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/gpu/gpu_data_manager_impl_private.h" 5 #include "content/browser/gpu/gpu_data_manager_impl_private.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <iterator> 8 #include <iterator>
9 #include <memory> 9 #include <memory>
10 #include <utility> 10 #include <utility>
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 67
68 enum WinSubVersion { 68 enum WinSubVersion {
69 kWinOthers = 0, 69 kWinOthers = 0,
70 kWinXP, 70 kWinXP,
71 kWinVista, 71 kWinVista,
72 kWin7, 72 kWin7,
73 kWin8, 73 kWin8,
74 kWin8_1, 74 kWin8_1,
75 kWin10, 75 kWin10,
76 kWin10_TH2, 76 kWin10_TH2,
77 kWin10_R1,
77 kNumWinSubVersions 78 kNumWinSubVersions
78 }; 79 };
79 80
80 int GetGpuBlacklistHistogramValueWin(gpu::GpuFeatureStatus status) { 81 int GetGpuBlacklistHistogramValueWin(gpu::GpuFeatureStatus status) {
81 static WinSubVersion sub_version = kNumWinSubVersions; 82 static WinSubVersion sub_version = kNumWinSubVersions;
82 if (sub_version == kNumWinSubVersions) { 83 if (sub_version == kNumWinSubVersions) {
83 sub_version = kWinOthers; 84 sub_version = kWinOthers;
84 switch (base::win::GetVersion()) { 85 switch (base::win::GetVersion()) {
85 case base::win::VERSION_PRE_XP: 86 case base::win::VERSION_PRE_XP:
86 case base::win::VERSION_XP: 87 case base::win::VERSION_XP:
87 case base::win::VERSION_SERVER_2003: 88 case base::win::VERSION_SERVER_2003:
88 case base::win::VERSION_VISTA: 89 case base::win::VERSION_VISTA:
89 case base::win::VERSION_WIN_LAST: 90 case base::win::VERSION_WIN_LAST:
90 break; 91 break;
91 case base::win::VERSION_WIN7: 92 case base::win::VERSION_WIN7:
92 sub_version = kWin7; 93 sub_version = kWin7;
93 break; 94 break;
94 case base::win::VERSION_WIN8: 95 case base::win::VERSION_WIN8:
95 sub_version = kWin8; 96 sub_version = kWin8;
96 break; 97 break;
97 case base::win::VERSION_WIN8_1: 98 case base::win::VERSION_WIN8_1:
98 sub_version = kWin8_1; 99 sub_version = kWin8_1;
99 break; 100 break;
100 case base::win::VERSION_WIN10: 101 case base::win::VERSION_WIN10:
101 sub_version = kWin10; 102 sub_version = kWin10;
102 break; 103 break;
103 case base::win::VERSION_WIN10_TH2: 104 case base::win::VERSION_WIN10_TH2:
104 sub_version = kWin10_TH2; 105 sub_version = kWin10_TH2;
105 break; 106 break;
107 case base::win::VERSION_WIN10_R1:
108 sub_version = kWin10_R1;
109 break;
106 } 110 }
107 } 111 }
108 int entry_index = static_cast<int>(sub_version) * gpu::kGpuFeatureStatusMax; 112 int entry_index = static_cast<int>(sub_version) * gpu::kGpuFeatureStatusMax;
109 switch (status) { 113 switch (status) {
110 case gpu::kGpuFeatureStatusEnabled: 114 case gpu::kGpuFeatureStatusEnabled:
111 break; 115 break;
112 case gpu::kGpuFeatureStatusBlacklisted: 116 case gpu::kGpuFeatureStatusBlacklisted:
113 entry_index++; 117 entry_index++;
114 break; 118 break;
115 case gpu::kGpuFeatureStatusDisabled: 119 case gpu::kGpuFeatureStatusDisabled:
(...skipping 1272 matching lines...) Expand 10 before | Expand all | Expand 10 after
1388 gpu_info_.context_info_state = gpu::kCollectInfoFatalFailure; 1392 gpu_info_.context_info_state = gpu::kCollectInfoFatalFailure;
1389 #if defined(OS_WIN) 1393 #if defined(OS_WIN)
1390 gpu_info_.dx_diagnostics_info_state = gpu::kCollectInfoFatalFailure; 1394 gpu_info_.dx_diagnostics_info_state = gpu::kCollectInfoFatalFailure;
1391 #endif 1395 #endif
1392 complete_gpu_info_already_requested_ = true; 1396 complete_gpu_info_already_requested_ = true;
1393 // Some observers might be waiting. 1397 // Some observers might be waiting.
1394 NotifyGpuInfoUpdate(); 1398 NotifyGpuInfoUpdate();
1395 } 1399 }
1396 1400
1397 } // namespace content 1401 } // namespace content
OLDNEW
« no previous file with comments | « base/win/windows_version.cc ('k') | gpu/ipc/service/direct_composition_surface_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698