-
Notifications
You must be signed in to change notification settings - Fork 225
FieldTmp gather support
#2009
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
FieldTmp gather support
#2009
Conversation
b704d66 to
cabc47f
Compare
|
|
||
| /** gather data from neighbor GPU | ||
| * | ||
| * copy data from the border of neighboring GPU into the local guard. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add missing information that there is no race condition if asyncCommunicationGather is called before or after asyncCommunication
ax3l
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
little bug you found yourself and a few little comments for doc strings
| * | ||
| * If `true` it is possible to call the method `asyncCommunicationGather()` | ||
| * to copy data from the border of neighboring GPU into the local guard. | ||
| */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a bit more specific info: "This is also known as building up a "ghost" or "halo" region in domain decomposition and only necessary for specific algorithms that extend the basic PIC cyle, e.g. with dependence on derived density or energy fields."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh I see you tried if I copy&past your text without reading it^^ cyle must be cycle
|
|
||
| virtual EventTask asyncCommunication( EventTask serialEvent ); | ||
|
|
||
| /** gather data from neighbor GPU |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
neighboring GPUs
| { | ||
| /* guarding cells depend on direction | ||
| * for negative direction use originGuard else endGuard (relative direction ZERO is ignored) | ||
| * don't switch end and origin because this is a read buffer and no send buffer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and not a send buffer
|
|
||
| EventTask FieldTmp::asyncCommunicationGather( EventTask serialEvent ) | ||
| { | ||
| PMACC_VERIFY_MSG( fieldTmpSupportGatherCommunication == true, "fieldTmpSupportGatherCommunication in memory.param must be set to true" ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make me a two liner
| PMACC_VERIFY_MSG( fieldTmpSupportGatherCommunication == true, "fieldTmpSupportGatherCommunication in memory.param must be set to true" ); | ||
|
|
||
| if( fieldTmpRecv != nullptr ) | ||
| m_gatherEv = fieldTmpRecv->asyncCommunication( m_scatterEv + m_gatherEv ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
self-found by @psychocoderHPC : serialEvent needs to be handled here
e6bcf48 to
2c0e2cc
Compare
| * | ||
| * If `true` it is possible to call the method `asyncCommunicationGather()` | ||
| * to copy data from the border of neighboring GPU into the local guard. | ||
| */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
forgot:
- This is also known as building up a "ghost" or "halo" region in domain
- decomposition and only necessary for specific algorithms that extend
- the basic PIC cycle, e.g. with dependence on derived density or energy fields.
|
|
||
| uint32_t getCommTag(); | ||
|
|
||
| virtual EventTask asyncCommunication( EventTask serialEvent ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it would make sense to add a doxygen string here now, too
define a variable in `memory.param` to activate gather support for `FieldTmp`
- add method `asyncCommunicationGather()` (gather neighbor border data) - add buffer for gather communication
2c0e2cc to
1c2bbab
Compare
Adds the following changes to the `release-0.3.0` branch: - Multiple ionizers per species: `ionizer< ... >` became a sequence of `ionizers< ... >` ComputationalRadiationPhysics#1999 - Thomas-Fermi: - fixes in domain decomposition ComputationalRadiationPhysics#2007 - fixes compile issue (missing include) ComputationalRadiationPhysics#2003 - BSI models restructured ComputationalRadiationPhysics#2013 - ADK: fix effective principal quantum number `nEff` ComputationalRadiationPhysics#2011 - multiple ionization algorithms can be applied per species, e.g. cut-off barrier suppression ionization (BSI), probabilistic field ionization (ADK) and collisional ionization ComputationalRadiationPhysics#1999 - FieldTmp: Gather support to fill GUARD ComputationalRadiationPhysics#2009 - Fix undefined device variable in tilted laser pulse ComputationalRadiationPhysics#2017 - CompileTime Accessor: Type (::type) ComputationalRadiationPhysics#1998 - TBG Macros: Outdated Comment ComputationalRadiationPhysics#2004 Increases the state of the `0.3.0` release candidate to `rc3`.
Adds the following changes to the `release-0.3.0` branch: - Multiple ionizers per species: `ionizer< ... >` became a sequence of `ionizers< ... >` ComputationalRadiationPhysics#1999 - Thomas-Fermi: - fixes in domain decomposition ComputationalRadiationPhysics#2007 - fixes compile issue (missing include) ComputationalRadiationPhysics#2003 - BSI models restructured ComputationalRadiationPhysics#2013 - ADK: fix effective principal quantum number `nEff` ComputationalRadiationPhysics#2011 - multiple ionization algorithms can be applied per species, e.g. cut-off barrier suppression ionization (BSI), probabilistic field ionization (ADK) and collisional ionization ComputationalRadiationPhysics#1999 - FieldTmp: Gather support to fill GUARD ComputationalRadiationPhysics#2009 - Fix undefined device variable in tilted laser pulse ComputationalRadiationPhysics#2017 - CompileTime Accessor: Type (::type) ComputationalRadiationPhysics#1998 - TBG Macros: Outdated Comment ComputationalRadiationPhysics#2004 Increases the state of the `0.3.0` release candidate to `rc3`.
Add an explicit method to trigger that border data from the neighbor is gathered into the local guard of the GPU.
asyncCommunicationGather()(gather neighbor's border data)fieldTmpSupportGatherCommunicationvariable inmemory.paramto activate gather support forFieldTmpgetCommTag()Note
Currently the new method
asyncCommunicationGather()is only available inFieldTmpbut should be later also be ported to all other buffers likeFieldEandFieldB. The best way to do this is to extend the PMaccGridBufferto supportasyncCommunicationScatter()andasyncCommunicationGather().This is a bigger refactoring and should not be part of this pull request to allow a backport to the current release candidate
0.3.0.