Results 1 to 2 of 2

Thread: Constant memory

  1. #1

    Constant memory

    I am having some trouble figuring out how to copy to constant memory space. In CUDA I could use cudamemcpytosymbol() on the host side to copy over to device constant memory. In the SDK examples i've looked at i've only seen constants passed in as kernel arguments. Is there a way to copy to constant memory space directly? Thanks

  2. #2
    Senior Member
    Join Date
    Jul 2009
    Location
    Northern Europe
    Posts
    311

    Re: Constant memory

    You can define data in your kernel to be constant, but you can not, as the name suggests, copy to constant data in your kernel. The data needs to be initialized before the kernel is launched, either via a kernel argument or by values within the constant address space in the kernel source.

Similar Threads

  1. constant memory
    By FredericX in forum OpenCL
    Replies: 2
    Last Post: 12-03-2010, 11:52 AM
  2. Constant Memory latency
    By PaulS in forum OpenCL
    Replies: 3
    Last Post: 10-21-2009, 08:06 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •