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

Method get_workspace

dnn/src/fallback/conv_bias/im2col/algos.cpp:215–228  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

213} // namespace
214
215size_t ConvBiasImpl::AlgoIm2col::get_workspace(const NCBKernSizeParam& p) const {
216 MIDOUT_BEGIN(megdnn_fallback_im2col, 0, 0) {
217 fallback::MatrixMulImpl::AlgoBase::MatmulDescription matmul_desc =
218 m_matmul_algo->matmul_description();
219 size_t oc_tile_size = 0, ohw_tile_size = 0;
220 choice_ohw_oc_block(
221 p, oc_tile_size, ohw_tile_size, matmul_desc.innerblocksize.m,
222 matmul_desc.innerblocksize.n, m_ohw_tile_size, matmul_desc.packmode);
223 return get_bundle(p, m_matmul_algo, oc_tile_size, ohw_tile_size)
224 .total_size_in_bytes();
225 }
226 MIDOUT_END();
227 return 0;
228}
229
230SmallVector<ConvBiasImpl::NCBKern> ConvBiasImpl::AlgoIm2col::dispatch_kerns(
231 const NCBKernSizeParam& param) const {

Callers 2

get_thread_bundleMethod · 0.45
get_wbundle_computeMethod · 0.45

Calls 4

choice_ohw_oc_blockFunction · 0.85
total_size_in_bytesMethod · 0.80
get_bundleFunction · 0.70
MIDOUT_BEGINFunction · 0.50

Tested by

no test coverage detected