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

Function packA_group_size

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

Source from the content-addressed store, hash-verified

102}
103
104static size_t packA_group_size(
105 const MatrixMulImpl::AlgoBase* matmul_algo,
106 const fallback::MatrixMulImpl::KernSizeParam& matmul_param,
107 const fallback::MatrixMulImpl::AlgoBase::MatmulDescription& matmul_desc,
108 size_t packa_parallel_times) {
109 if (matmul_desc.packmode == fallback::MatrixMulImpl::AlgoBase::PackMode::DEFAULT) {
110 return matmul_algo->get_bundle(matmul_param).get_size(0);
111 } else if (
112 matmul_desc.packmode ==
113 fallback::MatrixMulImpl::AlgoBase::PackMode::ONLY_PACKA) {
114 return packa_parallel_times * matmul_algo->get_bundle(matmul_param).get_size(0);
115 }
116 megdnn_assert(
117 matmul_desc.packmode ==
118 fallback::MatrixMulImpl::AlgoBase::PackMode::NO_PACK);
119 //! nopack mode return 0;
120 return 0;
121}
122
123static WorkspaceBundle get_thread_bundle(
124 const fallback::ConvBiasImpl::NCBKernSizeParam& param,

Callers 4

get_bundleFunction · 0.85
dispatch_kernsMethod · 0.85

Calls 2

get_sizeMethod · 0.45
get_bundleMethod · 0.45

Tested by

no test coverage detected