Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

trying cuda on clang and HIPing shoc #48

Open
psteinb opened this issue Mar 22, 2016 · 5 comments
Open

trying cuda on clang and HIPing shoc #48

psteinb opened this issue Mar 22, 2016 · 5 comments

Comments

@psteinb
Copy link

psteinb commented Mar 22, 2016

dear SHOCers,

I am contemplating to modify shoc to use the clang compiler that has recently adopted mainline support for CUDA.
http://llvm.org/releases/3.8.0/tools/clang/docs/ReleaseNotes.html#cuda-support-in-clang
I'd like to know if you would be interest in PRs that enable SHOC to use this compiler toolchain?

On a related note, it would be interesting to compare native OpenCL SHOC results to HIPified CUDA benchmarks:
http://gpuopen.com/hip-release-0-82/
As I have no feeling how mature a 0.82 release would be, this more an experiment. But still, I'd like to know if the SHOC community would be interested.

@jyoung3131
Copy link
Contributor

Peter, I probably can't speak for the main SHOC team, but I think that a PR that enables clang compilation would be a very useful and interesting addition to the SHOC suite.

HIP does look pretty neat and would be a good test case for comparing CUDA->HIP with OpenCL. I personally would be interested to know the results for some of the Level 1 benchmarks, especially ones that pull in cuBLAS or other CUDA-specific math libraries.

@psteinb
Copy link
Author

psteinb commented Mar 29, 2016

Hi jyoung3131, I'll see to it and will send a PR ... once I get my head around autoconf and friends. I know that others are already looking into HIPifying SHOC as well, so it's good to see that the community would be interested.

@bensander
Copy link

Hi Folks - I think this is a great idea. We have done some internal work with hipifying SHOC and have Level0 and Level2 tests running. I want to clean up the tool support (HCC and HIP) for handling C++ structures across G++ and HCC (rather than hacking the shoc/src/common files or converting the entire project to compile HCC). This "cross-compile" support will be useful for other projects that want to use both G++ for host code and HCC for accelerator code.

In the meantime we did share a hipified version the Level0 BusBandwidth here:
https://github.com/GPUOpen-ProfessionalCompute-Tools/HIP/tree/master/samples/1_Utils/hipBusBandwidth

@wujingyue
Copy link

I tried compiling SHOC with the upstream Clang and managed to build at least ten benchmarks. Others use texture APIs which the upstream Clang doesn't support yet.

FYI, the hack I did to compile SHOC with Clang was

Replace "set dummy nvcc" with "set dummy clang++" in ./configure
./configure CPPFLAGS="-I/usr/local/cuda/include -L/usr/local/cuda/lib64" CUDA_CPPFLAGS="--cuda-gpu-arch=sm_35" LDFLAGS="-L/usr/local/cuda/lib64" LIBS="-lcudart_static -lpthread -ldl" --without-mpi
make -j32 -k

@aditya4d
Copy link

aditya4d commented Jun 7, 2016

Hi,
I have created a pull request #50. Any comments is appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants