Hi, This appears to be the same issue as described here:
https://bugs.openjdk.java.net/browse/JDK-8022407 that I can trigger with the following test case (SIGSEGV on a null pointer): https://gist.github.com/mbelop/6ebb11d7e583562279abfb2e3b733fa5 Regards, Mike Index: devel/jdk/1.8/patches/patch-hotspot_make_bsd_makefiles_gcc_make =================================================================== RCS file: devel/jdk/1.8/patches/patch-hotspot_make_bsd_makefiles_gcc_make diff -N devel/jdk/1.8/patches/patch-hotspot_make_bsd_makefiles_gcc_make --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ devel/jdk/1.8/patches/patch-hotspot_make_bsd_makefiles_gcc_make 25 May 2018 16:08:02 -0000 @@ -0,0 +1,23 @@ +$OpenBSD$ + +Make the fix for 8022407 available on all Clang versions. + +8022407: sun/misc/CopyMemory.java fails with SIGSEGV in Unsafe_SetByte+0x35 +Summary: lower optimization level for unsafe.cpp due to MacOS Xcode 4.6.2 compiler optimization issue. + +Index: hotspot/make/bsd/makefiles/gcc.make +--- hotspot/make/bsd/makefiles/gcc.make.orig ++++ hotspot/make/bsd/makefiles/gcc.make +@@ -320,10 +320,8 @@ OPT_CFLAGS/NOOPT=-O0 + + # Work around some compiler bugs. + ifeq ($(USE_CLANG), true) +- ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 2), 1) +- OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT) +- OPT_CFLAGS/unsafe.o += -O1 +- endif ++ OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT) ++ OPT_CFLAGS/unsafe.o += -O1 + else + # 6835796. Problem in GCC 4.3.0 with mulnode.o optimized compilation. + ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 3), 1)