Skip to content

Conversation

@raffenet
Copy link
Contributor

@raffenet raffenet commented Mar 19, 2025

Pull Request Description

Cleanup and refactor portions of the XPMEM code to support disabling the mapped segment cache. The goal is to aid experimentation on systems with XPMEM to better understand the impact of the cache on application performance.

Author Checklist

  • Provide Description
    Particularly focus on why, not what. Reference background, issues, test failures, xfail entries, etc.
  • Commits Follow Good Practice
    Commits are self-contained and do not do two things at once.
    Commit message is of the form: module: short description
    Commit message explains what's in the commit.
  • Passes All Tests
    Whitespace checker. Warnings test. Additional tests via comments.
  • Contribution Agreement
    For non-Argonne authors, check contribution agreement.
    If necessary, request an explicit comment from your companies PR approval manager.

We use this CVAR to control the initialization of XPMEM, so move it
where it is most appropriate.
@raffenet
Copy link
Contributor Author

test:mpich/ch4/xpmem

Use initialized state when deciding whether to use XPMEM. Avoid
overwriting the value MPIR_CVAR_CH4_XPMEM_ENABLE, which could be
modified during runtime by MPI_T.
Make init and finalize symmetrical. Avoid calling GAVL utilities
directly in finalize.
These functions are closely related. Combine them in a single file for
ease of maintenance. Make segment register and free private static
functions.
@raffenet raffenet force-pushed the xpmem-changes branch 2 times, most recently from b13e589 to 663255c Compare March 20, 2025 01:14
@raffenet
Copy link
Contributor Author

test:mpich/ch4/most
test:mpich/ch4/xpmem

@raffenet
Copy link
Contributor Author

test:mpich/ch4/most
test:mpich/ch4/xpmem

@raffenet
Copy link
Contributor Author

test:mpich/ch4/most
test:mpich/ch4/xpmem

@raffenet
Copy link
Contributor Author

test:mpich/ch4/most
test:mpich/ch4/xpmem

Implement search and insert functions for mapped cache segments. These
will be used by the handle mapping function, and will make for easier
targets when adding the ability to disable the segment cache.
There may situations where disabling the mapped segment cache is
desirable. Allow a way to control usage at runtime.
When the mapped segment cache is disabled, unmap segments once we are
done copying from them. Since we need access to the actual attached
address, we store it in the handle during mapping. To achieve this, we
pass the handle to map/unmap by reference rather than value to allow
modification of its contents.
@raffenet
Copy link
Contributor Author

test:mpich/ch4/most
test:mpich/ch4/xpmem

@raffenet raffenet requested a review from hzhou March 20, 2025 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant