Skip to content

Commit 7850a9c

Browse files
committed
Align TRITON_MAX_BLOCK code with upstream.
1 parent 451c2b4 commit 7850a9c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

torch/_inductor/runtime/hints.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@
77
from enum import auto, Enum
88
from typing import Optional, Union
99

10+
import torch
1011
from torch.utils._triton import has_triton_package
1112

1213

1314
# The following maximums only apply to runtime autotuning, when using FixedTritonConfig one may see larger values
1415
# NOTE: if these fail asserts submit a PR to increase them
1516
TRITON_MAX_BLOCK = {
16-
"X": 8192,
17+
"X": 8192 if torch.version.hip else 4096,
1718
"Y": 1024,
1819
"Z": 1024,
1920
"R0_": 4096 * 16, # * 16 is multi-kernel only

0 commit comments

Comments
 (0)