摘要:
在CUDA中统计运算时间,大致有三种方法:<1>使用cutil.h中的函数unsigned int timer=0; //创建计时器cutCreateTimer(&timer); //开始计时cutStartTimer(timer);{ //统计的代码段 …………}//停止计时cutStopTimer(timer);//获得从开始计时到停止之间的时间cutGetTimerValue( timer);//删除timer值cutDeleteTimer( timer);<2>time.h中的clock函数clock_t start, finish;float cost 阅读全文
posted @ 2012-08-17 14:44
喜欢阿亮的小水
阅读(931)
评论(0)
推荐(0)

浙公网安备 33010602011771号