wdmapp / gtensor

GTensor is a multi-dimensional array C++14 header-only library for hybrid GPU development.
BSD 3-Clause "New" or "Revised" License
34 stars 9 forks source link

clib namespace is confusing #224

Open bd4 opened 1 year ago

bd4 commented 1 year ago

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

germasch commented 1 year ago

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).