// Non-collective communication needed: // 1. Requests to migrate remote entities and (optionally) their // higher-order adjacencies. // Note that the iMesh implementation must be smart enough to change // ownership of lower-order entities that become orphaned due to migration. // TING: We dont use argument include_upward_adj, because we think that we only migrate // all (partition) objects around the lower-order mesh entity that is on the part boundary. void prefix_migrateEntity(iMesh_Instance instance, /*in*/ const prefix_PartitionHandle partition_handle, /*in*/ iBase_EntityHandle entity_handle, int *err); // TING: Do we need an array version? // void prefix_migrateEntArr(iMesh_Instance instance, // /*in*/ const prefix_PartitionHandle partition_handle, // /*in*/ iBase_EntityHandle *entity_handles, // /*in*/ int entity_handles_size, // int *err); // 2. Push entity data from owner to other parts for migrating entities // and updating remote copies. // TING: Here, the term 'remote copies' should be ghost entities. void prefix_updateGhostEntity(iMesh_Instance instance, /*in*/ const prefix_PartitionHandle partition_handle, /*in*/ iBase_EntityHandle entity_handle, int* err); // TING: Do we need an array version? // void prefix_updateGhostEntArr(iMesh_Instance instance, // /*in*/ const prefix_PartitionHandle partition_handle, // /*in*/ iBase_EntityHandle *entity_handles, // /*in*/ int entity_handles_size, // int* err); // 3. Allow parts to poll for requests and check status of their own // outstanding requests. int prefix_pollForRequests(iMesh_Instance instance, /*in*/ const prefix_PartitionHandle partition_handle, /*in*/ prefix_PartHandle* source_part_handles, /*in*/ int source_part_handles_size, /*in*/ int *message_tags, /*in*/ int message_tags_size, /*inout*/ int **flags, /*inout*/ int *flags_size, int* err); // TING: This function is similar to MPI_PROBE function. // 4. A "closing" blocking (perhaps collective) call that ensures all parts are done // and all requests are handled. This function may be where the ghosts are updated // for mesh consistency. void prefix_waitAll(iMesh_Instance instance, /*in*/ const prefix_PartitionHandle partition_handle, int *err); // 5. Capability to replace an entity with new entities, both locally and // remotely. This capability would include requests to perform an operation // on an entity copy (e.g., split that edge), as well as communication to update // remote entity handles for the new entities created. // TING: do we need to specify the argument 'Replace_OP'? void prefix_replaceEntity(iMesh_Instance instance, /*in*/ const prefix_PartitionHandle partition_handle, /*inout*/ iBase_EntityHandle parent_entity_handles, /*inout*/ iBase_EntityHandle* child_entity_handles, /*in*/ int child_entity_handles_size, /*out*/ int child_entity_handles_allocated, /*in*/ int Replace_OP, // eg. SPLIT int *err); // TING: Do we need an array version? // void prefix_replaceEntArr(iMesh_Instance instance, // /*in*/ const prefix_PartitionHandle partition_handle, // /*inout*/ iBase_EntityHandle *parent_entity_handles, // /*inout*/ iBase_EntityHandle **child_entity_handles, // /*in*/ int *child_entity_handles_size, // /*out*/ int *child_entity_handles_allocated, // /*in*/ int *Replace_OP, // eg. SPLIT // /*in*/ int Replace_OP_size, // int *err);