Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7015089
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:36:25+00:00 2026-05-27T22:36:25+00:00

I have an error in an OpenCL kernel, when I try to use the

  • 0

I have an error in an OpenCL kernel, when I try to use the cl_khr_fp64 extension, the kernel compiles and the build log is empty, but when I call clCreateKernel, I have CL_INVALID_KERNEL_NAME error.

The source that fails:

#pragma OPENCL EXTENSION cl_khr_fp64 : enable

__kernel void simple( __global char *x, __global char *y ){
int id = get_global_id(0);
y[id]=2*x[id];
}

This source compiles right:

__kernel void simple( __global char *x, __global char *y ){
int id = get_global_id(0);
y[id]=2*x[id];
}

I’m using OpenCL 1.0 with a Tesla C1060 that have cl_khr_fp64 in CL_DEVICE_EXTENSIONS, driver 280.13 and CL_PLATFORM_VERSION=OpenCL 1.1 CUDA 4.0.1

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T22:36:26+00:00Added an answer on May 27, 2026 at 10:36 pm

    The problem was that before call to clCreateProgramWithSource, we remove the newlines from source. E.g: the source:

    "__kernel void f( __global char *x ){\nint id = get_global_id(0);\nx[id]=2;\n}"
    

    Becomes:

    "__kernel void simple( __global char *x, __global char *y ){"
    "int id = get_global_id(0);"
    "x[id]=2;}"
    

    It causes no problem until we add the preproccessor directive.

    It’s the OpenCL preprocessor which actually wants newlines to be there. So, it should be written as:

    "__kernel void simple( __global char *x, __global char *y ){\n"
    "int id = get_global_id(0);\n"
    "x[id]=2;}\n"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying use double type in openCL, but doesn't work anyway, i want use
I have started working on Opencl for a project. I have wanted to use
I have a problem with Nvidia's OpenCl/Cuda framework, but I think it is a
Have error ValueError: time data '2012-03-15 9:45:00 AM' does not match format '%Y-%m-%d %H:%M:%S'
I have error in line 2 and 13 in PHP 5.2, I have no
Hello i have error when i am forwarding page without parameter. that is happen
I to do connection and have error. from u in db.aspnet_users where u.UserName.Equals(email) select
Is it possible to add an error for input via ModelState.AddModelError(inputId) to have error
I experience strange problem. We have error handling in global.asax that would redirect user
We have an error that we can't seem to find and don't have the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.