Closed bertmaher closed 5 years ago
Some of this functionality currently lives in ExecutionEngine::compile()
. It might make sense to share the logic both there and in the HostManager.
Isn't this as simple as adding a call to optimizeFunction inside addNetwork?
At least for #2693, checking isOpSupported()
is only done inside ExecutionEngine::compile()
, not optimizeFunction()
. I'm not sure what was going on with #2689, as @bertmaher noted HostManager::addNetwork()
already calls optimizeFunction()
, so not sure what the problem is there.
@jfix71 @bertmaher Can we close this PR?
isOpSupported()
at the end of optimizeFunction()
. Still not sure what the issue was where @bertmaher was seeing unoptimized functions somehow.I still need to check whether this is working properly with the open source repo now. I landed a temporary fix (TM) locally and haven't revisited it in a while.
@arunm-git tested this and we're good without the optimize call in H backend. I love it when bugs are solved automatically :)
In experimenting with the HostManager I found crashes with the Habana backend due to not running the optimizer. I'm not sure what's going on here because
HostManager::addNetwork
does, in fact calloptimizeFunction
.PRs #2689 and #2693 are workarounds for this, but I'd rather not land them since they're duplicating functionality that we should already have in HM.