I am trying to offload parts of the work to my custom accelerator. For that purpose, I’ve started using the BYOC UMA framework as it already bundles some of the best practices out there for this kind of stuff. Started from the Vanilla template. Already implemented a PoC plugging in a dummy C implementation for nn.conv2d. When I try to replace the qnn.conv2d op, I get an error though. RuntimeError: qnn.conv2d is currently only supported with Hexagon. Please run QNN Canonicalize pass to decompose this op into supported ops.
It seems this check was introduced in https://github.com/apache/tvm/pull/12398. I can probably get around this, by implementing some @qnn_conv2d_strategy.register-annotated qnn_conv2d_strategy in the same way it was done for Hexagon (or can’t I?). Just wondering if this is the way to go, since it’s probably not in line with the UMA way to go. Shouldn’t I be able to easily match on the qnn.conv2d ops and interject in the code generation in passes.py? Is the Hexagon RuntimeError a bug in the design?