Code quality: More MSVC warning fixing
This commit is contained in:
@@ -176,7 +176,7 @@ bool Device::fp64_support() const
|
||||
switch(backend_)
|
||||
{
|
||||
case OPENCL:
|
||||
return ocl::info<CL_DEVICE_DOUBLE_FP_CONFIG>(h_.cl());
|
||||
return extensions().find("cl_khr_fp64")!=std::string::npos;
|
||||
|
||||
#ifdef ISAAC_WITH_CUDA
|
||||
case CUDA:
|
||||
@@ -201,7 +201,7 @@ bool Device::fp64_support() const
|
||||
switch(backend_)\
|
||||
{\
|
||||
CUDACASE(CUNAME)\
|
||||
case OPENCL: return ocl::info<CLNAME>(h_.cl());\
|
||||
case OPENCL: return static_cast<ret>(ocl::info<CLNAME>(h_.cl()));\
|
||||
default: throw;\
|
||||
}\
|
||||
}\
|
||||
|
@@ -38,7 +38,7 @@ long Event::elapsed_time() const
|
||||
return 1e6*time;
|
||||
#endif
|
||||
case OPENCL:
|
||||
return ocl::info<CL_PROFILING_COMMAND_END>(h_.cl()) - ocl::info<CL_PROFILING_COMMAND_START>(h_.cl());
|
||||
return static_cast<long>(ocl::info<CL_PROFILING_COMMAND_END>(h_.cl()) - ocl::info<CL_PROFILING_COMMAND_START>(h_.cl()));
|
||||
default:
|
||||
throw;
|
||||
}
|
||||
|
@@ -129,7 +129,7 @@ Program::Program(Context const & context, std::string const & source) : backend_
|
||||
h_.cl() = clCreateProgramWithSource(context_.h_.cl(), 1, &csrc, &srclen, &err);
|
||||
try{
|
||||
ocl::check(clBuildProgram(h_.cl(), devices.size(), devices.data(), build_opt.c_str(), NULL, NULL));
|
||||
}catch(ocl::exception::build_program_failure const & e){
|
||||
}catch(ocl::exception::build_program_failure const &){
|
||||
for(std::vector<cl_device_id>::const_iterator it = devices.begin(); it != devices.end(); ++it)
|
||||
{
|
||||
std::cout << "Device : " << ocl::info<CL_DEVICE_NAME>(*it)
|
||||
|
Reference in New Issue
Block a user