Closed telegraphic closed 2 years ago
This is sorta kinda tangentially related but I get various warnings related to managed memory when I compile under CUDA 10.1:
memory.cpp: In function ‘BFstatus bfGetSpace(const void*, BFspace*)’:
memory.cpp:62:23: warning: ‘cudaPointerAttributes::isManaged’ is deprecated
(declared at /usr/local/cuda/include/driver_types.h:1341)
[-Wdeprecated-declarations]
} else if( ptr_attrs.isManaged ) {
^
memory.cpp:62:23: warning: ‘cudaPointerAttributes::isManaged’ is deprecated
(declared at /usr/local/cuda/include/driver_types.h:1341)
[-Wdeprecated-declarations]
memory.cpp:65:21: warning: ‘cudaPointerAttributes::memoryType’ is
deprecated (declared at /usr/local/cuda/include/driver_types.h:1302)
[-Wdeprecated-declarations]
switch( ptr_attrs.memoryType ) {
^
memory.cpp:65:21: warning: ‘cudaPointerAttributes::memoryType’ is
deprecated (declared at /usr/local/cuda/include/driver_types.h:1302)
[-Wdeprecated-declarations]
This may become an issue in future CUDA releases.
Just change it to switch(ptr_attrs.type)
and (ptr_attrs.type == cudaMemoryTypeManaged)
I started thinking about this again and my currently thinking is that it would be easy to support cuda_managed for Pascal and later. From what I can tell this should work seamlessly on those generations of GPUs and doesn't require the the explicit stream synchronization call of earlier generations.
https://github.com/ledatelescope/bifrost/commit/90dfc3d32948d1c6628d58f70c2375d8578d2ee5 starts work on cuda_managed support for Pascal and later GPUs. I also added a test suite in https://github.com/ledatelescope/bifrost/commit/d0552ee589a81d06bc22f0de4d45b8761e0fe0ba but I have an intermittent failures on the "reduce" tests.
Closing with the release of v0.10.0.
On the wishlist: ability to use
space='cuda_managed'
in blocks. Currently it'll fail like this: