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

Method check_exec

dnn/src/common/diag.cpp:25–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23}
24
25void Diag::check_exec(
26 const TensorLayout& src, const TensorLayout& dst, size_t workspace_in_bytes) {
27 TensorLayout dst_expected;
28 megdnn_assert_eq_dtype(src, dst);
29 deduce_layout(src, dst_expected);
30 megdnn_assert_eq_layout(dst_expected, dst);
31
32 megdnn_assert_contiguous(dst);
33 auto required_workspace_in_bytes = get_workspace_in_bytes(src, dst);
34 megdnn_assert(workspace_in_bytes >= required_workspace_in_bytes);
35}
36
37} // namespace megdnn
38

Callers

nothing calls this directly

Calls 2

deduce_layoutFunction · 0.85
get_workspace_in_bytesFunction · 0.70

Tested by

no test coverage detected