- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
I am currently dealing with optimizing Multikernel opencl app targetted to Altera FPGA. I have two arguments acroos two kernels of type const _constant roughly taking 20 Kbytes each I also have arguments of type const __global. I did refer the documentation regarding this in the form of Optimization guide. Is the constant cache optimization only for __constant type arguments or is it also for const __global type arguments ? With my case should the value specified for the --const-cache-bytes be 40 or should it be more. How should I decide on the value to be specified for ? Is there any limit on it ? ThanksLink Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--const-cache-bytes is only for __constant arguments of a kernel. Since cache misses have a large performance penalty you want to size the constant cache to be at least as large as the data set you want it to hold. In this case I would set it to be 64kB so that it can hold those two 20kB buffers using --const-cache-bytes 65536.
The only limit on the size is hardware resources. Constant caches are built of on-chip RAM inside the FPGA so if you request too large of a cache the hardware will not compile because the FPGA will run out of memory resources. What type of data is this that you want to store in constant memory? There might be better alternatives depending on what you are doing.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page