Skip to content

Instantly share code, notes, and snippets.

@dogbert17
Created February 4, 2021 18:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dogbert17/f0d40faf7cbd0582f11ac9279764e1cf to your computer and use it in GitHub Desktop.
Save dogbert17/f0d40faf7cbd0582f11ac9279764e1cf to your computer and use it in GitHub Desktop.
Data race
WARNING: ThreadSanitizer: data race (pid=670839)
Read of size 2 at 0x7b7000025370 by main thread:
#0 MVM_interp_run src/core/interp.c:6350 (libmoar.so+0x2728f6)
#1 MVM_vm_run_file src/moar.c:504 (libmoar.so+0x4a9de9)
#2 main src/main.c:305 (moar+0x30fe)
Previous write of size 8 at 0x7b7000025370 by thread T1:
#0 realloc <null> (libtsan.so.0+0x32666)
#1 MVM_realloc src/core/alloc.h:20 (libmoar.so+0x3d338c)
#2 ensure_space src/spesh/codegen.c:42 (libmoar.so+0x3d372a)
#3 write_int16 src/spesh/codegen.c:56 (libmoar.so+0x3d3908)
#4 write_instructions src/spesh/codegen.c:186 (libmoar.so+0x3d4f6c)
#5 MVM_spesh_codegen src/spesh/codegen.c:377 (libmoar.so+0x3d6261)
#6 MVM_spesh_candidate_add src/6model/reprs/MVMSpeshCandidate.c:257 (libmoar.so+0x42be35)
#7 worker src/spesh/worker.c:24 (libmoar.so+0x40e6ce)
#8 invoke_handler src/6model/reprs/MVMCFunction.c:9 (libmoar.so+0x33d089)
#9 thread_initial_invoke src/core/threads.c:58 (libmoar.so+0x29f322)
#10 MVM_interp_run src/core/interp.c:159 (libmoar.so+0x20ed85)
#11 start_thread src/core/threads.c:91 (libmoar.so+0x29f4b6)
#12 <null> <null> (libtsan.so.0+0x2d1af)
Location is heap block of size 2048 at 0x7b7000025000 allocated by thread T1:
#0 realloc <null> (libtsan.so.0+0x32666)
#1 MVM_realloc src/core/alloc.h:20 (libmoar.so+0x3d338c)
#2 ensure_space src/spesh/codegen.c:42 (libmoar.so+0x3d372a)
#3 write_int16 src/spesh/codegen.c:56 (libmoar.so+0x3d3908)
#4 write_instructions src/spesh/codegen.c:186 (libmoar.so+0x3d4f6c)
#5 MVM_spesh_codegen src/spesh/codegen.c:377 (libmoar.so+0x3d6261)
#6 MVM_spesh_candidate_add src/6model/reprs/MVMSpeshCandidate.c:257 (libmoar.so+0x42be35)
#7 worker src/spesh/worker.c:24 (libmoar.so+0x40e6ce)
#8 invoke_handler src/6model/reprs/MVMCFunction.c:9 (libmoar.so+0x33d089)
#9 thread_initial_invoke src/core/threads.c:58 (libmoar.so+0x29f322)
#10 MVM_interp_run src/core/interp.c:159 (libmoar.so+0x20ed85)
#11 start_thread src/core/threads.c:91 (libmoar.so+0x29f4b6)
#12 <null> <null> (libtsan.so.0+0x2d1af)
Thread T1 'spesh optimizer' (tid=670841, running) created by main thread at:
#0 pthread_create <null> (libtsan.so.0+0x5ea99)
#1 uv_thread_create_ex <null> (libmoar.so+0x521a81)
#2 MVM_spesh_worker_start src/spesh/worker.c:261 (libmoar.so+0x40f02d)
#3 MVM_vm_create_instance src/moar.c:443 (libmoar.so+0x4a98ef)
#4 main src/main.c:280 (moar+0x2f87)
SUMMARY: ThreadSanitizer: data race src/core/interp.c:6350 in MVM_interp_run
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment