RFR: 8055838 Hotspot does not compile with clang 6.0 (OS X Yosemite)

Lois Foltan lois.foltan at oracle.com
Tue Aug 26 12:11:53 UTC 2014


Hi Staffan,
I think this looks good.  I added the knock down of unsafe.o for clang 
4.6.2.  See https://bugs.openjdk.java.net/browse/JDK-8022407 for the 
original test causing the issue.
Lois

On 8/26/2014 5:47 AM, Staffan Larsen wrote:
> There is a check in the makefiles to lower the optimization level for some files on some versions of clang . This check needs to take clang 6.0 into account (which is the default compiler on OS X Yosemite). The straightforward fix is below. I have verified this by running the hotspot/compiler tests. With the higher optimization level, a couple of tests fail in compiler/5091921. With the lower optimization level these tests pass. So it seems the fix is still needed for clang 6.0.
>
> bug: https://bugs.openjdk.java.net/browse/JDK-8055838
>
> Thanks,
> /Staffan
>
>
> diff -r 8e575cec7af9 make/bsd/makefiles/gcc.make
> --- a/make/bsd/makefiles/gcc.make	Tue Aug 19 11:17:44 2014 -0700
> +++ b/make/bsd/makefiles/gcc.make	Fri Aug 22 19:06:41 2014 +0200
> @@ -325,6 +325,10 @@
>     else ifeq ($(shell expr $(CC_VER_MAJOR) = 5 \& $(CC_VER_MINOR) = 1), 1)
>       OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT)
>       OPT_CFLAGS/unsafe.o += -O1
> + # Clang 6.0
> + else ifeq ($(shell expr $(CC_VER_MAJOR) = 6 \& $(CC_VER_MINOR) = 0), 1)
> + OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT)
> + OPT_CFLAGS/unsafe.o += -O1
>     else
>       $(error "Update compiler workarounds for Clang $(CC_VER_MAJOR).$(CC_VER_MINOR)")
>     endif



More information about the hotspot-runtime-dev mailing list