gtensor icon indicating copy to clipboard operation
gtensor copied to clipboard

clib namespace is confusing

Open bd4 opened this issue 2 years ago • 1 comments

Why is is_device_accessible for example in gt::backend::clib, rather than just gt::backend?

bd4 avatar Nov 14 '22 14:11 bd4

I think the reason is that clib provides functionality for one particular backend, the one that is generally used to generate the clib functionality, as that can not be templated by space. I'm not sure there's a good C++ interface to the same functionality at this point, there is backend_ops<space::cuda/whatever>::is_device_accessible where the actual implementation lives.

There should probably by something like gt::is_device_accessible<SPACE>(ptr).

germasch avatar Nov 14 '22 16:11 germasch