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

zfsbootmenu-core: optimize initramfs search #488

Merged
merged 1 commit into from
Sep 20, 2023

Conversation

ahesford
Copy link
Member

Walking through a four-level loop to find all possible initramfs images can be painful, and most times the distribution default will be in place. Let's front-load the initramfs search with commonly expected formats for popular distributions and avoid some of the pain of the complex but more exhaustive loop.

@ahesford ahesford force-pushed the we-dont-have-fuel-for-THIS branch 3 times, most recently from 674280c to e8a1636 Compare September 20, 2023 01:10
@ahesford ahesford force-pushed the we-dont-have-fuel-for-THIS branch from e8a1636 to 59d73f3 Compare September 20, 2023 01:13
Copy link
Member

@zdykstra zdykstra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://somebits.link/u/p/bc852bb11b/flamechart.svg

Nice improvement for both the normal cases the pathological case. Readable, and a net gain in speed.

@ahesford ahesford merged commit 40f7928 into master Sep 20, 2023
2 checks passed
@ahesford ahesford deleted the we-dont-have-fuel-for-THIS branch September 20, 2023 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants