Building with GCC 6

Andrew Haley aph at redhat.com
Tue Feb 16 14:40:54 UTC 2016


GCC Version 6 doesn't build a working HotSpot without two flags:

  -fno-delete-null-pointer-checks
  -fno-lifetime-dse

These are because HotSpot uses undefined behaviour in some places.

"-fno-delete-null-pointer-checks" is needed because HotSpot
dereferences null pointers in soe places.

"-fno-lifetime-dse" refers to the practice of initializing objects
before the start of a constructor, which is explicitly forbidden by
Standard C++, but is used by HotSpot.

GCC 6 is quite new, so we have a little time before the various users
of OpenJDK start to hit these problems, but I'd like to help get some
build fixes in as soon as we can.  Also, it's not just about JDK9: 8u
fails to build too.

Thanks,

Andrew.



More information about the build-dev mailing list