MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / HandleImpl

Method HandleImpl

dnn/src/atlas/handle.cpp:11–21  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9namespace atlas {
10
11HandleImpl::HandleImpl(megcoreComputingHandle_t comp_handle)
12 : HandleImplHelper(comp_handle, HandleType::ATLAS) {
13 // Get megcore device handle
14 megcoreDeviceHandle_t dev_handle;
15 megcoreGetDeviceHandle(comp_handle, &dev_handle);
16
17 int dev_id;
18 megcoreGetDeviceID(dev_handle, &dev_id);
19 m_device_id = dev_id;
20 megcore::getAtlasContext(comp_handle, &m_megcore_context);
21}
22
23HandleImpl::~HandleImpl() noexcept = default;
24

Callers

nothing calls this directly

Calls 2

megcoreGetDeviceHandleFunction · 0.85
megcoreGetDeviceIDFunction · 0.85

Tested by

no test coverage detected