-
Notifications
You must be signed in to change notification settings - Fork 900
__malloc_hook issue #1336
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
if you do that, when ucx is closed, it might restore the openib malloc hook. I am afraid we need something more complex |
I agree with @ggouaillardet -- sounds like some OPAL-level infrastructure to track the malloc hook is required. |
@igor-ivanov maybe at least we can install malloc hook for btl_openib, only if it's really used, and not if it is not eventually selected? |
These changes fix issue open-mpi#1336 opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. It is safe because it is linked statically.
These changes fix issue open-mpi#1336 opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. It is safe because it is linked statically.
These changes fix issue open-mpi#1336 opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. It is safe because it is linked statically.
These changes fix issue open-mpi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi/ompi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi/ompi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi/ompi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi/ompi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi/ompi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
These changes fix issue open-mpi#1336 - improve abstractions: opal/memory/linux component should be single place that opeartes with Memory Allocation Hooks. - avoid collisions in case dynamic component open/close: it is safe because it is linked statically. - does not change original behaivour.
This issue came from UCX:
btl openib sets __malloc_hook to handle alignment (added in this commit cd17fee)
when it’s closed (component_close), for example because another component has higher priority, it restores the original handler.
The problem is that the __malloc_hook may have been changed since then by other component (e.g UCX), and restoring the original handler overrides this other component setting (UCX).
As a result, when UCX is running, it installs __malloc_hook, but btl openib changes it “under its feet”
I think this should be fixed by checking that the currentl __malloc_hook still points to btl_openib’s replacement, before restoring the original.
The text was updated successfully, but these errors were encountered: