2 Replies Latest reply on Mar 14, 2017 1:14 AM by meriken

    Using LLVM to make a Polaris (Ellesmere) binary loadable by the OpenCL API

    wolf0

      I've been using CLRadeonExtender, which doesn't support Polaris 10. I'd LOVE to use LLVM, but it seems that it's near impossible to figure out what to pass to it to get it to compile an OpenCL program and output an AMD binary for the target loadable by the OpenCL driver.

        • Re: Using LLVM to make a Polaris (Ellesmere) binary loadable by the OpenCL API
          wolf0

          Turns out, there seem to be options that MAY produce such a binary... but clang-4.0 (from svn) crashes on linking:

           

          1.    <eof> parser at end of file

          2.    Code generation

          3.    Running pass 'Function Pass Manager' on module '/mnt/3tb-secure/tmp/Ethereum/ethash-gcn/wolf-cn-clang.cl'.

          4.    Running pass 'SI Fix SGPR copies' on function '@cn0'

          clang-4.0: error: unable to execute command: Segmentation fault (core dumped)

          clang-4.0: error: clang frontend command failed due to signal (use -v to see invocation)

          clang version 4.0.0 (trunk 281716)

          Target: amdgcn-fiji--

          Thread model: posix

          InstalledDir: /usr/bin

          clang-4.0: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script.

          clang-4.0: note: diagnostic msg:

          ********************

           

          PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:

          Preprocessed source(s) and associated run script(s) are located at:

          clang-4.0: note: diagnostic msg: /tmp/wolf-cn-clang-026d14.cl

          clang-4.0: note: diagnostic msg: /tmp/wolf-cn-clang-026d14.sh

          clang-4.0: note: diagnostic msg:

           

          ********************