-
Notifications
You must be signed in to change notification settings - Fork 876
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
btl/ofi selects libfabric shm provider with libfabric 1.20+ #12233
Comments
wenduwan
added a commit
to wenduwan/ompi
that referenced
this issue
Jan 13, 2024
This PR addresses open-mpi#12233 Since 5.0.x, we introduced an optional FI_HMEM capability in ofi provider selection logic(both mtl and btl) in order to support accelerator memory. As described in the issue, this introduced a bug that can cause the wrong ofi provider to be selected, even if the user explicitly includes/excludes the provider name. This change refactors the selection logic to correctly handle the include/exclude list, and therefore fixes the bug. Signed-off-by: Wenduo Wang <wenduwan@amazon.com>
wenduwan
added a commit
to wenduwan/ompi
that referenced
this issue
Jan 16, 2024
This PR addresses open-mpi#12233 Since 5.0.x, we introduced an optional FI_HMEM capability in ofi provider selection logic(both mtl and btl) in order to support accelerator memory. As described in the issue, this introduced a bug that can cause the wrong ofi provider to be selected, even if the user explicitly includes/excludes the provider name. This change refactors the selection logic to correctly handle the include/exclude list, and therefore fixes the bug. Signed-off-by: Wenduo Wang <wenduwan@amazon.com>
will be fixed when #12234 is backported |
Main branch PR merged. Will open backport. |
wenduwan
added a commit
to wenduwan/ompi
that referenced
this issue
Jan 19, 2024
This PR addresses open-mpi#12233 Since 5.0.x, we introduced an optional FI_HMEM capability in ofi provider selection logic(both mtl and btl) in order to support accelerator memory. As described in the issue, this introduced a bug that can cause the wrong ofi provider to be selected, even if the user explicitly includes/excludes the provider name. This change refactors the selection logic to correctly handle the include/exclude list, and therefore fixes the bug. Signed-off-by: Wenduo Wang <wenduwan@amazon.com> (cherry picked from commit 29efcef)
PRs merged. Closing. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Background information
What version of Open MPI are you using? (e.g., v4.1.6, v5.0.1, git branch name and hash, etc.)
main and v5.0.x branches
Describe how Open MPI was installed (e.g., from a source/distribution tarball, from a git clone, from an operating system distribution package, etc.)
./configure ... --with-libfabric=<libfabric that has prov/shm enabled>
If you are building/installing from a git clone, please copy-n-paste the output from
git submodule status
.Submodules are not relevant in this case, but we need a new libfabric with this commit: ofiwg/libfabric@7e84ace#diff-9a108fdcddc323ee5ec91488c1fbdd907d733c960c0bdcddd507803ec1bf3081
Please describe the system on which you are running
Details of the problem
The problem can be revealed by one-sided applications. We reproduced with Intel Microbenchmark
This is because with the libfabric change the shm provider also satisfies btl/ofi's requirement, i.e.
FI_HMEM | FI_ATOMIC | FI_RMA
, and it was later ignored because it is on the exclusion list. As a result, btl/ofi did not select any provider :(In this case, the user's attention was to use another provider, e.g. efa, that does not support
FI_HMEM
, but that didn't happen because shm was returned byfi_getinfo(...)
first.This behavior was introduced in 5.0.x due to the optional
FI_HMEM
check.Proposed solution
I think we should refactor both mtl/ofi and btl/ofi provider selection logic, and respect
{mtl/btl}_ofi_provider_{exclude/exclude}
MCA parameter. Specifically, right after eachfi_getinfo(...)
call, we should first apply the include/exclude filter, and return error if no qualified provider is found.For this particular problem, I'm surprised that shm was selected at all, since it only supports intra-node communication. I wonder whether we should also request
FI_REMOTE_COMM | FI_LOCAL_COMM
, the same as mtl/ofi.Mitigation
fi_getinfo
to return specific providers with-x PROVIDER=<the desired provider>
The text was updated successfully, but these errors were encountered: