Results 1 to 3 of 3

Thread: opencl code concept

  1. #1
    Join Date
    May 2014

    opencl code concept

    hello everyone,I am new to OpenCL.I have a few questions about work items.I am trying to find the sum of an array.I am trying to compute the sum by dividing the array into several parts and each work item will sum up a part of the array.suppose I have 20 elements in the array and I have 4 work items.So I want each work item to get 5 elements each and then they will compute the sum of each part using a loop but all the work items will work simultaneously so that I have the sum of the 4 parts after 4 time units.So I want to know how many work items can work parallely in my computer?Please help.

  2. #2
    Senior Member
    Join Date
    Dec 2011
    It varies, but some devices are capable of running hundreds or thousands of work items in parallel. You should design kernels to be launched over thousands or millions of work items to best utilize the hardware.

  3. #3
    Junior Member
    Join Date
    Aug 2013
    use clGetDeviceInfo to get CL_DEVICE_MAX_WORK_ITEM_SIZES

Posting Permissions

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