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

Method BindCustomKernel

driver/cpu/cpu_runner.cpp:982–995  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

980}
981
982NodeOps* CPURunner::BindCustomKernel(Node* node)
983{
984 /* set errno first */
985 set_tengine_errno(EINVAL);
986
987 if(!node->ExistAttr(ATTR_CUSTOM_KERNEL) || !node->ExistAttr(DEV_PROPOSAL_ATTR))
988 return nullptr;
989
990 const DevProposal* prop = any_cast<DevProposal>(&node->GetAttr(DEV_PROPOSAL_ATTR));
991
992 NodeOps* node_ops = CustomKernelManager::BindOps(node, prop->dev_id);
993
994 return node_ops;
995}
996
997bool CPURunner::BindNodeOps(Subgraph* sub_graph)
998{

Callers

nothing calls this directly

Calls 4

set_tengine_errnoFunction · 0.85
BindOpsFunction · 0.85
ExistAttrMethod · 0.45
GetAttrMethod · 0.45

Tested by

no test coverage detected