Skip to content

Instantly share code, notes, and snippets.

@dogbert17
Created August 3, 2017 11:05
Show Gist options
  • Save dogbert17/04de6ec9fbb925469d378c04a0339c03 to your computer and use it in GitHub Desktop.
Save dogbert17/04de6ec9fbb925469d378c04a0339c03 to your computer and use it in GitHub Desktop.
dogbert@dogbert-VirtualBox ~/repos/rakudo $ ./perl6 -v
This is Rakudo version 2017.07-126-g86cb1363d built on MoarVM version 2017.07-299-g079dc9e9
implementing Perl 6.c.
dogbert@dogbert-VirtualBox ~/repos/rakudo $ for i in `seq 15`; do ./perl6 t/spec/integration/eval-and-threads.t; done
1..1
ok 1 - Simple EVAL in a loop does not crash
1..1
=================================================================
==7501== ERROR: AddressSanitizer: heap-use-after-free on address 0xabe5227c at pc 0xb564904d bp 0x9fff1a98 sp 0x9fff1a8c
READ of size 4 at 0xabe5227c thread T3
#0 0xb564904c in MVM_sc_get_collectable_sc /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.h:77
#1 0xb564904c in MVM_sc_get_obj_sc /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.h:82
#2 0xb564904c in MVM_interp_run /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/interp.c:3109
#3 0xb569769f in start_thread /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/threads.c:81
#4 0xb59c98f6 in uv__thread_start /home/dogbert/repos/rakudo/nqp/MoarVM/3rdparty/libuv/src/unix/thread.c:49
#5 0xb611d9c6 (/usr/lib/i386-linux-gnu/libasan.so.0+0x1a9c6)
#6 0xb610d2ac (/usr/lib/i386-linux-gnu/libasan.so.0+0xa2ac)
#7 0xb52cdf71 in start_thread (/lib/i386-linux-gnu/libpthread.so.0+0x6f71)
#8 0xb53d13ed (/lib/i386-linux-gnu/libc.so.6+0xee3ed)
0xabe5227c is located 1276 bytes inside of 1280-byte region [0xabe51d80,0xabe52280)
freed by thread T2 here:
#0 0xb61199b4 (/usr/lib/i386-linux-gnu/libasan.so.0+0x169b4)
#1 0xb57fd981 in MVM_realloc /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/alloc.h:20
#2 0xb57fd981 in MVM_sc_add_all_scs_entry /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.c:66
#3 0xb57fed74 in MVM_sc_create /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.c:11
#4 0xb563b603 in MVM_interp_run /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/interp.c:3015
#5 0xb569769f in start_thread /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/threads.c:81
#6 0xb59c98f6 in uv__thread_start /home/dogbert/repos/rakudo/nqp/MoarVM/3rdparty/libuv/src/unix/thread.c:49
#7 0xb53d13ed (/lib/i386-linux-gnu/libc.so.6+0xee3ed)
previously allocated by thread T3 here:
#0 0xb61199b4 (/usr/lib/i386-linux-gnu/libasan.so.0+0x169b4)
#1 0xb57fd981 in MVM_realloc /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/alloc.h:20
#2 0xb57fd981 in MVM_sc_add_all_scs_entry /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.c:66
#3 0xb57fed74 in MVM_sc_create /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.c:11
#4 0xb563b603 in MVM_interp_run /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/interp.c:3015
#5 0xb569769f in start_thread /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/threads.c:81
#6 0xb59c98f6 in uv__thread_start /home/dogbert/repos/rakudo/nqp/MoarVM/3rdparty/libuv/src/unix/thread.c:49
#7 0xb53d13ed (/lib/i386-linux-gnu/libc.so.6+0xee3ed)
Thread T3 created by T0 here:
#0 0xb610d1d0 (/usr/lib/i386-linux-gnu/libasan.so.0+0xa1d0)
#1 0xb59c9950 in uv_thread_create /home/dogbert/repos/rakudo/nqp/MoarVM/3rdparty/libuv/src/unix/thread.c:66
#2 0xb560209c in MVM_interp_run /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/interp.c:4035
#3 0xb59a6dc7 in MVM_vm_run_file /home/dogbert/repos/rakudo/nqp/MoarVM/src/moar.c:349
#4 0x8049133 in main /home/dogbert/repos/rakudo/nqp/MoarVM/src/main.c:253
#5 0xb52fcaf2 (/lib/i386-linux-gnu/libc.so.6+0x19af2)
Thread T2 created by T0 here:
#0 0xb610d1d0 (/usr/lib/i386-linux-gnu/libasan.so.0+0xa1d0)
#1 0xb59c9950 in uv_thread_create /home/dogbert/repos/rakudo/nqp/MoarVM/3rdparty/libuv/src/unix/thread.c:66
#2 0xb560209c in MVM_interp_run /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/interp.c:4035
#3 0xb59a6dc7 in MVM_vm_run_file /home/dogbert/repos/rakudo/nqp/MoarVM/src/moar.c:349
#4 0x8049133 in main /home/dogbert/repos/rakudo/nqp/MoarVM/src/main.c:253
#5 0xb52fcaf2 (/lib/i386-linux-gnu/libc.so.6+0x19af2)
SUMMARY: AddressSanitizer: heap-use-after-free /home/dogbert/repos/rakudo/nqp/MoarVM/src/6model/sc.h:77 MVM_sc_get_collectable_sc
Shadow bytes around the buggy address:
0x357ca3f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x357ca400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x357ca410: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x357ca420: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x357ca430: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
=>0x357ca440: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd[fd]
0x357ca450:fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x357ca460: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x357ca470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x357ca480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x357ca490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
Addressable: 00
Partially addressable: 01 02 03 04 05 06 07
Heap left redzone: fa
Heap righ redzone: fb
Freed Heap region: fd
Stack left redzone: f1
Stack mid redzone: f2
Stack right redzone: f3
Stack partial redzone: f4
Stack after return: f5
Stack use after scope: f8
Global redzone: f9
Global init order: f6
Poisoned by user: f7
ASan internal: fe
==7501== ABORTING
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment