merrymercy commented on pull request #5898: URL: https://github.com/apache/incubator-tvm/pull/5898#issuecomment-648223645
There are very simple unit tests for `LegalizeInvalidAttach` ```python import tvm from tvm import te A = te.compute((10, 10), lambda i, j: 1.0, name='A') B = te.compute((10, 10), lambda i, j: A[i][j], name='B') # Case 1: Split an axis which is the target of a compute_at s = te.create_schedule([B.op]) s[A].compute_at(s[B], B.op.axis[1]) s[B].split(B.op.axis[1], 2) print(tvm.lower(s, [A, B], simple_mode=True)) # Case 2: Fuse an axis which is the target of a compute_at s = te.create_schedule([B.op]) s[A].compute_at(s[B], B.op.axis[1]) s[B].fuse(B.op.axis[0], B.op.axis[1]) print(tvm.lower(s, [A, B], simple_mode=True)) ``` ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org