Skip to content

Commit 0bdb796

Browse files
naromero77amdpytorchmergebot
authored andcommitted
[ROCm][inductor] Additional pointwise tunings (#2642)
This config improves the performance of a 1D pointwise kernel by 20% as measured on MI350. (cherry picked from commit a7bac0a)
1 parent 2e79001 commit 0bdb796

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

torch/_inductor/runtime/triton_heuristics.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2529,6 +2529,15 @@ def pointwise(
25292529
),
25302530
*hinted_configs,
25312531
]
2532+
# Additional reduction configs appended for ROCm builds
2533+
if torch.version.hip:
2534+
configs.append(triton_config_with_settings(
2535+
size_hints,
2536+
2048,
2537+
num_warps=8,
2538+
num_stages=2,
2539+
waves_per_eu=1
2540+
)) # 20% improvement
25322541
if len(size_hints) == 2:
25332542
if (
25342543
disable_pointwise_autotuning(inductor_meta) # or tile_hint == TileHint.SQUARE

0 commit comments

Comments
 (0)