hi, i am trying to include a custom codegen in tvm , and have followed below steps to do it:
- create a codegen inside src/relay/backend/contrib/custom_codegen.cc . and regsitered the codegen using
TVM_REGISTER_GLOBAL("relay.ext.CUSTOM").set_body_typed(CustomCompiler);
api - Added rules for annotating the operations for the custom compiler in python/tvm/relay/op/contrib/custom.py
- Created a cmake file to include the codegen files in cmake/modules/contrib/CUSTOM.cmake.
- Added the fag in config.cmake file to use the custom compiler as
set(USE_CUSTOM ON)
but while building the tvm from scratch , i dont see any compilation of my codegen , whereas if i build it for DNNL codegen , i can see the compiler codegen files.
Also while calling relay.build() , passing a relay module partitionted for custom compiler , its throwing below error:
Check failed: (pf) is false: Failed to find the external codegen tool for relay.ext.CUSTOM
which makes me wonder what other steps i have to perform for tvm to recognise my codegen and start compiling it.
Any help would be largely appreciated. thanks