Skip to content

ma_refine_number leads to crash #199

@KennethEJansen

Description

@KennethEJansen

This was the most stable phastaChef case of the many we have tried. Then, after more than 200 adapt cycles I get this:

86 rank 5261 badflag xyz -0.001536249417  0.006062729008               0 -0.001519191546  0.006013116779                   0
 87 rank 5261 badflag xyz  -0.00144037133  0.006048323858               0 -0.001536249417  0.006062729008                   0
 88 rank 3061 badflag xyz -0.001519190288  0.006013112085           0.025 -0.001488309744  0.006055524086           0.02    5
 89 rank 3061 badflag xyz -0.001488309744  0.006055524086           0.025 -0.001584186574  0.006069924541           0.02    5
 90 expected tag "ma_refine_number" on entity type 2
 91 expected tag "ma_refine_number" on entity type 2
 92 signal 6 caught by pcu
 93 signal 6 caught by pcu

The first 4 lines indicate a new failure in checkFlagConsistency. You might recall we had a problem with tags not matching for coarsening so Cameron helped me write a hack that, rather than aborting on an unmatched tag, it made it match. This allowed us to do the 200 successful adapts. Full disclosure, somewhere along the way, I also got failures in non-matching refinement tags. So I expanded the hack to deal with that (seemed to be a rare event). So, with the new failure I decided to fix ANY unmatched tag like this:

253     if(value != getFlag(a,e,flag)){ //detect mismatch
254      if(1) { // for COLLAPSE we will clear inconsistency and carry on
255 //     if(flag==SPLIT || flag==COLLAPSE) { // for COLLAPSE we will clear inconsistency and carry on
256         entFlagsToFlip.push_back(e); //buffer the mismatched ents
257         if(getFlag(a,e,flag) != 1) clearFlag(a,e,flag);
258         Entity* v[2]; // find and print the coordinates to stderr so we know where fixes applied
259         m->getDownward(e,0,v);
260         Vector x1 = getPosition(m, v[0]);
261         Vector x2 = getPosition(m, v[1]);
262         fprintf(stderr, "rank %d badflag xyz %15.10g %15.10g %15.10g %15.10g %15.10g %15.10g \n", PCU_Comm_Self(), x1.x(), x1.y(), x1.z(), x2.x    (), x2.y(), x2.z());
263       } else {
264         ok = false; // for other flags maintain the checkAndQuit approach
265       }

of course the real fix is below this but using the if(1) I think I should now be requesting any missmatched tag to get fixed.

This did not work though so it appears this bandaid doesn't extend to this new issue. Can someone familiar with the code clear up what is going on so that hopefully Cameron and I can figure out if another fix is possible?

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions