当前位置:   article > 正文

Ubuntu 18.04 CPU 安装 OpenCL_opencl下载

opencl下载

由于 Windows 驱动中自动包含了OpenCL驱动,但 Linux系统需要自己安装OpenCL驱动。

一开始打算在虚拟机中搭建Ubuntu 18.04 环境安装,但无论怎么搞都找不到核显,索性放弃,在电脑装了个ubuntu18.04 系统,重新搞,果然成功了,貌似是虚拟机中找不到核显 ,具体原因不详。

一:系统

Ubuntu18.04 + Intel(R)  Core(TM)  i7 8550U + Intel(R) UHD Graphics 620

二:安装

1. 下载 OpenCl  SDK  Choose & Download Intel® SDK for OpenCL™ Applications ,选择linux平台,解压。

        sudo ./install.sh

2. 安装 NEO  GitHub - intel/compute-runtime: Intel® Graphics Compute Runtime for oneAPI Level Zero and OpenCL™ Driver  选个版本(建议手动下载,要不下载速度太慢。)

  1. mkdir neo
  2. cd neo
  3. wget https://github.com/intel/compute-runtime/releases/download/19.51.15145/intel-gmmlib_19.3.4_amd64.deb
  4. wget https://github.com/intel/compute-runtime/releases/download/19.51.15145/intel-igc-core_1.0.3041_amd64.deb
  5. wget https://github.com/intel/compute-runtime/releases/download/19.51.15145/intel-igc-opencl_1.0.3041_amd64.deb
  6. wget https://github.com/intel/compute-runtime/releases/download/19.51.15145/intel-opencl_19.51.15145_amd64.deb
  7. wget https://github.com/intel/compute-runtime/releases/download/19.51.15145/intel-ocloc_19.51.15145_amd64.deb
  8. sudo dpkg -i *.deb

3. 安装 clinfo ​

        sudo apt-get install clinfo

4. 执行 clinfo

  1. Number of platforms 2
  2. Platform Name Intel(R) OpenCL
  3. Platform Vendor Intel(R) Corporation
  4. Platform Version OpenCL 2.0
  5. Platform Profile FULL_PROFILE
  6. Platform Extensions cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_depth_images cl_khr_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_icd cl_khr_image2d_from_buffer cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_spir
  7. Platform Extensions function suffix INTEL
  8. Platform Name Experimental OpenCL 2.1 CPU Only Platform
  9. Platform Vendor Intel(R) Corporation
  10. Platform Version OpenCL 2.1 LINUX
  11. Platform Profile FULL_PROFILE
  12. 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_depth_images cl_khr_3d_image_writes cl_intel_exec_by_local_thread cl_khr_spir cl_khr_fp64 cl_khr_image2d_from_buffer
  13. Platform Host timer resolution 1ns
  14. Platform Extensions function suffix INTEL
  15. Platform Name Intel(R) OpenCL
  16. Number of devices 2
  17. Device Name Intel(R) HD Graphics
  18. Device Vendor Intel(R) Corporation
  19. Device Vendor ID 0x8086
  20. Device Version OpenCL 2.0
  21. Driver Version r5.0.63503
  22. Device OpenCL C Version OpenCL C 2.0
  23. Device Type GPU
  24. Device Available Yes
  25. Device Profile FULL_PROFILE
  26. Max compute units 24
  27. Max clock frequency 1150MHz
  28. Device Partition (core)
  29. Max number of sub-devices 0
  30. Supported partition types None
  31. Max work item dimensions 3
  32. Max work item sizes 256x256x256
  33. Max work group size 256
  34. Compiler Available Yes
  35. Linker Available Yes
  36. Preferred work group size multiple 32
  37. Sub-group sizes (Intel) 8x16x32
  38. Preferred / native vector sizes
  39. char 16 / 16
  40. short 8 / 8
  41. int 4 / 4
  42. long 1 / 1
  43. half 8 / 8 (cl_khr_fp16)
  44. float 1 / 1
  45. double 1 / 1 (cl_khr_fp64)
  46. Half-precision Floating-point support (cl_khr_fp16)
  47. Denormals Yes
  48. Infinity and NANs Yes
  49. Round to nearest Yes
  50. Round to zero Yes
  51. Round to infinity Yes
  52. IEEE754-2008 fused multiply-add Yes
  53. Support is emulated in software No
  54. Correctly-rounded divide and sqrt operations No
  55. Single-precision Floating-point support (core)
  56. Denormals Yes
  57. Infinity and NANs Yes
  58. Round to nearest Yes
  59. Round to zero Yes
  60. Round to infinity Yes
  61. IEEE754-2008 fused multiply-add Yes
  62. Support is emulated in software No
  63. Correctly-rounded divide and sqrt operations Yes
  64. Double-precision Floating-point support (cl_khr_fp64)
  65. Denormals Yes
  66. Infinity and NANs Yes
  67. Round to nearest Yes
  68. Round to zero Yes
  69. Round to infinity Yes
  70. IEEE754-2008 fused multiply-add Yes
  71. Support is emulated in software No
  72. Correctly-rounded divide and sqrt operations No
  73. Address bits 64, Little-Endian
  74. Global memory size 13238812672 (12.33GiB)
  75. Error Correction support No
  76. Max memory allocation 4294959103 (4GiB)
  77. Unified memory for Host and Device Yes
  78. Shared Virtual Memory (SVM) capabilities (core)
  79. Coarse-grained buffer sharing Yes
  80. Fine-grained buffer sharing No
  81. Fine-grained system sharing No
  82. Atomics No
  83. Minimum alignment for any data type 128 bytes
  84. Alignment of base address 1024 bits (128 bytes)
  85. Preferred alignment for atomics
  86. SVM 64 bytes
  87. Global 64 bytes
  88. Local 64 bytes
  89. Max size for global variable 65536 (64KiB)
  90. Preferred total size of global vars 4294959103 (4GiB)
  91. Global Memory cache type Read/Write
  92. Global Memory cache size 524288 (512KiB)
  93. Global Memory cache line 64 bytes
  94. Image support Yes
  95. Max number of samplers per kernel 16
  96. Max size for 1D images from buffer 268434943 pixels
  97. Max 1D or 2D image array size 2048 images
  98. Base address alignment for 2D image buffers 4 bytes
  99. Pitch alignment for 2D image buffers 4 bytes
  100. Max 2D image size 16384x16384 pixels
  101. Max planar YUV image size 16384x16380 pixels
  102. Max 3D image size 16384x16384x2048 pixels
  103. Max number of read image args 128
  104. Max number of write image args 128
  105. Max number of read/write image args 128
  106. Max number of pipe args 16
  107. Max active pipe reservations 1
  108. Max pipe packet size 1024
  109. Local memory type Local
  110. Local memory size 65536 (64KiB)
  111. Max constant buffer size 4294959103 (4GiB)
  112. Max number of constant args 8
  113. Max size of kernel argument 1024
  114. Queue properties (on host)
  115. Out-of-order execution Yes
  116. Profiling Yes
  117. Queue properties (on device)
  118. Out-of-order execution Yes
  119. Profiling Yes
  120. Preferred size 131072 (128KiB)
  121. Max size 67108864 (64MiB)
  122. Max queues on device 1
  123. Max events on device 1024
  124. Prefer user sync for interop Yes
  125. Profiling timer resolution 83ns
  126. Execution capabilities
  127. Run OpenCL kernels Yes
  128. Run native kernels No
  129. SPIR versions 1.2
  130. printf() buffer size 4194304 (4MiB)
  131. Built-in kernels block_motion_estimate_intel;block_advanced_motion_estimate_check_intel;block_advanced_motion_estimate_bidirectional_check_intel
  132. Motion Estimation accelerator version (Intel) 2
  133. Device-side AVC Motion Estimation version 1
  134. Supports texture sampler use Yes
  135. Supports preemption No
  136. Device Extensions cl_intel_accelerator cl_intel_advanced_motion_estimation cl_intel_device_side_avc_motion_estimation cl_intel_driver_diagnostics cl_intel_media_block_io cl_intel_motion_estimation cl_intel_planar_yuv cl_intel_packed_yuv cl_intel_required_subgroup_size cl_intel_subgroups cl_intel_subgroups_short cl_intel_va_api_media_sharing cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_depth_images cl_khr_fp16 cl_khr_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_icd cl_khr_image2d_from_buffer cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_mipmap_image cl_khr_mipmap_image_writes cl_khr_spir cl_khr_subgroups
  137. Device Name Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz
  138. Device Vendor Intel(R) Corporation
  139. Device Vendor ID 0x8086
  140. Device Version OpenCL 2.0 (Build 475)
  141. Driver Version 1.2.0.475
  142. Device OpenCL C Version OpenCL C 2.0
  143. Device Type CPU
  144. Device Available Yes
  145. Device Profile FULL_PROFILE
  146. Max compute units 8
  147. Max clock frequency 3400MHz
  148. Device Partition (core)
  149. Max number of sub-devices 8
  150. Supported partition types by counts, equally, by names (Intel)
  151. Max work item dimensions 3
  152. Max work item sizes 8192x8192x8192
  153. Max work group size 8192
  154. Compiler Available Yes
  155. Linker Available Yes
  156. Preferred work group size multiple 128
  157. Preferred / native vector sizes
  158. char 1 / 32
  159. short 1 / 16
  160. int 1 / 8
  161. long 1 / 4
  162. half 0 / 0 (n/a)
  163. float 1 / 8
  164. double 1 / 4 (cl_khr_fp64)
  165. Half-precision Floating-point support (n/a)
  166. Single-precision Floating-point support (core)
  167. Denormals Yes
  168. Infinity and NANs Yes
  169. Round to nearest Yes
  170. Round to zero No
  171. Round to infinity No
  172. IEEE754-2008 fused multiply-add No
  173. Support is emulated in software No
  174. Correctly-rounded divide and sqrt operations No
  175. Double-precision Floating-point support (cl_khr_fp64)
  176. Denormals Yes
  177. Infinity and NANs Yes
  178. Round to nearest Yes
  179. Round to zero Yes
  180. Round to infinity Yes
  181. IEEE754-2008 fused multiply-add Yes
  182. Support is emulated in software No
  183. Correctly-rounded divide and sqrt operations No
  184. Address bits 64, Little-Endian
  185. Global memory size 16559001600 (15.42GiB)
  186. Error Correction support No
  187. Max memory allocation 4139750400 (3.855GiB)
  188. Unified memory for Host and Device Yes
  189. Shared Virtual Memory (SVM) capabilities (core)
  190. Coarse-grained buffer sharing Yes
  191. Fine-grained buffer sharing No
  192. Fine-grained system sharing No
  193. Atomics No
  194. Minimum alignment for any data type 128 bytes
  195. Alignment of base address 1024 bits (128 bytes)
  196. Preferred alignment for atomics
  197. SVM 64 bytes
  198. Global 64 bytes
  199. Local 0 bytes
  200. Max size for global variable 65536 (64KiB)
  201. Preferred total size of global vars 65536 (64KiB)
  202. Global Memory cache type Read/Write
  203. Global Memory cache size 262144 (256KiB)
  204. Global Memory cache line 64 bytes
  205. Image support Yes
  206. Max number of samplers per kernel 480
  207. Max size for 1D images from buffer 258734400 pixels
  208. Max 1D or 2D image array size 2048 images
  209. Base address alignment for 2D image buffers 64 bytes
  210. Pitch alignment for 2D image buffers 64 bytes
  211. Max 2D image size 16384x16384 pixels
  212. Max 3D image size 2048x2048x2048 pixels
  213. Max number of read image args 480
  214. Max number of write image args 480
  215. Max number of read/write image args 480
  216. Max number of pipe args 16
  217. Max active pipe reservations 32767
  218. Max pipe packet size 1024
  219. Local memory type Global
  220. Local memory size 32768 (32KiB)
  221. Max constant buffer size 131072 (128KiB)
  222. Max number of constant args 480
  223. Max size of kernel argument 3840 (3.75KiB)
  224. Queue properties (on host)
  225. Out-of-order execution Yes
  226. Profiling Yes
  227. Local thread execution (Intel) Yes
  228. Queue properties (on device)
  229. Out-of-order execution Yes
  230. Profiling Yes
  231. Preferred size 4294967295 (4GiB)
  232. Max size 4294967295 (4GiB)
  233. Max queues on device 4294967295
  234. Max events on device 4294967295
  235. Prefer user sync for interop No
  236. Profiling timer resolution 1ns
  237. Execution capabilities
  238. Run OpenCL kernels Yes
  239. Run native kernels Yes
  240. SPIR versions 1.2
  241. printf() buffer size 1048576 (1024KiB)
  242. Built-in kernels
  243. Device 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_depth_images cl_khr_3d_image_writes cl_intel_exec_by_local_thread cl_khr_spir cl_khr_fp64 cl_khr_image2d_from_buffer
  244. Platform Name Experimental OpenCL 2.1 CPU Only Platform
  245. Number of devices 1
  246. Device Name Intel(R) Core(TM) i7-8550U CPU @1.80GHz
  247. Device Vendor Intel(R) Corporation
  248. Device Vendor ID 0x8086
  249. Device Version OpenCL 2.1 (Build 10)
  250. Driver Version 1.2.0.10
  251. Device OpenCL C Version OpenCL C 2.0
  252. Device Type CPU
  253. Device Available Yes
  254. Device Profile FULL_PROFILE
  255. Max compute units 8
  256. Max clock frequency 3400MHz
  257. Device Partition (core)
  258. Max number of sub-devices 8
  259. Supported partition types by counts, equally, by names (Intel)
  260. Max work item dimensions 3
  261. Max work item sizes 8192x8192x8192
  262. Max work group size 8192
  263. Compiler Available Yes
  264. Linker Available Yes
  265. Preferred work group size multiple 128
  266. Max sub-groups per work group 1
  267. Preferred / native vector sizes
  268. char 1 / 32
  269. short 1 / 16
  270. int 1 / 8
  271. long 1 / 4
  272. half 0 / 0 (n/a)
  273. float 1 / 8
  274. double 1 / 4 (cl_khr_fp64)
  275. Half-precision Floating-point support (n/a)
  276. Single-precision Floating-point support (core)
  277. Denormals Yes
  278. Infinity and NANs Yes
  279. Round to nearest Yes
  280. Round to zero No
  281. Round to infinity No
  282. IEEE754-2008 fused multiply-add No
  283. Support is emulated in software No
  284. Correctly-rounded divide and sqrt operations No
  285. Double-precision Floating-point support (cl_khr_fp64)
  286. Denormals Yes
  287. Infinity and NANs Yes
  288. Round to nearest Yes
  289. Round to zero Yes
  290. Round to infinity Yes
  291. IEEE754-2008 fused multiply-add Yes
  292. Support is emulated in software No
  293. Correctly-rounded divide and sqrt operations No
  294. Address bits 64, Little-Endian
  295. Global memory size 16559001600 (15.42GiB)
  296. Error Correction support No
  297. Max memory allocation 4139750400 (3.855GiB)
  298. Unified memory for Host and Device Yes
  299. Shared Virtual Memory (SVM) capabilities (core)
  300. Coarse-grained buffer sharing Yes
  301. Fine-grained buffer sharing Yes
  302. Fine-grained system sharing Yes
  303. Atomics Yes
  304. Minimum alignment for any data type 128 bytes
  305. Alignment of base address 1024 bits (128 bytes)
  306. Preferred alignment for atomics
  307. SVM 64 bytes
  308. Global 64 bytes
  309. Local 0 bytes
  310. Max size for global variable 65536 (64KiB)
  311. Preferred total size of global vars 65536 (64KiB)
  312. Global Memory cache type Read/Write
  313. Global Memory cache size 262144 (256KiB)
  314. Global Memory cache line 64 bytes
  315. Image support Yes
  316. Max number of samplers per kernel 480
  317. Max size for 1D images from buffer 258734400 pixels
  318. Max 1D or 2D image array size 2048 images
  319. Base address alignment for 2D image buffers 64 bytes
  320. Pitch alignment for 2D image buffers 64 bytes
  321. Max 2D image size 16384x16384 pixels
  322. Max 3D image size 2048x2048x2048 pixels
  323. Max number of read image args 480
  324. Max number of write image args 480
  325. Max number of read/write image args 480
  326. Max number of pipe args 16
  327. Max active pipe reservations 32767
  328. Max pipe packet size 1024
  329. Local memory type Global
  330. Local memory size 32768 (32KiB)
  331. Max constant buffer size 131072 (128KiB)
  332. Max number of constant args 480
  333. Max size of kernel argument 3840 (3.75KiB)
  334. Queue properties (on host)
  335. Out-of-order execution Yes
  336. Profiling Yes
  337. Local thread execution (Intel) Yes
  338. Queue properties (on device)
  339. Out-of-order execution Yes
  340. Profiling Yes
  341. Preferred size 4294967295 (4GiB)
  342. Max size 4294967295 (4GiB)
  343. Max queues on device 4294967295
  344. Max events on device 4294967295
  345. Prefer user sync for interop No
  346. Profiling timer resolution 1ns
  347. Execution capabilities
  348. Run OpenCL kernels Yes
  349. Run native kernels Yes
  350. Sub-group independent forward progress No
  351. IL version SPIR-V_1.0
  352. SPIR versions 1.2
  353. printf() buffer size 1048576 (1024KiB)
  354. Built-in kernels
  355. Device 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_depth_images cl_khr_3d_image_writes cl_intel_exec_by_local_thread cl_khr_spir cl_khr_fp64 cl_khr_image2d_from_buffer
  356. NULL platform behavior
  357. clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...) No platform
  358. clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...) No platform
  359. clCreateContext(NULL, ...) [default] No platform
  360. clCreateContext(NULL, ...) [other] Success [INTEL]
  361. clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU) No platform
  362. clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU) No platform
  363. clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR) No platform
  364. clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM) No platform
  365. clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL) No platform

5. 成功找到  Intel(R) HD Graphics 

              

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/笔触狂放9/article/detail/386654
推荐阅读
相关标签
  

闽ICP备14008679号