Skip to content

Commit fa56386

Browse files
committed
Fix tailcall matching
1 parent b95c9cf commit fa56386

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

bench_runner/plot.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,16 @@ def get_comparison_value(ref, r):
437437
cfg["runners"], cfg["names"], cfg["colors"], cfg["styles"], cfg["markers"]
438438
):
439439
runner_results = commits.get(runner, {})
440-
base_results = runner_results.get("", {})
440+
# For tailcall, we want to compare against the default compiler
441+
# which is a different "machine"
442+
if flag == "TAILCALL":
443+
# It's ok if the removesuffix fails -- it's fine to compare with
444+
# the same machine if the "default" equivalent isn't available.
445+
base_results = commits.get(runner.removesuffix("_clang"), {}).get(
446+
"", {}
447+
)
448+
else:
449+
base_results = runner_results.get("", {})
441450

442451
line = []
443452
for cpython_hash, r in runner_results.get(flag, {}).items():

0 commit comments

Comments
 (0)