I’m trying to use TVM from D and figured it would be much simpler to start off with porting the C API rather than the C++ API.
I can’t seem to find any examples using the C API, do they exist? Trying to follow the Python API while source diving just got me stuck in the rabbit hole.
TVM C API is quite low level and is not intended for direct use(but serve as an FFI system). You can likely create a wrapper around it. The key is to support a wrapper of PackedFunc, which is described in here: https://docs.tvm.ai/dev/runtime.html, everything is then exposed as PackedFunc directly in the frontend language.