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

[LibOS] Keep all VMAs of a given LibOS handle on a linked list #1917

Open
dimakuv opened this issue Jun 19, 2024 · 0 comments
Open

[LibOS] Keep all VMAs of a given LibOS handle on a linked list #1917

dimakuv opened this issue Jun 19, 2024 · 0 comments
Labels
enhancement New feature or request P: 2

Comments

@dimakuv
Copy link
Contributor

dimakuv commented Jun 19, 2024

Description of the feature

Currently, if some LibOS handle operation needs to access a VMA corresponding to that memory address/range, the only way to do so is to iterate over all VMAs and filter out the ones that correspond to this LibOS handle. Thus, even if the LibOS handle a couple VMAs associated with it, any VMA-accessing operation will see traverse over all VMAs. This can become expensive.

One example is reload_mmaped_from_file_handle(). Another example can be found in PR #1818.

The proposal from @mwkmwkmwk is to keep all VMAs of a given libos_handle on a linked list. This will significantly speed up VMA-specific operations linked to a particular handle.

This issue is extracted from discussion https://reviewable.io/reviews/gramineproject/gramine/1818#-NybRQD02P8LkpEw7ztX

Why Gramine should implement it?

Performance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request P: 2
Projects
None yet
Development

No branches or pull requests

1 participant