Field/Function split: FieldFactory + two-level naming, remove AddLayout#336
Open
jacobmerson wants to merge 24 commits into
Open
Field/Function split: FieldFactory + two-level naming, remove AddLayout#336jacobmerson wants to merge 24 commits into
jacobmerson wants to merge 24 commits into
Conversation
jacobmerson
force-pushed
the
jacobmerson/field-function-split
branch
from
July 12, 2026 18:29
c74eefe to
bcb83df
Compare
jacobmerson
force-pushed
the
jacobmerson/conservative-transfer
branch
from
July 12, 2026 18:29
7dfbf1e to
5bda307
Compare
jacobmerson
force-pushed
the
jacobmerson/field-function-split
branch
2 times, most recently
from
July 12, 2026 22:50
0716c22 to
a16f1ea
Compare
…trix / load_vector) Squashed original commits: 0a27b53, 0c0e697
…nsfer Squashed original commits: bad8434, eca15d1, b4af186, 26f35c6, b8baf3b, 6b1d7f2, dba7966, 5baf365, 4b00ac1 (mesh_fields_rhs_integrator churn from 26f35c6/b8baf3b dropped)
Squashed original commits: 844dc1c, b4a4545, 629419f (sobol_sequence churn dropped)
…y buffers Squashed original commits: e7488c6, 4e68c80
…fter #308) Squashed original commit: 75a3045
Currently the petsc-based solver is only needed for conservative projection which requires MeshFields. So petsc is only linked when PCMS_ENABLE_PETSC and PCMS_ENABLE_MESHFIELDS
Add a shared, format-agnostic GID-to-local permutation and use it so the transfer operators handle sparse or reordered global IDs correctly. This allows us to reuse the global-to-local mapping for things outside of the serialization such as setting up the petsc arrays.
…olders Split the GID (layout) message from the field (data) message and reuse the field GID-permutation primitives so exchanges handle overlap masks and reordered global IDs without corrupting payloads.
The python pcms module links libpetsc.so dynamically when python_api is ON, so PETSc lib dir must be on LD_LIBRARY_PATH for import to succeed.
clang-tidy bugprone-implicit-widening-of-multiplication-result (treated as error) flagged int*int products used to size 64-bit Views in the intersection/MC RHS integrators and the field-exchange-planner test. Perform the multiplication in size_t via an explicit cast.
Forward-declare the RHS integrators
We had kokkos lambdas in private functions which does not compile.
First pass is to just make a host mirror. Long term, we need to ask PETSc team if there is a better way to handle this.
The idea is as follows: a function space creates a function. A Function<T> represents an object that can be evaluated. A Function<T> is a Field<T>. A Field<T> itself does not have evaluation capabilities, but has everything needed to be sent over the network.
naming model, removing AddLayout. Our goal was to remove the need for AddLayout and forcing the user to *know* what layouts they needed to add. This was the simplest strategy of the ones we tested. It also aligns to the idea that fields are likely to have names anyways. So, having a field and layout both have names allows convenient cacheing of the layout communicator and naming of fields that follows on its construction.
With Function<T> being the object that handles evaluatable fields and Field<T> being the non-evaluatable object that can be used for sending over the network. This commit makes the function naming/usage consisent.
jacobmerson
force-pushed
the
jacobmerson/field-function-split
branch
from
July 13, 2026 07:11
a16f1ea to
fed617a
Compare
jacobmerson
force-pushed
the
jacobmerson/conservative-transfer
branch
from
July 13, 2026 07:11
2730ec6 to
c72ccad
Compare
jacobmerson
changed the base branch from
jacobmerson/conservative-transfer
to
develop
July 21, 2026 09:14
Sichao25
changed the base branch from
develop
to
jacobmerson/conservative-transfer
July 21, 2026 21:24
Sichao25
changed the base branch from
jacobmerson/conservative-transfer
to
develop
July 22, 2026 04:08
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Splits field construction from the function-space concept and removes
AddLayout, reworking field construction and coupler registration around a two-level naming model.Highlights:
FieldFactory; rework construction around two-level naming, removingAddLayoutCreateFunction/CreateFieldsplitBase is
jacobmerson/conservative-transfer(#335)