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

Implement User Traits #344

Open
Matthew-Whitlock opened this issue May 30, 2024 · 0 comments · May be fixed by #345
Open

Implement User Traits #344

Matthew-Whitlock opened this issue May 30, 2024 · 0 comments · May be fixed by #345
Assignees

Comments

@Matthew-Whitlock
Copy link
Contributor

UserTraits

What: Serialize/deserialize calls are now also templated on UserTraits..., which is passed on to the base serializer. Some helpers for adding/removing and checking for the existence of trait are added as well.
Why: User traits allow arbitrary customization of serialization behavior based on user-defined terms. This enables more flexibility in checkpointing than an extra boolean variable, and is more clear in user-space code than a pre-defined variable name (EG: VT::RestoreProxies instead of s.isCheckpointRecovery())

Serialization overriding

What: When a non-intrusive serializer and an intrusive serializer are both found, call the non-intrusive serializer.
Why: Non-intrusive serializers can follow up with calls to the intrusive copy, meaning non-intrusive serializers can be used as a form of serialization subscriber. Particularly with user traits, we can define non-intrusive serializers which only run when a particular trait is used on a given object, allowing third parties (E.G. KokkosResilience) to perform custom logic before serialization of arbitrary objects. This can also be used to generally attach to serialization of objects for the purposes of tracing, etc.

For examples of these changes in action, see checkpoint_example_user_traits.cc/hpp

@Matthew-Whitlock Matthew-Whitlock self-assigned this May 30, 2024
@Matthew-Whitlock Matthew-Whitlock linked a pull request May 30, 2024 that will close this issue
@Matthew-Whitlock Matthew-Whitlock linked a pull request May 30, 2024 that will close this issue
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
For NVCC < 11.7.1, the templated static constexpr member variables give
the wrong results (has_trait_v replaced with has_trait::value).
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
For NVCC < 11.7.1, the templated static constexpr member variables give
the wrong results (has_trait_v replaced with has_trait::value).
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
For NVCC < 11.7.1, the templated static constexpr member variables give
the wrong results (has_trait_v replaced with has_trait::value).
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
For NVCC < 11.7.1, the templated static constexpr member variables give
the wrong results (has_trait_v replaced with has_trait::value).
Matthew-Whitlock added a commit that referenced this issue Sep 24, 2024
Also adds is_footprinter_v
Matthew-Whitlock added a commit that referenced this issue Sep 25, 2024
Also adds is_footprinter_v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant