MCPcopy Create free account
hub / github.com/Niko1221/Strata / alloc

Method alloc

engine/src/kernels/expdec_bench.cpp:207–212  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

205 std::vector<void*> ptrs;
206 ~DevMem() { for (void* p : ptrs) cudaFree(p); }
207 void* alloc(size_t n) {
208 void* p = nullptr;
209 if (!ck(cudaMalloc(&p, n), "malloc")) return nullptr;
210 ptrs.push_back(p);
211 return p;
212 }
213};
214
215struct StreamEvents {

Callers 1

run_deviceFunction · 0.45

Calls 3

push_backMethod · 0.80
ckFunction · 0.70
cudaMallocFunction · 0.50

Tested by

no test coverage detected