[GRASS-dev] [GRASS GIS] #2074: r3.mapcalc neighborhood modifier hash table and tile errors

GRASS GIS trac at osgeo.org
Fri Oct 4 07:11:06 PDT 2013


#2074: r3.mapcalc neighborhood modifier hash table and tile errors
-------------------------+--------------------------------------------------
 Reporter:  wenzeslaus   |       Owner:  grass-dev@…              
     Type:  defect       |      Status:  new                      
 Priority:  normal       |   Milestone:  7.0.0                    
Component:  Raster3D     |     Version:  svn-trunk                
 Keywords:  r3.mapcalc   |    Platform:  All                      
      Cpu:  Unspecified  |  
-------------------------+--------------------------------------------------

Comment(by glynn):

 Replying to [comment:1 huhabla]:
 > I can confirm this issue in case grass7 is compiled with pthreads
 support. The errors appear randomly at different indices. Looks like a
 race condition to me. Hence this issue my be related to the pthreads
 parallelism in r3.mapcalc? The problem may be related to the static and
 global variables used in the raster3d library.
 >
 > When grass7 is compiled without pthreads support the errors disappear
 and everything works as expected.

 Does calling putenv("WORKERS=1") from setup_maps() in map3.c avoid the
 problem? Failing that, we'd need to add a mutex around most of the code in
 map3.c (see cats_mutex in map.c for an example).

-- 
Ticket URL: <https://trac.osgeo.org/grass/ticket/2074#comment:3>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list