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

HIP #647

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open

HIP #647

wants to merge 18 commits into from

Conversation

neworderofjamie
Copy link
Contributor

@neworderofjamie neworderofjamie commented Jan 6, 2025

So, HIP is a clone of CUDA with all the functions and types prefixed with hip instead of cuda. This means it's much closer to CUDA than e.g. OpenCL so I have added another layer of abstraction between BackendSIMT and the CUDA backend - BackendCUDAHIP - to reflect this. The CUDA and HIP backends are then derived off this and provide virtuals which provide the prefixes for the various libraries and do anything that actually involves interfacing with the device (getting cudaDeviceProp). Other than that heavy-lifting, this PR:

  • Removes OpenCL - it was never supported well enough by anyone to be worthwhile and it hadn't been updated to GeNN 5 anyway
  • Does some fancy pytest stuff to the feature tests so which backends to test is determined automatically

This is the type of change that is going to be absolutely horrible to merge other stuff onto so, while this isn't really ready for anyone to use until I get to test on an actual AMD card, I'd like to get it merged so I can do other things. It definitely doesn't break CUDA and the HIP backend works fine with the NVIDIA backend which basically just renamed everything back.

Copy link

codecov bot commented Jan 6, 2025

Codecov Report

Attention: Patch coverage is 80.01708% with 234 lines in your changes missing coverage. Please review.

Project coverage is 88.45%. Comparing base (ebdeeac) to head (8f749de).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
src/genn/genn/code_generator/backendCUDAHIP.cc 86.18% 117 Missing ⚠️
src/genn/backends/hip/backend.cc 64.37% 88 Missing ⚠️
include/genn/genn/code_generator/backendCUDAHIP.h 54.09% 28 Missing ⚠️
src/genn/backends/hip/optimiser.cc 80.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #647      +/-   ##
==========================================
- Coverage   88.94%   88.45%   -0.50%     
==========================================
  Files         106      111       +5     
  Lines       14786    15062     +276     
==========================================
+ Hits        13152    13323     +171     
- Misses       1634     1739     +105     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Base automatically changed from improved_heterogeneity to master January 6, 2025 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant