-
-
Notifications
You must be signed in to change notification settings - Fork 169
Implement sorting of the memory map produced by exit_boot_services
#661
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
Comments
exit_boot_services
Hi. Generally speaking, we are open for high-level interfaces and API simplifications. Do you have a specific implementation in mind? If so, feel free to submit a PR so we can discuss further. |
Should we keep a way to obtain an unsorted memory map, or should the memory map just always be sorted for convenience? I don't see any uses that could be better done with an unsorted memory map, so the only cost would be the time needed to sort. |
I thought a little about this and came to the conclusion that instead of a new heap-structure, which will be tricky to implement, I'd prefer a stateful-iterator that always searches for the next bigger element in the memory map (according to the begin address). Given the fact that the map will not be iterated that often and that hundreds or thousands of entries are unlikely, this should be feasible. |
To facilitate construction of memory managers, would it be possible to implement a method to obtain a sorted memory map upon a call to 'exit_boot_services'? Since iterators can't be sorted, one first has to allocate memory to event begin to be able to sort the map, which complicates design. Implementing such a capability here would be much easier, as we have access to the slice, rather than the iterator.
The text was updated successfully, but these errors were encountered: