MCPcopy Create free account
hub / github.com/MegEngine/MegCC / zero

Method zero

compiler/lib/KernelGen/Utils/Utils.cpp:87–97  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

85}
86
87std::string Utils::DtypeHelper::zero() {
88 switch (m_dtype) {
89 case DtypeEnum::float32:
90 return "0.f";
91 case DtypeEnum::int32:
92 return "0";
93 default:
94 CC_ASSERT(0) << "not support dtype " << (int)m_dtype;
95 }
96 return "";
97}
98
99std::string Utils::DtypeHelper::inline_max_func() {
100 switch (m_dtype) {

Callers 1

gen_initFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected