Build failure on amd platform

Help
mux85
2010-04-12
2012-12-21
  • mux85
    mux85
    2010-04-12

    I installed stream sdk to try the cpu implementation. The ati stream platform and the cpu device are found correctly but when the program is built i get the build failure exception. i have tried to use stream kernel analyzer but i always get this message "Unknown error compiling Brook kernel". have you ever tried the amd cpu implementation? can you make it work? are you able to use stream kernel analyzer?
    thanks

     
  • nythrix
    nythrix
    2010-04-12

    have you ever tried the amd cpu implementation? can you make it work?
    Yes. The examples that come with Clootils should work with ATI as well. Have you tried running them? You can select the platform under Build/Configuration. Note that this will not work with versions older than 0.7.1. You were able to change platforms but not for the examples. They used to pick the first available.
    If you have a large kernel that's working on CUDA but failing on Stream that's a different (and much more difficult) problem. Usually it is 95% drivers related…

    are you able to use stream kernel analyzer?
    No. Well, I mean I don't know. Never used it. But I have tried to use their OpenCL Profiler without success. All it gave me was a file-choosing dialog and an exception. But maybe things are better now.
    Is this kernel analyzer bundled into Stream?

     
  • mux85
    mux85
    2010-04-13

    Actually Clootils works well.
    The kernel is not so large and i don't think it uses anything particular (like images).
    Stream kernel analyzer needs to be download independently.

     
  • mux85
    mux85
    2010-04-13

    i get the exception even with an empty kernel. another odd  thing is that when the exception is raised a command prompt window pops up and then disappear. this happens only when using amd platform and it happens too fast to read something

     
  • mux85
    mux85
    2010-04-13

    ok with this workaround it works. i hope this is a only temporary problem. is this the cause of the useless console windows that opens with clootils? now i get one also with my application and i hate it so much.
    i had to add "#pragma OPENCL EXTENSION cl_khr_byte_addressable_store : enable" to make my kernel work.
    i also noticed that clootils as some problem with this kind of directives: some times it comes up with an error when it's all right, other times i get a build success even with intentional errors like "enableqwerty" instead of "enable".
    talking about performance i get longer execution times using opencl on cpu (which should use both of my processor cores) then with normal cpu code which uses only one core. why would that be?

     
  • nythrix
    nythrix
    2010-04-13

    Yes. ATI Stream OpenCL REQUIRES some sort of console. Most annoying thing ever.

    Yeah I've noticed that too. But Clootils don't test the OpenCL program. It just passes the code to the driver and retrieves the log. Any problems are directly related to the underlying compiler, which can also happily crash if you're lucky enough. There's nothing special I can do about that.
    That said, Clootils has a somewhat lower priority than Cloo so it's a very far cry from what it could be ;)

    Maybe a dual core isn't fast enough to make up for the data transfers between memories? In some cases OpenCL is actually slower, depending on what you're solving.

     
  • mux85
    mux85
    2010-04-14

    yes maybe that what i am doing is not taking enough advantage from being executed on 2 cores considering the overhead of all the initializations that opencl requires.

    "Clootils has a somewhat lower priority than Cloo so it's a very far cry from what it could be ;)"

    I noticed ;) that's why i was trying the stream kernel analyzer. can you try it and tell me if you can make it work?
    thanks

     
  • nythrix
    nythrix
    2010-04-15

    I can't compile anything with the analyzer. Is it supposed to work without an ATI card?

     
  • mux85
    mux85
    2010-04-15

    well i supposed it should work on opencl amd plaform, so even on a cpu. maybe i am wrong