MCPcopy Create free account
hub / github.com/apache/tvm-ffi / CallFunction

Function CallFunction

examples/abi_overview/example_code.c:223–232  ·  view source on GitHub ↗

[Function.Call.begin]

Source from the content-addressed store, hash-verified

221
222// [Function.Call.begin]
223int64_t CallFunction(TVMFFIObject* func, int64_t x, int64_t y) {
224 int err_code;
225 TVMFFIAny args[2];
226 TVMFFIAny result = (TVMFFIAny){0};
227 args[0] = Any_AnyView_FromInt(x);
228 args[1] = Any_AnyView_FromInt(y);
229 err_code = TVMFFIFunctionCall(func, args, 2, &result);
230 assert(err_code == 0);
231 return Any_AnyView_GetInt(&result);
232}
233// [Function.Call.end]
234
235// [Function.GetGlobal.begin]

Callers

nothing calls this directly

Calls 3

Any_AnyView_FromIntFunction · 0.85
TVMFFIFunctionCallFunction · 0.85
Any_AnyView_GetIntFunction · 0.85

Tested by

no test coverage detected