I am very new to OpenCl. I need to write a packet processing program in OpenCl using GPU. Program is supposed to get some packets from sockets, checks their headers, does the match/action and outputs them on the correct outgoing socket. I have no idea how to do it. Could you please give me a hint on how I can implement such a program in OpenCl?
Thank you so much in advance,
As a first step, I would implement the code in C on the CPU. Once you are sure of its functional correctness and have a number of tests to prove it, I would start learning the OpenCL and moving it to the GPU.
For that, you can start with online tutorials and samples (we have some Tutorials https://software.intel.com/en-us/articles/opencl-tutorials and samples https://software.intel.com/en-us/intel-opencl-support/code-samples and here https://software.intel.com/en-us/intel-opencl-support/training , but you could find more online) , or purchase a good OpenCL book, e.g. Heterogeneous Computing with OpenCL 2.0 http://www.amazon.com/Heterogeneous-Computing-OpenCL-David-Kaeli/dp/0128014148/ref=sr_1_1?ie=UTF8&qi... .
Once you have a functionally correct OpenCL implementation, you might want to read our optimization guide: https://software.intel.com/en-us/iocl_opg and download our tools Intel SDK for OpenCL Applications https://software.intel.com/en-us/intel-opencl and Intel Vtune Amplifier https://software.intel.com/en-us/intel-vtune-amplifier-xe/ .
Hope this helps!