-
Notifications
You must be signed in to change notification settings - Fork 101
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
Feature/hisq fgi #1368
base: develop
Are you sure you want to change the base?
Feature/hisq fgi #1368
Conversation
…rrect data then clean up
…ks with 13b367d28d742534bac7ab0881d3876b4c6f11b3 in callat_qcd MILC feature/nested-force-gradient-integrator
@@ -124,6 +124,7 @@ void printQudaGaugeParam(QudaGaugeParam *param) { | |||
P(use_resident_mom, 0); | |||
P(make_resident_gauge, 0); | |||
P(make_resident_mom, 0); | |||
P(use_fgi, 1);// FGI: This needs to be 0, and set to 1 with MILC/QUDA interface |
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.
Should be set back to 0
, I'm guessing?
@@ -104,6 +103,32 @@ CloverField *cloverEigensolver = nullptr; | |||
cudaGaugeField *momResident = nullptr; | |||
cudaGaugeField *extendedGaugeResident = nullptr; | |||
|
|||
// These Copy fields are to support the Force Gradient Integrator |
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.
I'm not sure if I like the term "Copy"... maybe "Backup" would be a better term? "Previous"? I guess that would be best informed by the language of the FGI algorithm --- and if "copy" is the common language, that's good enough to me. (This also isn't a hill I'll die on!)
@@ -2086,8 +2142,11 @@ quda::cudaGaugeField *checkGauge(QudaInvertParam *param) | |||
param->cuda_prec_refinement_sloppy, param->cuda_prec_eigensolver}; | |||
QudaReconstructType recon[4] = {gaugeSloppy->Reconstruct(), gaugePrecondition->Reconstruct(), | |||
gaugeRefinement->Reconstruct(), gaugeEigensolver->Reconstruct()}; | |||
|
|||
printfQuda("QudaInvertParam has different precisions than loadGaugeQuda, so recomputing sloppy fields\n"); |
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.
I like the addition of this for logging reasons---I'd put this in a logQuda(QUDA_VERBOSE, [...]);
, I think.
@@ -2120,8 +2179,10 @@ quda::cudaGaugeField *checkGauge(QudaInvertParam *param) | |||
// recon is always no for fat links, so just use long reconstructs here | |||
QudaReconstructType recon[4] = {gaugeLongSloppy->Reconstruct(), gaugeLongPrecondition->Reconstruct(), | |||
gaugeLongRefinement->Reconstruct(), gaugeLongEigensolver->Reconstruct()}; | |||
printfQuda("QudaInvertParam has different precisions than loadGaugeQuda, so recomputing sloppy fields\n"); |
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.
Same as above
|
||
// Wilson Links | ||
//---------------------------------------------------------- | ||
if(gaugePrecise) { |
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.
Just confirming --- it's intentional that this doesn't throw an errorQuda
if gaugePrecise
is unset, right? I see that it's fully safe code on its own.
|
||
// Wilson Links | ||
//---------------------------------------------------------- | ||
if(gaugePrecise) gaugePrecise->copy(*gaugeCopyPrecise); |
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.
if (gaugePrecise && gaugeCopyPrecise)
@@ -1381,6 +1406,37 @@ void endQuda(void) | |||
|
|||
if(momResident) delete momResident; | |||
|
|||
// Delete MILC FGI 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.
I know we discussed moving these into freeUniqueGauge
, etc, offline --- just adding this comment so it can be marked as "resolved" at some point.
@@ -87,6 +87,8 @@ extern "C" { | |||
int return_result_gauge; /**< Return the result gauge field */ | |||
int return_result_mom; /**< Return the result momentum field */ | |||
|
|||
int use_fgi; /**< add FGI terms */ |
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.
Perhaps this should be a bool
instead? (Note that I'm going to kill QudaBoolean
at some point, and replace it with bool
- this is fine since bool
is supported on C99 which we require anyway for the QUDA C interface.)
@@ -1373,6 +1375,18 @@ extern "C" { | |||
*/ | |||
void momResidentQuda(void *mom, QudaGaugeParam *param); | |||
|
|||
/** |
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.
Some punctuation in this comment might be nice :P
Nothing controversial in this commit. One thought on the design used here: would it be a better fit to Just a thought. |
This WIP add functionality to allow for offload in the FGI RHMC routines in https://github.com/callat-qcd/milc_qcd/tree/feature/nested-force-gradient-integrator. It simply creates copy gauge and momentum fields consistent with MILC's QUDA offload sequences.