I'm seeing this patch fail across all platforms on internal builds. Please hold off any push for now. Maybe other config changes are needed on our build systems.

e.g.

/opt/jprt/products/P1/SS12u1/SS12u1/prod/bin/CC                                 
   \
                     -m64 -G -KPIC     \
                   
-I/opt/jprt/T/P1/094712.scoffey/s/hotspot/agent/src/os/solaris/proc             
                           \
                   -I../generated                                       \
                   -I/opt/jprt/products/P1/jdk7u7-latest/jdk1.7.0_07/include    
                      \
                   
-I/opt/jprt/products/P1/jdk7u7-latest/jdk1.7.0_07/include/solaris    \
                                             \
                   
/opt/jprt/T/P1/094712.scoffey/s/hotspot/agent/src/os/solaris/proc/saproc.cpp    
                                    \
                   sadis.o                                          \
                   -M 
/opt/jprt/T/P1/094712.scoffey/s/hotspot/agent/src/os/solaris/proc/mapfile -mt 
-xnolib -norunpath                                         \
                   -o libsaproc.so                                              
  \
                   -ldl -ldemangle -lthread -lc
ld: fatal: file @NO_DELETE_NULL_POINTER_CHECKS_CFLAG@: open failed: No such 
file or directory
ld: fatal: file @NO_LIFETIME_DSE_CFLAG@: open failed: No such file or directory
ld: fatal: file @CXXSTD_CXXFLAG@: open failed: No such file or directory
ld: fatal: file processing errors. No output written to libgenerateJvmOffsets.so
gmake[6]: *** [libgenerateJvmOffsets.so] Error 1
gmake[6]: *** Waiting for unfinished jobs....
gmake[6]: Leaving directory 
`/opt/jprt/T/P1/094712.scoffey/s/build/solaris-x86_64-normal-server-release/hotspot/solaris_amd64_compiler2/product'
gmake[5]: *** [the_vm] Error 2

Regards,
Sean.

On 01/08/2016 12:34, Erik Joelsson wrote:
Looks good now, thanks!

Sorry for not answering earlier. I just got back from vacation.

/Erik

On 2016-07-15 17:22, Andrew Hughes wrote:
Ping?

----- Original Message -----
----- Original Message -----
Hello,

It looks like TOOLCHAIN_CXX_COMPILER_CHECK_ARGUMENTS is always returning
yes and TOOLCHAIN_C_COMPILER_CHECK_ARGUMENTS still does both the C and
C++ checks.

Ugh, merged a block in the wrong place by the looks of it.

Fixed in http://cr.openjdk.java.net/~andrew/8u/8151841/webrev.02/

configure:29739: checking if the C++ compiler supports "-std=gnu++98 "
configure:29755: /usr/bin/g++ -c  -std=gnu++98   conftest.cpp >&5
configure:29755: $? = 0
configure:29769: result: yes
configure:29815: checking if the C compiler supports
"-fno-delete-null-pointer-checks -Werror"
configure:29832: /usr/bin/gcc -c -fno-delete-null-pointer-checks -Werror
conftest.c >&5
configure:29832: $? = 0
configure:29846: result: yes
configure:29855: checking if the C++ compiler supports
"-fno-delete-null-pointer-checks -Werror"
configure:29871: /usr/bin/g++ -c -fno-delete-null-pointer-checks -Werror
conftest.cpp >&5
configure:29871: $? = 0
configure:29885: result: yes
configure:29894: checking if both compilers support
"-fno-delete-null-pointer-checks -Werror"
configure:29899: result: yes
configure:29911: checking if the C compiler supports "-fno-lifetime-dse
-Werror"
configure:29927: /usr/bin/gcc -c -fno-lifetime-dse -Werror conftest.c >&5
configure:29927: $? = 0
configure:29941: result: yes
configure:29950: checking if the C++ compiler supports "-fno-lifetime-dse
-Werror"
configure:29966: /usr/bin/g++ -c -fno-lifetime-dse -Werror conftest.cpp >&5
configure:29966: $? = 0
configure:29980: result: yes
configure:29989: checking if both compilers support "-fno-lifetime-dse
-Werror"
configure:29994: result: yes


/Erik

On 2016-07-07 22:21, Andrew Hughes wrote:
Webrev: http://cr.openjdk.java.net/~andrew/8u/8151841/webrev.01/
Bug: https://bugs.openjdk.java.net/browse/JDK-8151841

This is a backport of the original fix to support building OpenJDK
with GCC 6. It was necessary to cherry-pick parts of a number of
earlier fixes to make this work with the build system in 8:

8149647: Incremental enhancements from build-infra
8032045: Enable compiler and linker safety switches for debug builds

and so I'm requesting a review of the 8 version of the patch here as well
as approval for 8u.

In brief, the patch makes OpenJDK build with GCC 6 by explicitly
specifying
the C++ standard to use (-std=gnu++98) and disabling two optimisations
with
-fno-lifetime-dse and -fno-delete-null-pointer-checks. Further
information
on the changes is available in the GCC 6 release notes [0]. GCC 6 uses a newer C++ standard, C++14, with which the OpenJDK codebase is not yet
compliant. The simplest way to fix this, especially for existing
releases,
is to explicitly request the previous default, gnu++98. The deletion
of null pointer checks and more aggressive lifetime dead store
elimination
in 6 lead to a crashing virtual machine being built, so we disable them
if GCC >= 6 is used.

To make the original patch work with 8u, a number of changes from other
fixes had to also be brought over:

* We need to check we are using GCC 6 or above, so we need to bring
over the TOOLCHAIN_CHECK_COMPILER_VERSION and
TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS macros from 8149647.
TOOLCHAIN_CHECK_COMPILER_VERSION is converted back to a traditional
numbered rather than named argument macro so we don't need to backport
BASIC_DEFUN_NAMED.
* We bring over the introduction of COMMON_CCXXFLAGS_JDK from 8030245
as we need to apply the -std option only to the C++ compiler, not the
C compiler. If passed to the C compiler, it will produce a warning,
and this is converted to an error at one point in the build
(a -Werror in libsctp).

Generally, we've kept things in toolchain.m4 (8034788 introduced
flags.m4,
separating out some code, and so many of these changes are in that file
in 9) and avoid named argument macros. Otherwise, it's largely the
same as the 9 version. We have adopted the longer name for
the -fno-delete-null-pointer-checks flag variable as suggested in the
review of the update to this patch for the new HotSpot build [1].

[0] https://gcc.gnu.org/gcc-6/porting_to.html
[1]
http://mail.openjdk.java.net/pipermail/hotspot-dev/2016-July/023840.html

--
Andrew :)

Senior Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

PGP Key: ed25519/35964222 (hkp://keys.gnupg.net)
Fingerprint = 5132 579D D154 0ED2 3E04  C5A0 CFDA 0F9B 3596 4222





Reply via email to