This is an automated email from the ASF dual-hosted git repository.
zhaowu pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tvm.git
The following commit(s) were added to refs/heads/main by this push:
new 712b4a5 [Auto Scheduler][fix] Add dense strategy for mali (#7181)
712b4a5 is described below
commit 712b4a553fb417b743407be9194c0c4a545978d9
Author: leowang1225 <[email protected]>
AuthorDate: Wed Dec 30 20:32:43 2020 +0800
[Auto Scheduler][fix] Add dense strategy for mali (#7181)
Signed-off-by: leowang1225 <[email protected]>
---
python/tvm/relay/op/strategy/mali.py | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
diff --git a/python/tvm/relay/op/strategy/mali.py
b/python/tvm/relay/op/strategy/mali.py
index c4cb4a1..fc47bd6 100644
--- a/python/tvm/relay/op/strategy/mali.py
+++ b/python/tvm/relay/op/strategy/mali.py
@@ -171,9 +171,16 @@ def
conv2d_winograd_without_weight_transfrom_strategy_mali(attrs, inputs, out_ty
def dense_strategy_mali(attrs, inputs, out_type, target):
"""dense mali strategy"""
strategy = _op.OpStrategy()
- strategy.add_implementation(
- wrap_compute_dense(topi.mali.dense),
- wrap_topi_schedule(topi.mali.schedule_dense),
- name="dense.mali",
- )
+ if not is_auto_scheduler_enabled():
+ strategy.add_implementation(
+ wrap_compute_dense(topi.mali.dense),
+ wrap_topi_schedule(topi.mali.schedule_dense),
+ name="dense.mali",
+ )
+ else:
+ strategy.add_implementation(
+ wrap_compute_dense(topi.nn.dense, need_auto_scheduler_layout=True),
+ naive_schedule,
+ name="dense.mali",
+ )
return strategy