ForestClaw / forestclaw

Quadtree/octree adaptive PDE solver based based on p4est.
http://www.forestclaw.org
BSD 2-Clause "Simplified" License
58 stars 22 forks source link

Fix point search synchronization #224

Closed cburstedde closed 2 years ago

cburstedde commented 2 years ago

So far the point search (as used for gauges in applications) did not always make results unique in parallel. Now we perform an additional collective communication to ensure that each point is found on at most one rank.

Please give it some testing with the gauges code.

I'd appreciate a merge commit due to multiple authors contributing and meaningful history.

scottaiton commented 2 years ago

I looks like the geoclaw regression tests are failing on exit with a memory leak warning.

https://github.com/ForestClaw/forestclaw/runs/7904806253?check_suite_focus=true#step:13:345

   [libsc 0] Memory balance (fclaw)
   [libsc 0] Memory balance (libsc)
   [fv-az186-268:07768] *** Process received signal ***
   [fv-az186-268:07768] Signal: Segmentation fault (11)
   [fv-az186-268:07768] Associated errno: Unknown error 21856 (21856)
   [fv-az186-268:07768] Signal code:  (0)
   [fv-az186-268:07768] Failing at address: 0x3ffffffff
   [fv-az186-268:07768] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x43090)[0x7f1d5429b090]
   [fv-az186-268:07768] [ 1] /lib/x86_64-linux-gnu/libpthread.so.0(pthread_mutex_lock+0x4)[0x7f1d54454fc4]
   [fv-az186-268:07768] [ 2] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xbce84)[0x5560e533de84]
   [fv-az186-268:07768] [ 3] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xbe0ad)[0x5560e533f0ad]
   [fv-az186-268:07768] [ 4] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xbe01d)[0x5560e533f01d]
   [fv-az186-268:07768] [ 5] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xbe42e)[0x5560e533f42e]
   [fv-az186-268:07768] [ 6] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xbf4f3)[0x5560e53404f3]
   [fv-az186-268:07768] [ 7] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0x60568)[0x5560e52e1568]
   [fv-az186-268:07768] [ 8] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xf656)[0x5560e5290656]
   [fv-az186-268:07768] [ 9] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3)[0x7f1d5427c083]
   [fv-az186-268:07768] [10] /home/runner/work/forestclaw/forestclaw/build/applications/geoclaw/bowl_radial/bowl_radial(+0xf8ce)[0x5560e52908ce]
   [fv-az186-268:07768] *** End of error message ***
scottaiton commented 2 years ago

I looks like this is probably caused by using SC_FREE instead of FCLAW_FREE.

cburstedde commented 2 years ago

I looks like this is probably caused by using SC_FREE instead of FCLAW_FREE.

You're right, thanks. With this latest push make check runs clean for me.