client: Always use GPU model name from OpenCL if available for ATI / AMD GPUs

svn path=/trunk/boinc/; revision=25276
This commit is contained in:
Charlie Fenton 2012-02-17 00:31:14 +00:00
parent 7ee9f28e54
commit aed729dbcd
1 changed files with 13 additions and 4 deletions

View File

@ -429,10 +429,19 @@ strcpy(prop.opencl_driver_version, "CLH 1.0");
#endif
if (ati.have_cal) {
// Always use GPU model name from OpenCL if available for ATI / AMD
// GPUs because (we believe) it is more reliable and user-friendly.
// Assumes OpenCL and CAL return the devices in the same order
strcpy(ati_gpus[prop.device_num].name, prop.name);
if (prop.device_num < (int)(ati_gpus.size())) {
// Always use GPU model name from OpenCL if available for ATI / AMD
// GPUs because (we believe) it is more reliable and user-friendly.
// Assumes OpenCL and CAL return the devices in the same order
strcpy(ati_gpus[prop.device_num].name, prop.name);
} else {
if (log_flags.coproc_debug) {
msg_printf(0, MSG_INFO,
"[coproc] OpenCL ATI device #%d does not match any CAL device",
device_index
);
}
}
} else {
COPROC_ATI c;
c.opencl_prop = prop;