Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion python/tvm/script/parser/tir/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,20 @@
# under the License.
"""The tir parser"""

from typing import TYPE_CHECKING

from ...ir_builder.tir import * # pylint: disable=redefined-builtin
from ...ir_builder.tir import ir as _tir
from . import operation as _operation
from . import parser as _parser
from .entry import Buffer, Ptr, prim_func
from .entry import Buffer, Ptr

if TYPE_CHECKING:
# pylint: disable=invalid-name
# Define prim_func and make it type check as static method
# so most tvmscript won't trigger pylint error here.
prim_func = staticmethod
else:
from .entry import prim_func

__all__ = _tir.__all__ + ["Buffer", "Ptr", "prim_func"]