summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrouslan@chromium.org <rouslan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-13 01:32:34 +0000
committerrouslan@chromium.org <rouslan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-13 01:32:34 +0000
commit26c8862de79d12c36b2f7735ec9e51b03e201a82 (patch)
treeea824a96b4eabfdba1f974770f240b65283f7926
parent07212f3038bbcd3c7de2e7299d7c80478f8ba93a (diff)
downloadchromium_src-26c8862de79d12c36b2f7735ec9e51b03e201a82.zip
chromium_src-26c8862de79d12c36b2f7735ec9e51b03e201a82.tar.gz
chromium_src-26c8862de79d12c36b2f7735ec9e51b03e201a82.tar.bz2
Revert of Use the updated AMD switchable info collection code. (https://codereview.chromium.org/332843003/)
Reason for revert: The patch appears to have broken windows perf bot: http://build.chromium.org/p/chromium.perf/builders/Win%20Builder/builds/69732 Original issue's description: > Use the updated AMD switchable info collection code. > > BUG=376562 > TEST= > R=kbr@chromium.org > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=276865 TBR=kbr@chromium.org,zmo@chromium.org NOTREECHECKS=true NOTRY=true BUG=376562 Review URL: https://codereview.chromium.org/333683004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276879 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--gpu/config/gpu_info_collector.h2
-rw-r--r--gpu/config/gpu_info_collector_win.cc18
2 files changed, 6 insertions, 14 deletions
diff --git a/gpu/config/gpu_info_collector.h b/gpu/config/gpu_info_collector.h
index f16071b..f3d339e 100644
--- a/gpu/config/gpu_info_collector.h
+++ b/gpu/config/gpu_info_collector.h
@@ -66,8 +66,6 @@ GPU_EXPORT void MergeGPUInfoGL(GPUInfo* basic_gpu_info,
// Advanced Micro Devices has interesting configurations on laptops were
// there are two videocards that can alternatively a given process output.
-// TODO(zmo): remove them when we remove the GetAMDVideocardType() in the
-// internal src/third_party/amd.
enum AMDVideoCardType {
UNKNOWN,
STANDALONE,
diff --git a/gpu/config/gpu_info_collector_win.cc b/gpu/config/gpu_info_collector_win.cc
index 65d75ec..556842c 100644
--- a/gpu/config/gpu_info_collector_win.cc
+++ b/gpu/config/gpu_info_collector_win.cc
@@ -363,14 +363,13 @@ void CollectD3D11Support() {
} // namespace anonymous
#if !defined(GOOGLE_CHROME_BUILD)
-void GetAMDVideocardInfo(GPUInfo* gpu_info) {
- DCHECK(gpu_info);
- return;
+AMDVideoCardType GetAMDVideocardType() {
+ return STANDALONE;
}
#else
// This function has a real implementation for official builds that can
// be found in src/third_party/amd.
-void GetAMDVideocardInfo(GPUInfo* gpu_info);
+AMDVideoCardType GetAMDVideocardType();
#endif
bool CollectDriverInfoD3D(const std::wstring& device_id,
@@ -434,14 +433,9 @@ bool CollectDriverInfoD3D(const std::wstring& device_id,
// signal the videocard is assumed to be switchable. Additionally,
// some switchable systems with Intel GPUs aren't correctly
// detected, so always count them.
- GetAMDVideocardInfo(gpu_info);
- if (!gpu_info->amd_switchable &&
- gpu_info->gpu.vendor_id == 0x8086) {
- gpu_info->amd_switchable = true;
- gpu_info->secondary_gpus.push_back(gpu_info->gpu);
- gpu_info->gpu.vendor_id = 0x1002;
- gpu_info->gpu.device_id = 0; // Unknown discrete AMD GPU.
- }
+ AMDVideoCardType amd_card_type = GetAMDVideocardType();
+ gpu_info->amd_switchable = (gpu_info->gpu.vendor_id == 0x8086) ||
+ (amd_card_type != STANDALONE);
}
}