Closed Anto6453 closed 7 months ago
Hi @Anto6453 , thanks for the report. In order to reproduce this, could you send me the full setup you are using? (i.e. setup.cpp+idefix.ini) (can be by email if your don't want your setup to appear publicly).
Problem is that gridCoarsening tries to reconstruct the normal component of B from the divergence of the two tangential components of B stored in Vs. When DIMENSIONS<3, one of these components is not defined (because it's not stored on cell faces), resulting in a segfault (as it turns out, also on CPUs). The fix #230 will be part of Idefix v2.0.05 release.
v2.0.05 released with this bug fixed.
Describe the issue:
When using coarsening on X2 direction (corresponding to $\theta$ in spherical coordinates), I obtain an illegal memory access error when I try to run idefix on GPU (seen on A100 and RTX 2080 SUPER). The same configuration works on CPU.
In my case, I use a 2D-axisym spherical grid, and I divide my radial grid in one uniform grid in the inner domain, and one log grid in the outer domain. To avoid that my uniform grid in $r$ becomes too thin in the $\theta$ direction when it comes close to the center of the domain, in need to coars the grid in the $\theta$ direction.
My coarsening function :
where
radiusCoars
is the radius that delimits the uniform and the log grids.The error seems to occure when the number of points become too big. For example :
It also seems to be triggered more easily when I increase the maximum coarsening level (via
coarsIncrement
in the coarsening function).By looking at the log in debug mode, the error seems to appear when idefix is trying to coars the magnetic field while keeping divB equal to zero (in the second FLUID_CoarsenFlow_BXsn idefix_for loop in the src/fluid/coarsenFlow.hpp file).
Thanks in advance for your help.
Error message:
runtime information:
Idefix version 2.0.04-00e3db93 Master branch
Kokkos 30500
Seen on GPU A100 and RTX 2080 SUPER