Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallel Access from Java Application causes SegFault in Lace #3

Open
kfriedberger opened this issue Dec 17, 2020 · 0 comments
Open

Comments

@kfriedberger
Copy link

Our Java application crashes deterministically when using one central JSylvan instance from multiple threads.

Reported SegFault:

# A fatal error has been detected by the Java Runtime Environment:
#    SIGSEGV (0xb) at pc=0x00007fe4839db5b0, pid=5258, tid=5279
# JRE version: OpenJDK Runtime Environment (11.0.9.1+1) (build 11.0.9.1+1-Ubuntu-0ubuntu1.18.04)
# Java VM: OpenJDK 64-Bit Server VM (11.0.9.1+1-Ubuntu-0ubuntu1.18.04,
#          mixed mode, sharing, tiered, compressed oops, g1 gc, linux-amd64)
# Problematic frame:
#    C  [libsylvan.so+0x395b0]  lace_get_head+0x0
# Core dump will be written....

Stacktrace when crashing:

Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [libsylvan.so+0x395b0]  lace_get_head+0x0

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  jsylvan.JSylvan.makeOr(JJ)J+0
j  parallel_nqueens.SylvanBDDRegionManager.makeOr(Lparallel_nqueens/SylvanBDDRegion;
      Lparallel_nqueens/SylvanBDDRegion;)Lparallel_nqueens/SylvanBDDRegion;+11
j  parallel_nqueens.NQueensMain.build()V+120
...

We provide a small example project here: parallelNqueens.zip
This example project tries to solve two instances of N-queens in parallel and
crashes with with SegFault instantly when JSylvan internally calles lace_get_head.
The problem happens deterministically on several Ubuntu-based machines under OpenJDK 11 and 15.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant