Alloc device memory
| 102 | |
| 103 | // Alloc device memory |
| 104 | void *alloc(const size_t elements, const af::dtype type) { |
| 105 | void *ptr; |
| 106 | AF_DEPRECATED_WARNINGS_OFF |
| 107 | AF_THROW(af_alloc_device(&ptr, elements * size_of(type))); |
| 108 | AF_DEPRECATED_WARNINGS_ON |
| 109 | // FIXME: Add to map |
| 110 | return ptr; |
| 111 | } |
| 112 | |
| 113 | // Alloc device memory |
| 114 | void *allocV2(const size_t bytes) { |
nothing calls this directly
no test coverage detected