Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add benchmark test for render_recipe #5490

Merged
merged 1 commit into from
Sep 18, 2024

Conversation

kenodegard
Copy link
Contributor

Description

Adds render_recipe test for #5392. This is added separately so we can see the benchmark speedups in the other PR via CodSpeed.

Checklist - did you ...

  • Add a file to the news directory (using the template) for the next release's release notes?
  • Add / update necessary tests?
  • Add / update outdated documentation?

@conda-bot conda-bot added the cla-signed [bot] added once the contributor has signed the CLA label Sep 17, 2024
Copy link

codspeed-hq bot commented Sep 17, 2024

CodSpeed Performance Report

Merging #5490 will not alter performance

Comparing kenodegard:render_recipe_test (3194fbc) with main (2ecadb9)

Summary

✅ 3 untouched benchmarks

🆕 1 new benchmarks

Benchmarks breakdown

Benchmark main kenodegard:render_recipe_test Change
🆕 test_render_recipe N/A 64.7 s N/A

@kenodegard kenodegard changed the base branch from 24.9.x to main September 17, 2024 23:10
@kenodegard kenodegard marked this pull request as ready for review September 17, 2024 23:11
@kenodegard kenodegard requested a review from a team as a code owner September 17, 2024 23:11
@kenodegard kenodegard merged commit 433f048 into conda:main Sep 18, 2024
30 checks passed
@kenodegard kenodegard deleted the render_recipe_test branch September 18, 2024 01:32
kenodegard added a commit to minrk/conda-build that referenced this pull request Sep 18, 2024
beeankha added a commit that referenced this pull request Sep 18, 2024
* discard unused variants before copying metadata

when variant matrix is large and mostly unused (as in conda-forge),
the length of input_variants may be several thousand
when only a few are actually used.

This causes `get_loop_vars` and `metadata.copy()` to become very expensive.

* try reducing with all used vars instead of loop vars

should reduce less

* perf: copy distributed variants list after subsetting

vastly reduces the number of copies computed for large variant matrices

* perf: pass used_vars subset to get_loop_vars

rather than computing all loop vars and then intersecting,
only consider relevant keys when computing loop vars

reduces get_used_loop_vars from O(n_vars * n_variants) to O(n_used_vars * n_variants)

* remove redundant deepcopy of config.variant

config.copy already copies this, no need to do it twice in metadata.copy

* add config.copy_variants method

to avoid calling pickle in too many places

* Update news/5392-variant-copy

* Add benchmark test for `render_recipe` (#5490)

---------

Co-authored-by: Matthew R. Becker <beckermr@users.noreply.github.com>
Co-authored-by: Bianca Henderson <beeankha@gmail.com>
Co-authored-by: Ken Odegard <kodegard@anaconda.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed [bot] added once the contributor has signed the CLA
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants