java.cr icon indicating copy to clipboard operation
java.cr copied to clipboard

Segfault: BDWGC vs JVM issue

Open ysbaddaden opened this issue 7 years ago • 1 comments

Running the test suite causes BDWGC to try to collect some memory, which sends a custom signal to all threads, asking them to stop. The JVM catches that signal, and forwards it back to the previous handler set by BDWGC, but that eventually segfaults.

Speculation: it's possible that the JVM starts a thread, and forwards the signal from that thread that libgc doesn't know about, causing a segfault.

  • LibGC v7.4.2 (?)
  • OpenJDK 8u162-b12 (ubuntu package -1~14.04)

ysbaddaden avatar Apr 10 '18 10:04 ysbaddaden

Correction: the crash seems to happen in the JVM signal handler:

[0x2b242a691c3d] ???
[0x2b242a696749] JVM_handle_linux_signal +393
[0x2b242a68a5b8] ???
[0x2b242b278330] ???
[0x450c80] GC_push_all_eager +64
[0x42b36f] ???
[0x4511dd] GC_mark_some +141
[0x45a69d] GC_stopped_mark +125
[0x45b0f0] GC_try_to_collect_inner +208
[0x45ba34] GC_collect_or_expand +372
[0x44d8bb] GC_alloc_large +187
[0x44dcac] GC_generic_malloc +348
[0x44deba] GC_core_malloc_atomic +250
[0x44f15e] GC_realloc +222

ysbaddaden avatar Apr 10 '18 10:04 ysbaddaden