mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-12-28 03:37:59 +00:00
ENH: Added Pstream tags to mapped field types
This commit is contained in:
@ -190,6 +190,11 @@ void mappedFieldFvPatchField<Type>::updateCoeffs()
|
||||
|
||||
typedef GeometricField<Type, fvPatchField, volMesh> fieldType;
|
||||
|
||||
// Since we're inside initEvaluate/evaluate there might be processor
|
||||
// comms underway. Change the tag we use.
|
||||
int oldTag = UPstream::msgType();
|
||||
UPstream::msgType() = oldTag + 1;
|
||||
|
||||
const fvMesh& nbrMesh = refCast<const fvMesh>(sampleMesh());
|
||||
|
||||
// Result of obtaining remote values
|
||||
@ -317,6 +322,9 @@ void mappedFieldFvPatchField<Type>::updateCoeffs()
|
||||
<< endl;
|
||||
}
|
||||
|
||||
// Restore tag
|
||||
UPstream::msgType() = oldTag;
|
||||
|
||||
fixedValueFvPatchField<Type>::updateCoeffs();
|
||||
}
|
||||
|
||||
|
||||
@ -102,6 +102,11 @@ void Foam::mappedFixedInternalValueFvPatchField<Type>::updateCoeffs()
|
||||
return;
|
||||
}
|
||||
|
||||
// Since we're inside initEvaluate/evaluate there might be processor
|
||||
// comms underway. Change the tag we use.
|
||||
int oldTag = UPstream::msgType();
|
||||
UPstream::msgType() = oldTag + 1;
|
||||
|
||||
// Retrieve the neighbour values and assign to this patch boundary field
|
||||
mappedFixedValueFvPatchField<Type>::updateCoeffs();
|
||||
|
||||
@ -148,6 +153,9 @@ void Foam::mappedFixedInternalValueFvPatchField<Type>::updateCoeffs()
|
||||
}
|
||||
}
|
||||
|
||||
// Restore tag
|
||||
UPstream::msgType() = oldTag;
|
||||
|
||||
// Assign to (this) patch internal field its neighbour values
|
||||
Field<Type>& intFld = const_cast<Field<Type>&>(this->internalField());
|
||||
UIndirectList<Type>(intFld, this->patch().faceCells()) = nbrIntFld;
|
||||
|
||||
@ -224,6 +224,11 @@ void mappedFixedValueFvPatchField<Type>::updateCoeffs()
|
||||
|
||||
typedef GeometricField<Type, fvPatchField, volMesh> fieldType;
|
||||
|
||||
// Since we're inside initEvaluate/evaluate there might be processor
|
||||
// comms underway. Change the tag we use.
|
||||
int oldTag = UPstream::msgType();
|
||||
UPstream::msgType() = oldTag + 1;
|
||||
|
||||
// Get the scheduling information from the mappedPatchBase
|
||||
const mappedPatchBase& mpp = refCast<const mappedPatchBase>
|
||||
(
|
||||
@ -389,6 +394,9 @@ void mappedFixedValueFvPatchField<Type>::updateCoeffs()
|
||||
<< endl;
|
||||
}
|
||||
|
||||
// Restore tag
|
||||
UPstream::msgType() = oldTag;
|
||||
|
||||
fixedValueFvPatchField<Type>::updateCoeffs();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user