1 of 1 people found this helpful
HD 4670 is hardly a OpenCL device at any level. Many features are just emulated. It is no longer supported by APP SDK too. I would recommend you to buy a newer GPU if you are seriously into GPGPU.
For learning purpose even CPU is good enough. APP SDK works with any x86 CPU (even intel's )
Now i can not renew my laptop.What are steps or tools which i need to start???
With a 4xxx OpenCL is not a good choice. The OpenCL compiler for 4xxx is in a beta status and its development has been stopped years ago.
To utilize the 0.48 TFlops/s in your card, you have to code in AMD_IL language. (That's also unsupported, but it works)
It's harder, but if you don't want to buy at least an 5xxx then that is the only way (except machine code ).
Here are two examples for the same job, both of them still work on my HD4850 with winXP and Cat11.3.
//Here's small example in OpenCL:
void main(__global int* uav,__constant int* cb)
//And here's how it looks like in AMD_IL (assuming an 1D kernel domain range)
dcl_raw_uav_id(0) //uav translation if id=0 : 5xxx, 6xxx: -> 11, 7xxx -> 10
//dcl_arena_uav_id(8) //This is needed on XP, except on 4xxx
dcl_cb cb0 ; Constant buffer that holds ABI data, must declare on 4xxx
dcl_cb cb1 //cb1.x : uav offset
dcl_cb cb2 //actual cb
//here comes the actual job:
ishl r65.x, vAbsTid.x0, 2
iadd r65.x, cb1.x, r65.x //address calculation: uav[GID]
uav_raw_load_id(0)_cached r0.x, r65.x //load uav[GID]
iadd r66.x,cb2.x,r0.x //add cb
uav_raw_store_id(0) mem.x___, r65.x, r66.x //write uav[GID]
But be warned, in case if you start thinking of amd_il: IMO there's is no point using amd_il instead of OpenCL for the hardware which is supported by OpenCL (5,6,7xxx). I mean that there are no extra things in amd_il that you can't reach from OpenCL.
Thanks for your reply.My first purpose is to learn opencv.Then i will buy a vidock to use a better video card.Can i use opencl to run programs on my cpu??? and if yes do i need intel opencl sdk ???
intel opencl sdk need cpu with sse4 support. you can use amd sdk which need only sse3 cpu.