Search:

Type: Posts; User: qwer

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. Replies
    1
    Views
    986

    Private variables compiler optimization?

    Does OpenCL compiler attempts to conduct private variables optimization?

    Lets say there are two private variables A and B. A is used only in lines 3-9 and B only in lines 10-23, so there is no...
  2. Replies
    0
    Views
    1,094

    double with select() function doesn't compile

    Hi, I have following code:
    float a,b,c; select(a,b,c>0.1); that works fine on Tesla C1060 with float and float4 but with double and double4 it gives this error: call to 'select' is ambiguous ......
  3. Re: CL_INVALID_BINARY (-42) while trying to use double on Te

    Solution: I had 2 cards and only one of them had double-precision support, so while creating context one needs only to mention one:

    devices.push_back(context.getInfo<CL_CONTEXT_DEVICES>()[0]);
  4. CL_INVALID_BINARY (-42) while trying to use double on Tesla

    I get CL_INVALID_BINARY (-42) in Program::build() while trying to use double on Tesla C1060, here is the code:

    #pragma OPENCL EXTENSION cl_khr_fp64 : enable

    __kernel void compute(__global...
  5. Thread: MPI like support

    by qwer
    Replies
    1
    Views
    1,966

    MPI like support

    It would be nice to be able to use devices not only locally but also from a remote computer. This way it would be easy to use OpenCL on a cluster (like MPI). Is this feature being discussed by...
  6. Replies
    1
    Views
    1,379

    accessing elements of cl::Buffer?

    Hi,
    is it possible somehow to access elements of cl::Buffer, like

    cl::Buffer buf;

    ...

    cout << buf[4];

    operator[] is not defined for cl::Buffer - but is there any other way?
  7. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    Here is the solution:


    // allocate value in GPU memory
    value = cl::Buffer(context,
    CL_MEM_READ_WRITE,
    sizeof(T) * size,
    ...
  8. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    it doesn't compile, since object_ is protected...



    1) why is it not initialized?! it passed:


    if(status != CL_SUCCESS)
    {
    cerr << "Error: cl::Buffer failed. (" << status...
  9. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    How should I check it? I tried to "cout <<" it, but it refused...

    then I tried to put:


    template <typename T> Vector<T>::Vector(unsigned int size_):
    size(size_),
    {
    cl_int status = 0;
  10. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    yes, its on the same place - in write function...
  11. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    david.garcia - you are correct (as always :) )

    1) I changed those lines to:



    context = cl::Context(CL_DEVICE_TYPE_CPU, cps, NULL, NULL, &status);
    devices =...
  12. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    Is there a way to get more details on the error?
    export CL_LOG_ERRORS=stdout - didn't provide any information in console...
  13. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    I rewrote the Vector::write() and it didn't help :( ... also placing &source[0] instead of dstArray didn't work... Yes, I run initializeCL(); successfully before vec1.write()...


    template...
  14. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    pps: queue initialization seems to pass without error messages, what causes problem is this:


    vec1.write(input);
  15. Replies
    16
    Views
    5,620

    Re: CL_INVALID_COMMAND_QUEUE error

    ps: I forgot to mention that I have initialization routine in main():


    int main()
    {
    if(initializeCL() == 1)
    exit(1);

    ...
    Vector<cl_int> vec1(10);
  16. Replies
    16
    Views
    5,620

    CL_INVALID_COMMAND_QUEUE error

    I get CL_INVALID_COMMAND_QUEUE ( -36 ) while trying to write to buffer. I have no clue why and how to debug this issue. Any ideas? I tried to export CL_LOG_ERRORS=stdout in order to see a more...
  17. Replies
    5
    Views
    1,787

    Re: Problems with linking in Linux

    the problem was that I did export LD_LIBRARY_PATH=$ATISTREAMSDKROOT/lib/x86_64 in one terminal and launched the program in another terminal. Doing both things in the same terminal solved the issue....
  18. Replies
    5
    Views
    1,787

    Re: Problems with linking in Linux

    the problem was that I have declared global varibles in a .h file and included it later several times... using "extern" solved this issue. The program compiles and links, however I now have problem...
  19. Replies
    5
    Views
    1,787

    Problems with linking in Linux

    Hi,

    I tried to add OpenCL to my program, so all I did for the beginning is defining a global variable:


    // GLOBALS

    cl_context context;

    (I use ATI SDK with CPU only)
  20. Replies
    4
    Views
    1,666

    Re: unique kernel names?

    thank you very much for the help!
  21. Replies
    4
    Views
    1,666

    Re: unique kernel names?

    thank you!

    what are pro's and con's of both approaches?
    what was the idea to divide everything into programs?
    how will putting one kernel per program impact 1) performance 2) use of resources 3)...
  22. Replies
    4
    Views
    1,666

    unique kernel names?

    Do the kernel function names have to be unique? Is it ok, if I pass different source code strings to clCreateProgramWithSource but all with the same kernel name? Looks like I will be able to get...
  23. Re: Globally visible buffers or direct memory access?

    should I request global kernel variables as a new feature or was it already discussed somewhere and rejected?
  24. Re: Globally visible buffers or direct memory access?

    thank you very much! you saved me a lot of time and nerves.
  25. Re: Globally visible buffers or direct memory access?

    No, but that has not stopped people from trying to come up with clever workarounds. Be warned: the only method that will work in all implementations and is guaranteed to produce correct results is...
Results 1 to 25 of 27
Page 1 of 2 1 2