Skip to content

Commit 987f6b5

Browse files
authored
SPMI: Sort summary by collection name (#109370)
These are already sorted by work item order, which themselves are sorted by collection name, but the work items end up sorted as "0 1 10 2 3", which breaks the ordering. Just sort them again when summarizing.
1 parent a3b617e commit 987f6b5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/coreclr/scripts/superpmi.py

+6
Original file line numberDiff line numberDiff line change
@@ -4163,6 +4163,9 @@ def summarize_json_summaries(coreclr_args):
41634163
(base_jit_options, diff_jit_options, asm_diffs) = json.load(fh)
41644164
summarizable_asm_diffs.extend(asm_diffs)
41654165

4166+
# Sort by collection name
4167+
summarizable_asm_diffs.sort(key=lambda t: t[0])
4168+
41664169
with open(overall_md_summary_file, "w") as write_fh:
41674170
write_asmdiffs_markdown_summary(write_fh, base_jit_options, diff_jit_options, summarizable_asm_diffs, True)
41684171
logging.info(" Summary Markdown file: %s", overall_md_summary_file)
@@ -4182,6 +4185,9 @@ def summarize_json_summaries(coreclr_args):
41824185
(base_jit_build_string_decoded, diff_jit_build_string_decoded, base_jit_options, diff_jit_options, tp_diffs) = json.load(fh)
41834186
summarizable_tp_diffs.extend(tp_diffs)
41844187

4188+
# Sort by collection name
4189+
summarizable_tp_diffs.sort(key=lambda t: t[0])
4190+
41854191
with open(overall_md_summary_file, "w") as write_fh:
41864192
write_tpdiff_markdown_summary(write_fh, base_jit_build_string_decoded, diff_jit_build_string_decoded, base_jit_options, diff_jit_options, summarizable_tp_diffs, True)
41874193
logging.info(" Summary Markdown file: %s", overall_md_summary_file)

0 commit comments

Comments
 (0)