我的笔记本电脑配备ATI Radeon 4500显卡和Intel(R)Core(TM)2 Duo CPU P8700 2.53GHz作为CPU。当我查询OpenCL的平台时,输出是这样的:
Found 2 Platforms
==================Platform No 0======================
CL_PLATFORM_NAME : AMD Accelerated Parallel Processing
CL_PLATFORM_VENDOR : Advanced Micro Devices, Inc.
CL_PLATFORM_VERSION: OpenCL 1.2 AMD-APP (937.2)
CL_PLATFORM_PROFILE: FULL_PROFILE
CL_PLATFORM_EXTENSIONS: cl_khr_icd cl_amd_event_callback cl_amd_offline_devices
======================================================
==================Platform No 1======================
CL_PLATFORM_NAME : Intel(R) OpenCL
CL_PLATFORM_VENDOR : Intel(R) Corporation
CL_PLATFORM_VERSION: OpenCL 1.2 LINUX
CL_PLATFORM_PROFILE: FULL_PROFILE
CL_PLATFORM_EXTENSIONS: cl_khr_icd cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_byte_addressable_store cl_khr_spir cl_intel_exec_by_local_thread cl_khr_depth_images cl_khr_3d_image_writes cl_khr_fp64
======================================================
当我查询opencl设备时,输出就像这样
Number of OpenCL platforms available in the system: 2
Printing OpenCL Device Info For Platform ID : 0
==================Device No 0======================
CL_DEVICE_NAME: ATI RV710
CL_DEVICE_VENDOR: Advanced Micro Devices, Inc.
CL_DRIVER_VERSION: CAL 1.4.1734
CL_DEVICE_VERSION: OpenCL 1.0 AMD-APP (937.2)
CL_DEVICE_MAX_COMPUTE_UNITS: 2
====================================================
==================Device No 1======================
CL_DEVICE_NAME: Intel(R) Core(TM)2 Duo CPU P8700 @ 2.53GHz
CL_DEVICE_VENDOR: GenuineIntel
CL_DRIVER_VERSION: 2.0 (sse2)
CL_DEVICE_VERSION: OpenCL 1.2 AMD-APP (937.2)
CL_DEVICE_MAX_COMPUTE_UNITS: 2
====================================================
Printing OpenCL Device Info For Platform ID : 1
==================Device No 0======================
CL_DEVICE_NAME: Intel(R) Core(TM)2 Duo CPU P8700 @ 2.53GHz
CL_DEVICE_VENDOR: Intel(R) Corporation
CL_DRIVER_VERSION: 1.2.0.92
CL_DEVICE_VERSION: OpenCL 1.2 (Build 92)
CL_DEVICE_MAX_COMPUTE_UNITS: 2
====================================================
我觉得有些不对劲。因为在属于图形卡的Platform ID 0中有两个设备。一个用于AMD(ATI),另一个用于英特尔。但是在属于Intel CPU的Platform ID 1中,只有一个设备。 我已经安装了AMD APP和Intel OpenCL库。 我可以在AMD Codex软件中看到这个输出,我确信代码的输出。 为什么ATI(AMD)显卡显示两个设备,而我在CPU中有两个内核。 我很困惑。 请帮忙。 谢谢
答案 0 :(得分:1)
AMD OpenCL实现支持CPU和AMD GPU。但是,英特尔OpenCL实现支持CPU以及英特尔GPU(至少在Windows系统上),但不支持AMD GPU。所以你的输出非常好,没有错。