Integrated: 8265431: Add -fno-delete-null-pointer-checks to clang builds

Maxim Kartashev github.com+28651297+mkartashev at openjdk.java.net
Tue Jun 1 18:00:25 UTC 2021


On Mon, 24 May 2021 14:03:45 GMT, Maxim Kartashev <github.com+28651297+mkartashev at openjdk.org> wrote:

> This commit adds the `-fno-delete-null-pointer-checks` compiler option to clang builds, which is going to become necessary starting from clang version 12.0.0 (see the [bug report](https://bugs.openjdk.java.net/browse/JDK-8265431) for more info).
> 
> Verified on Linux (with both gcc and clang toolchains) and MacOS (with only the clang toolchain) by
> - Running configure with `--with-toolchain-type=clang`; the following appears in the configure output:
> 
> ...
> checking if BUILD_CC supports "-fno-delete-null-pointer-checks"... yes
> checking if BUILD_CXX supports "-fno-delete-null-pointer-checks"... yes
> checking if both BUILD_CC and BUILD_CXX support "-fno-delete-null-pointer-checks"... yes
> ...
> * Toolchain:      clang (clang/LLVM)
> * C Compiler:     Version 10.0.0 (at /usr/bin/clang)
> * C++ Compiler:   Version 10.0.0 (at /usr/bin/clang++)
> 
> - Successfully building `make images`. The option is actually passed down to the compiler:
> 
> $ grep fno-delete-null-pointer-checks .../jdk/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/*cmdline | wc -l 
> 1069
> 
> -  Running `make run-test-tier1` on Linux.

This pull request has now been integrated.

Changeset: 64ba2f0e
Author:    Maxim Kartashev <maxim.kartashev at jetbrains.com>
Committer: Erik Joelsson <erikj at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/64ba2f0e8f38a92edf8a301f43b3a0d4e239e1b2
Stats:     9 lines in 1 file changed: 9 ins; 0 del; 0 mod

8265431: Add -fno-delete-null-pointer-checks to clang builds

Reviewed-by: erikj

-------------

PR: https://git.openjdk.java.net/jdk/pull/4166



More information about the build-dev mailing list