MCPcopy Create free account
hub / github.com/OAID/Tengine / SelectFunc

Function SelectFunc

executor/operator/arm64/fc/fully_connected_fast.cpp:336–354  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

334};
335
336NodeOps* SelectFunc(const CPUInfo* cpu_info, Node* node)
337{
338 Tensor* input = node->GetInputTensor(0);
339 const int data_type = input->GetDataType();
340 const ExecAttr* exec_attr = any_cast<const ExecAttr*>(node->GetAttr(ATTR_EXEC_ATTR));
341 if(data_type != TENGINE_DT_FP32 || exec_attr->graph_layout != TENGINE_LAYOUT_NCHW)
342 return nullptr;
343
344 FCOps* ops = new FCOps();
345
346 int master_cpu = cpu_info->GetMasterCPU();
347
348 if(cpu_info->GetCPUModelString(master_cpu) == std::string("A72"))
349 ops->cpu_type = TYPE_A72;
350 else
351 ops->cpu_type = TYPE_A53;
352
353 return ops;
354}
355
356} // namespace FC_fast
357

Callers

nothing calls this directly

Calls 5

GetDataTypeMethod · 0.80
GetMasterCPUMethod · 0.80
GetCPUModelStringMethod · 0.80
GetInputTensorMethod · 0.45
GetAttrMethod · 0.45

Tested by

no test coverage detected