MCPcopy Create free account
hub / github.com/ashvardanian/less_slow.cpp / unified_array

Method unified_array

less_slow.cpp:3305–3307  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3303
3304 public:
3305 unified_array(std::size_t size) : size_(size) {
3306 if (cudaMallocManaged(&data_, sizeof(type_) * size_) != cudaSuccess) throw std::bad_alloc();
3307 }
3308
3309 ~unified_array() noexcept { cudaFree(data_); }
3310

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected