
OpenCL
文章平均质量分 81
范泽德
这个作者很懒,什么都没留下…
展开
-
OpenCL例程2-数组相加
cpp文件// OpenCl-1.cpp : Defines the entry point for the console application.//#include "stdafx.h"#include #include #include using namespace std;#define ARRAY_SIZE 128cl_int Conve原创 2014-03-31 11:06:01 · 1968 阅读 · 0 评论 -
OpenCL例程1-HelloWorld
步骤如下:1. 获得并选择可用平台2. 查询GPU设备,并选择可用设备3. 创建设备环境4. 创建命令队列5. 创建程序对象6. 编译程序7. 并创建输入输出内核内存对象8. 创建内核对象9. 设置内核参数10. 运行内核11. 将输出读取到主机内存12. 输出计算结果13. 释放资源// OpenCl-1.cpp : Defines原创 2014-03-25 21:25:52 · 3266 阅读 · 2 评论 -
OpenCL例程3-矩阵相乘
cpp文件代码// OpenCl-3.cpp : Defines the entry point for the console application.//#include "stdafx.h"#include #include #include using namespace std;#define MATRIX_A_ROW 8 // 矩阵A行数#defin原创 2014-03-31 14:32:50 · 2111 阅读 · 0 评论