[riscv-port-jdk11u:riscv-port] RFR: 8290496: riscv: Fix build warnings-as-errors with GCC 11
kuaiwei
duke at openjdk.org
Mon May 13 02:26:41 UTC 2024
On Sun, 3 Mar 2024 06:40:16 GMT, Gui Cao <gcao at openjdk.org> wrote:
> Hi, Please review this backport to riscv-port-jdk17u.
> Backport of [JDK-8290496](https://bugs.openjdk.java.net/browse/JDK-8290496). Applies cleanly.
> build config:
>
> bash configure --with-debug-level=release --with-jvm-variants=minimal --with-zlib=system --with-native-debug-symbols=internal --with-boot-jdk=/home/zifeihan/jre/jre11 --with-extra-cxxflags=-Wno-maybe-uninitialized --with-extra-cflags=-Wno-maybe-uninitialized
>
>
> Before this backport:
>
>
> ERROR: Build failed for target 'default (exploded-image)' in configuration 'linux-riscv64-normal-minimal-release' (exit code 2)
> Stopping sjavac server
>
> === Output from failing command(s) repeated here ===
> * For target hotspot_variant-minimal_libjvm_objs_c1_LIRAssembler.o:
> In file included from /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/c1/c1_LIRAssembler.hpp:28,
> from /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/c1/c1_LIRAssembler.cpp:30:
> In member function 'void PatchingStub::install(MacroAssembler*, LIR_PatchCode, Register, CodeEmitInfo*)',
> inlined from 'void LIR_Assembler::patching_epilog(PatchingStub*, LIR_PatchCode, Register, CodeEmitInfo*)' at /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/c1/c1_LIRAssembler.cpp:45:17:
> /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/c1/c1_CodeStubs.hpp:423:25: error: 'this' pointer is null [-Werror=nonnull]
> 423 | n_move->set_offset(field_offset);
> | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
> In file included from /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/code/nativeInst.hpp:30,
> from /home/zifeihan/riscv-port-jdk11u/src/hotspot/share/precompiled/precompiled.hpp:77:
> /home/zifeihan/riscv-port-jdk11u/src/hotspot/cpu/riscv/nativeInst_riscv.hpp: In member function 'void LIR_Assembler::patching_epilog(PatchingStub*, LIR_PatchCode, Register, CodeEmitInfo*)':
> /home/zifeihan/riscv-port-jdk11u/src/hotspot/cpu/riscv/nativeInst_riscv.hpp:419:8: note: in a call to non-static member function 'void NativeMovRegMem::set_offset(int)'
> 419 | void set_offset(int x);
> | ^~~~~~~~~~
> cc1plus: all warnings being treated as errors
>
> * All command lines available in /home/zifeihan/riscv-port-jdk11u/build/linux-riscv64-normal-minimal-release/make-support/failure-logs.
> === End of repeated output ===
>
> No indication of failed target found.
> Hint: Try searching the build log for '] Error'.
> Hint: See doc/building.html#troubleshooting for assistance.
>
> make[1]: *** [/home/zifeihan/riscv-port-jdk11u/make/Init.gmk:308: main] E...
LGTM
-------------
PR Review: https://git.openjdk.org/riscv-port-jdk11u/pull/7#pullrequestreview-2051579357
More information about the riscv-port-dev
mailing list