Michael Lazos 2025-06-10 07:32:23 +00:00 committed by PyTorch MergeBot
parent 8b8684466a
commit 5dfe1787b5
2 changed files with 8 additions and 1 deletions

View File

@ -582,6 +582,9 @@ max_epilogue_benchmarked_choices = 1
# how many nodes to allow into a single fusion
max_fusion_size = 64
# how many nodes to attempt pairwise fusion with in a buffer group
max_fusion_buffer_group_pairwise_attempts = 64
# max number of inputs to generate cat as a pointwise op with masked laods
max_pointwise_cat_inputs = 8

View File

@ -3229,7 +3229,11 @@ class Scheduler:
def check_all_pairs(nodes: list[BaseSchedulerNode]) -> None:
for node1_index, node1 in enumerate(nodes):
for node2 in nodes[node1_index + 1 :]:
for node2 in nodes[
node1_index + 1 : node1_index
+ 1
+ config.max_fusion_buffer_group_pairwise_attempts
]:
key = (node1, node2)
if key in seen:
continue