junrushao1994 commented on a change in pull request #8767:
URL: https://github.com/apache/tvm/pull/8767#discussion_r691549866



##########
File path: python/tvm/tir/schedule/schedule.py
##########
@@ -442,6 +442,64 @@ def after_split(a: ty.handle, b: ty.handle) -> None:
         # that there is at most one None in `factors`
         return _ffi_api.ScheduleSplit(self, loop, factors)  # type: ignore # 
pylint: disable=no-member
 
+    def reorder(self, *loops: List[LoopRV]) -> None:
+        """
+        Reorder a list of loops. It doesn't require the loops to be 
consecutive.
+        It requires:
+        1) The loops are in the same line. That means: the loops can be 
ordered to [l_1, l_2, ... ,
+            l_n] where l_i is an ancestor of l_{i+1} and there are only 
single-branch loops between
+            l_1 and l_n (which also indicates they are under the same scope).
+        2) In the new order, an outer loop cannot depend on inner loops.
+        3) The block below the loops have affine bindings and only have 
data-parallel or reduction
+            block iters
+        4) A loop cannot appear multiple times in the input array.

Review comment:
       Update the docs




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@tvm.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to