Possible stale pointer problem with ImportanceBiasing

Geant4 Version: 10.07.p04+patch, 11.4.1+path
Operating System: Various
Compiler/Version: Various
CMake Version: Various


Following Stale pointers in parallel worlds? and the resulting fix in Bugzilla #2714, I have implemented an “emergency patch” (Does G4 have a recommended way to apply patches locally?) to both my 10.07.p04 and 11.4.1 Geant4 installations.

In the CDMS simulation framework, we are now seeing stale pointer failures coming from the ImportanceBiasing process, when it is triggered by the particle we want to bias. We see this problem with both releases, which suggests that it’s in code which was conserved across the G4 v10/v11 boundary.

When I run normally, I get a FatalException

-------- EEEE ------- G4Exception-START -------- EEEE -------
*** G4Exception : GeomNav1002
      issued by : G4TransportationManager::ActivateNavigator()
Navigator for volume -- not found in memory!
*** Fatal Exception *** core dump ***

Where “volume --” in the message means that the volume name is an empty string. If I build and run with GCC’s thread-sanitizer code enabled, then I get a massive cascade of 80+ thousand santizer errors,

WARNING: ThreadSanitizer: signal-unsafe call inside of a signal (pid=75407)

These all come from

    #2 G4TransportationManager::ActivateNavigator(G4Navigator*) <null> (libG4geometry.so+0x18d283)

and are probably equivalent to the empty string issue above. I am not sure that I’m going to be able to create a true MRE (because all this stuff is embedded in our CDMS simulation framework), but I’m hoping it’s sufficiently close to Bugzilla #2714 for that issue is obvious to the experts.

Who would be the best point of contact for me to open a dialogue about this issue? It’s possible that the error is on our end, which is the other reason I don’t want to open a Bugzilla report yet.

Hi Mike, we are working for putting in place a patch which will include a fix for this issue too. Sorry for the late answer, in general it is always good to open a ticket so issues can be tracked and properly followed up!

I agree, but (a) we don’t have an MRE (this is the full CDMS framework), and (b) it was only working before the #2714 fix, so I felt there was a good chance we had something we ourselves were doing wrong.

Thanks for letting me know there’s a patch in the works!