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

GRASS GIS trac at osgeo.org
Fri Oct 4 03:48:15 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 huhabla):

 Race condition confirmed with valgrind.

 Using:
 {{{
 valgrind --tool=helgrind r3.mapcalc "new_map = (test_map + test_map[1, 1,
 0]) / 2" --o
 }}}

 Produces:

 {{{
 GRASS 7.0.svn (TestLL):~/src/grass7.0/grass_trunk > valgrind
 --tool=helgrind r3.mapcalc "new_map = (test_map + test_map[1, 1, 0]) / 2"
 --o
 ==24618== Helgrind, a thread error detector
 ==24618== Copyright (C) 2007-2011, and GNU GPL'd, by OpenWorks LLP et al.
 ==24618== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright
 info
 ==24618== Command: r3.mapcalc new_map\ =\ (test_map\ +\ test_map[1,\ 1,\
 0])\ /\ 2 --o
 ==24618==
 ==24618== ---Thread-Announcement------------------------------------------
 ==24618==
 ==24618== Thread #3 was created
 ==24618==    at 0x5CD0C8E: clone (clone.S:77)
 ==24618==    by 0x56CAF6F: do_clone.constprop.4 (createthread.c:75)
 ==24618==    by 0x56CC57F: pthread_create@@GLIBC_2.2.5
 (createthread.c:256)
 ==24618==    by 0x4C2DAAD: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x508429E: G_init_workers (worker.c:124)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #3: pthread_cond_{signal,broadcast}: dubious: associated
 lock is not held by any thread
 ==24618==    at 0x4C2CC23: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5084022: worker (worker.c:47)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ---Thread-Announcement------------------------------------------
 ==24618==
 ==24618== Thread #2 was created
 ==24618==    at 0x5CD0C8E: clone (clone.S:77)
 ==24618==    by 0x56CAF6F: do_clone.constprop.4 (createthread.c:75)
 ==24618==    by 0x56CC57F: pthread_create@@GLIBC_2.2.5
 (createthread.c:256)
 ==24618==    by 0x4C2DAAD: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x508429E: G_init_workers (worker.c:124)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #2: lock order "0x52934C0 before 0x6984810" violated
 ==24618==
 ==24618== Observed (incorrect) order is: acquisition of lock at 0x6984810
 ==24618==    at 0x4C2D1BE: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5083FEA: worker (worker.c:39)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618==  followed by a later acquisition of lock at 0x52934C0
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084069: G_begin_execute (worker.c:74)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Required order was established by acquisition of lock at
 0x52934C0
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084069: G_begin_execute (worker.c:74)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618==  followed by a later acquisition of lock at 0x6984810
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084109: G_begin_execute (worker.c:86)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x6984840 by thread
 #2
 ==24618== Locks held: 2, at addresses 0x52934C0 0x6984810
 ==24618==    at 0x50840B2: G_begin_execute (worker.c:60)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x5083FFD: worker (worker.c:43)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6984840 is 128 bytes inside a block of size 1024
 alloc'd
 ==24618==    at 0x4C29F64: calloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5063076: G__calloc (alloc.c:81)
 ==24618==    by 0x5084245: G_init_workers (worker.c:118)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ---Thread-Announcement------------------------------------------
 ==24618==
 ==24618== Thread #4 was created
 ==24618==    at 0x5CD0C8E: clone (clone.S:77)
 ==24618==    by 0x56CAF6F: do_clone.constprop.4 (createthread.c:75)
 ==24618==    by 0x56CC57F: pthread_create@@GLIBC_2.2.5
 (createthread.c:256)
 ==24618==    by 0x4C2DAAD: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x508429E: G_init_workers (worker.c:124)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #4: pthread_cond_{signal,broadcast}: dubious: associated
 lock is not held by any thread
 ==24618==    at 0x4C2CC23: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5084022: worker (worker.c:47)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 4 at 0x6982690 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DC80: Rast3d_cache_hash_name2index (cachehash.c:110)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA8: Rast3d_cache_hash_name2index (cachehash.c:121)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==
 ==24618== Address 0x6982690 is 32 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 4 at 0x6982688 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DC87: Rast3d_cache_hash_name2index (cachehash.c:111)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA5: Rast3d_cache_hash_name2index (cachehash.c:119)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==
 ==24618== Address 0x6982688 is 24 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 1 at 0x6982920 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DC98: Rast3d_cache_hash_name2index (cachehash.c:114)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 1 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DC3E: Rast3d_cache_hash_load_name (cachehash.c:101)
 ==24618==    by 0x4E3CA5A: Rast3d_cache_elt_ptr (cache1.c:491)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x6982920 is 0 bytes inside a block of size 125 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB72: Rast3d_cache_hash_new (cachehash.c:63)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 4 at 0x69826E0 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCA2: Rast3d_cache_hash_name2index (cachehash.c:117)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DC3B: Rast3d_cache_hash_load_name (cachehash.c:100)
 ==24618==    by 0x4E3CA5A: Rast3d_cache_elt_ptr (cache1.c:491)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x69826E0 is 0 bytes inside a block of size 500 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB67: Rast3d_cache_hash_new (cachehash.c:62)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x6982688 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCA5: Rast3d_cache_hash_name2index (cachehash.c:119)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA5: Rast3d_cache_hash_name2index (cachehash.c:119)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==
 ==24618== Address 0x6982688 is 24 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x6982690 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCA8: Rast3d_cache_hash_name2index (cachehash.c:121)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA8: Rast3d_cache_hash_name2index (cachehash.c:121)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==
 ==24618== Address 0x6982690 is 32 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x698268C by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCAF: Rast3d_cache_hash_name2index (cachehash.c:120)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCAF: Rast3d_cache_hash_name2index (cachehash.c:120)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==
 ==24618== Address 0x698268C is 28 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 1 at 0x65D86B0 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E44C8D: Rast3d_get_double_region (getvalue.c:231)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 1 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4C2FDD6: memcpy (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E443C3: Rast3d_copy_from_xdr (fpxdr.c:230)
 ==24618==    by 0x4E4CC2C: Rast3d_read_tile (tileread.c:22)
 ==24618==    by 0x4E3D4B8: cacheRead_readFun (cache.c:14)
 ==24618==    by 0x4E3CABA: Rast3d_cache_elt_ptr (cache1.c:505)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==
 ==24618== Address 0x65D86B0 is 0 bytes inside a block of size 3840000
 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3C3ED: Rast3d_cache_new (cache1.c:105)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5670 by thread
 #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x5084184: G_end_execute (worker.c:98)
 ==24618==    by 0x4053D6: evaluate_function (evaluate.c:112)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x6983050 by thread
 #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x409C44: f_add (xadd.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x407B0A: read_map.isra.1 (map3.c:103)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6983050 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x405196: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #2: pthread_cond_{signal,broadcast}: dubious: associated
 lock is not held by any thread
 ==24618==    at 0x4C2CC23: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5084022: worker (worker.c:47)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ---Thread-Announcement------------------------------------------
 ==24618==
 ==24618== Thread #1 is the program's root thread
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x61A9E0 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x405984: execute (evaluate.c:330)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous read of size 4 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x405634: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #1: lock order "0x6984810 before 0x52934C0" violated
 ==24618==
 ==24618== Observed (incorrect) order is: acquisition of lock at 0x52934C0
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084069: G_begin_execute (worker.c:74)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618==  followed by a later acquisition of lock at 0x6984810
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084109: G_begin_execute (worker.c:86)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Required order was established by acquisition of lock at
 0x6984810
 ==24618==    at 0x4C2D1BE: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5083FEA: worker (worker.c:39)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618==  followed by a later acquisition of lock at 0x52934C0
 ==24618==    at 0x4C2E0ED: pthread_mutex_lock (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084069: G_begin_execute (worker.c:74)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ---Thread-Announcement------------------------------------------
 ==24618==
 ==24618== Thread #5 was created
 ==24618==    at 0x5CD0C8E: clone (clone.S:77)
 ==24618==    by 0x56CAF6F: do_clone.constprop.4 (createthread.c:75)
 ==24618==    by 0x56CC57F: pthread_create@@GLIBC_2.2.5
 (createthread.c:256)
 ==24618==    by 0x4C2DAAD: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x508429E: G_init_workers (worker.c:124)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #5: pthread_cond_{signal,broadcast}: dubious: associated
 lock is not held by any thread
 ==24618==    at 0x4C2CC23: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x5084022: worker (worker.c:47)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x6984840 by thread
 #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x5083FFD: worker (worker.c:43)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous read of size 8 by thread #2
 ==24618== Locks held: 2, at addresses 0x52934C0 0x6984810
 ==24618==    at 0x50840B2: G_begin_execute (worker.c:60)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6984840 is 128 bytes inside a block of size 1024
 alloc'd
 ==24618==    at 0x4C29F64: calloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5063076: G__calloc (alloc.c:81)
 ==24618==    by 0x5084245: G_init_workers (worker.c:118)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5B70 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x5084184: G_end_execute (worker.c:98)
 ==24618==    by 0x4053D6: evaluate_function (evaluate.c:112)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5B70 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406CD8: operator (expression.c:41)
 ==24618==    by 0x4136BA: yyparse (mapcalc.y:165)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x69834F0 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x40AB82: f_div (xdiv.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x40AC0E: f_double (xdouble.c:37)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x69834F0 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x4050CF: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5B70 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x5084051: G_begin_execute (worker.c:71)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5B70 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406CD8: operator (expression.c:41)
 ==24618==    by 0x4136BA: yyparse (mapcalc.y:165)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x6984840 by thread
 #1
 ==24618== Locks held: 1, at address 0x52934C0
 ==24618==    at 0x50840B2: G_begin_execute (worker.c:60)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x5083FFD: worker (worker.c:43)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6984840 is 128 bytes inside a block of size 1024
 alloc'd
 ==24618==    at 0x4C29F64: calloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5063076: G__calloc (alloc.c:81)
 ==24618==    by 0x5084245: G_init_workers (worker.c:118)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x65D5B70 by thread
 #1
 ==24618== Locks held: 1, at address 0x52934C0
 ==24618==    at 0x50840F8: G_begin_execute (worker.c:78)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5B70 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406CD8: operator (expression.c:41)
 ==24618==    by 0x4136BA: yyparse (mapcalc.y:165)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984990 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5670 by thread
 #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x5084051: G_begin_execute (worker.c:71)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #5
 ==24618== Locks held: 1, at address 0x6984990
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984990 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x65D5670 by thread
 #2
 ==24618== Locks held: 2, at addresses 0x52934C0 0x6984810
 ==24618==    at 0x50840F8: G_begin_execute (worker.c:78)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #5
 ==24618== Locks held: 1, at address 0x6984990
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984990 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5670 by thread
 #2
 ==24618== Locks held: 2, at addresses 0x6984810 0x6984910
 ==24618==    at 0x508419C: G_end_execute (worker.c:104)
 ==24618==    by 0x4053D6: evaluate_function (evaluate.c:112)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #5
 ==24618== Locks held: 1, at address 0x6984990
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x6983050 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x407B0A: read_map.isra.1 (map3.c:103)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous read of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x409C44: f_add (xadd.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6983050 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x405196: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x65D5670 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous read of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x5084184: G_end_execute (worker.c:98)
 ==24618==    by 0x4053D6: evaluate_function (evaluate.c:112)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D5670 by thread
 #2
 ==24618== Locks held: 2, at addresses 0x6984810 0x6984910
 ==24618==    at 0x50841B3: G_end_execute (worker.c:104)
 ==24618==    by 0x4053D6: evaluate_function (evaluate.c:112)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x508400F: worker (worker.c:45)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D5670 is 80 bytes inside a block of size 88 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x406757: mapname (expression.c:41)
 ==24618==    by 0x4138E0: yyparse (mapcalc.y:128)
 ==24618==    by 0x414077: parse_string (mapcalc.y:253)
 ==24618==    by 0x40432C: main (main.c:148)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x6982688 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA5: Rast3d_cache_hash_name2index (cachehash.c:119)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCA5: Rast3d_cache_hash_name2index (cachehash.c:119)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x6982688 is 24 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x6982690 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCA8: Rast3d_cache_hash_name2index (cachehash.c:121)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCA8: Rast3d_cache_hash_name2index (cachehash.c:121)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x6982690 is 32 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x698268C by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCAF: Rast3d_cache_hash_name2index (cachehash.c:120)
 ==24618==    by 0x4E3C631: Rast3d_cache_unlock (cache1.c:306)
 ==24618==    by 0x4E3CAD1: Rast3d_cache_elt_ptr (cache1.c:500)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCAF: Rast3d_cache_hash_name2index (cachehash.c:120)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x698268C is 28 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984890 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 4 at 0x698268C by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x4E3DCB8: Rast3d_cache_hash_name2index (cachehash.c:112)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 4 by thread #3
 ==24618== Locks held: 1, at address 0x6984890
 ==24618==    at 0x4E3DCAF: Rast3d_cache_hash_name2index (cachehash.c:120)
 ==24618==    by 0x4E3C99B: Rast3d_cache_elt_ptr (cache1.c:469)
 ==24618==    by 0x4E4C1BB: Rast3d_get_tile_ptr (tileio.c:88)
 ==24618==    by 0x4E44C82: Rast3d_get_double_region (getvalue.c:224)
 ==24618==    by 0x4E44DCD: Rast3d_get_value_region (getvalue.c:263)
 ==24618==    by 0x4E4ACF2: Rast3d_nearest_neighbor (resample.c:39)
 ==24618==    by 0x407B3B: read_map.isra.1 (map3.c:99)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==
 ==24618== Address 0x698268C is 28 bytes inside a block of size 40 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x4E3BED6: Rast3d_malloc (alloc.c:28)
 ==24618==    by 0x4E3DB51: Rast3d_cache_hash_new (cachehash.c:55)
 ==24618==    by 0x4E3C495: Rast3d_cache_new (cache1.c:127)
 ==24618==    by 0x4E3C559: Rast3d_cache_new_read (cache1.c:164)
 ==24618==    by 0x4E3D715: Rast3d_init_cache (cache.c:25)
 ==24618==    by 0x4E46032: Rast3d_fill_header (header.c:446)
 ==24618==    by 0x4E49629: Rast3d_open_cell_old (open.c:164)
 ==24618==    by 0x407F59: open_map (map3.c:510)
 ==24618==    by 0x4051B4: initialize_function (evaluate.c:50)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984990 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x6983058 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x404A2D: column_shift (column_shift.c:44)
 ==24618==    by 0x407AD5: read_map.isra.1 (map3.c:361)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #5
 ==24618== Locks held: 1, at address 0x6984990
 ==24618==    at 0x407B0A: read_map.isra.1 (map3.c:103)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6983058 is 8 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x405196: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x6983050 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x404A1C: column_shift (column_shift.c:47)
 ==24618==    by 0x407AD5: read_map.isra.1 (map3.c:361)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous read of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x409C44: f_add (xadd.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6983050 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x405196: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 8 at 0x6983050 by thread
 #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x52AE640: Rast_set_d_null_value (string3.h:52)
 ==24618==    by 0x407A36: read_map.isra.1 (map3.c:348)
 ==24618==    by 0x40564C: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== This conflicts with a previous read of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x409C44: f_add (xadd.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6983050 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x405196: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984910 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x61A9F0 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x4059A0: execute (evaluate.c:329)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous read of size 4 by thread #4
 ==24618== Locks held: 1, at address 0x6984910
 ==24618==    at 0x40563D: do_evaluate (evaluate.c:151)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x65D6380 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x40AB76: f_div (xdiv.c:66)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x409C20: f_add (xadd.c:64)
 ==24618==    by 0x4053ED: evaluate_function (evaluate.c:174)
 ==24618==    by 0x5083FF8: worker (worker.c:41)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x65D6380 is 0 bytes inside a block of size 960 alloc'd
 ==24618==    at 0x4C2B87D: malloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5062FE4: G__malloc (alloc.c:39)
 ==24618==    by 0x4050CF: initialize_function (evaluate.c:27)
 ==24618==    by 0x40513F: initialize_function (evaluate.c:88)
 ==24618==    by 0x405920: execute (evaluate.c:71)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Lock at 0x52934C0 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084200: G_init_workers (worker.c:114)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Lock at 0x6984810 was first observed
 ==24618==    at 0x4C2DDF1: pthread_mutex_init (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x508427C: G_init_workers (worker.c:122)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== Possible data race during read of size 8 at 0x69847C0 by thread
 #1
 ==24618== Locks held: 1, at address 0x52934C0
 ==24618==    at 0x5084091: G_begin_execute (worker.c:60)
 ==24618==    by 0x40539D: evaluate_function (evaluate.c:107)
 ==24618==    by 0x405A20: execute (evaluate.c:210)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous write of size 8 by thread #2
 ==24618== Locks held: 1, at address 0x6984810
 ==24618==    at 0x5083FFD: worker (worker.c:43)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x69847C0 is 0 bytes inside a block of size 1024 alloc'd
 ==24618==    at 0x4C29F64: calloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5063076: G__calloc (alloc.c:81)
 ==24618==    by 0x5084245: G_init_workers (worker.c:118)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Possible data race during write of size 4 at 0x6984938 by thread
 #1
 ==24618== Locks held: none
 ==24618==    at 0x50842F4: G_finish_workers (worker.c:134)
 ==24618==    by 0x4059B5: execute (evaluate.c:350)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== This conflicts with a previous read of size 4 by thread #4
 ==24618== Locks held: none
 ==24618==    at 0x508402F: worker (worker.c:36)
 ==24618==    by 0x4C2DC3D: ??? (in /usr/lib/valgrind/vgpreload_helgrind-
 amd64-linux.so)
 ==24618==    by 0x56CBE99: start_thread (pthread_create.c:308)
 ==24618==
 ==24618== Address 0x6984938 is 376 bytes inside a block of size 1024
 alloc'd
 ==24618==    at 0x4C29F64: calloc (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5063076: G__calloc (alloc.c:81)
 ==24618==    by 0x5084245: G_init_workers (worker.c:118)
 ==24618==    by 0x4057E6: execute (evaluate.c:327)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
 ==24618== ----------------------------------------------------------------
 ==24618==
 ==24618== Thread #1's call to pthread_mutex_destroy failed
 ==24618==    with error code 16 (EBUSY: Device or resource busy)
 ==24618==    at 0x4C2DF2F: pthread_mutex_destroy (in /usr/lib/valgrind
 /vgpreload_helgrind-amd64-linux.so)
 ==24618==    by 0x5084343: G_finish_workers (worker.c:141)
 ==24618==    by 0x4059B5: execute (evaluate.c:350)
 ==24618==    by 0x404387: main (main.c:158)
 ==24618==
  100%
 ==24618==
 ==24618== For counts of detected and suppressed errors, rerun with: -v
 ==24618== Use --history-level=approx or =none to gain increased speed, at
 ==24618== the cost of reduced accuracy of conflicting-access information
 ==24618== ERROR SUMMARY: 1029629 errors from 42 contexts (suppressed:
 655560 from 190)
 }}}

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



More information about the grass-dev mailing list