From cdaa57468aa57da7c1991ca4522061aab0af53aa Mon Sep 17 00:00:00 2001 From: wrongtest Date: Wed, 9 Aug 2023 06:10:46 +0000 Subject: [PATCH] check empty array of x86 injective's iters --- include/tvm/topi/x86/injective.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/tvm/topi/x86/injective.h b/include/tvm/topi/x86/injective.h index 16eaee659564..cc1f48c86005 100644 --- a/include/tvm/topi/x86/injective.h +++ b/include/tvm/topi/x86/injective.h @@ -51,7 +51,7 @@ inline Schedule schedule_injective_from_existing(Schedule sch, const Tensor& out auto c = axis[1]; auto fused = detail::Fuse(sch[out], {n, c}); // for nhwc layout, fuse n and h sch[out].parallel(fused); - } else { + } else if (!axis.empty()) { sch[out].parallel(axis[0]); } return sch;