Skip to content

Commit b45b2ed

Browse files
committed
[Language] Support loop_break primitive
1 parent c538d8a commit b45b2ed

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tilelang/language/builtin.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -352,6 +352,12 @@ def sync_grid():
352352
return tir.call_intrin("handle", tir.op.Op.get("tl.sync_grid"))
353353

354354

355+
def loop_break():
356+
"""Break out of the innermost loop.
357+
"""
358+
return tir.call_intrin("handle", tir.op.Op.get("tl.loop_break"))
359+
360+
355361
def cp_async_barrier_noinc(barrier_id: Union[int, PrimExpr, tir.Call]):
356362
"""Perform a ptx async copy barrier using cp.async.mbarrier.arrive.noinc.
357363
"""

0 commit comments

Comments
 (0)