-
Sub-task
-
Resolution: Duplicate
-
P3
-
9
I encountered 2 compiler warnings and 2 VM crashes with GCC 6:
* Compiler warnings:
-----------
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp: In static member function 'static Address Address::make_raw(int, int, int, int, relocInfo::relocType)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +32)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
return madr;
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +24)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +16)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
cc1plus: all warnings being treated as errors
-----------
Error #3: uninitialized value at interp_masm_x86.cpp
```
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::increment_mdp_data_at(Register, int, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::increment_mdp_data_at(Register, Register, int, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, reg, Address::times_1, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_called_method(Register, Register, Register)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_virtual_call(Register, Register, Register, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_ret(Register, Register)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
cc1plus: all warnings being treated as errors
-----------
* VM crash
- hs_err_pid45139.log and replay_pid45139.log
- hs_err_pid58985.log and replay_pid58985.log
* Compiler warnings:
-----------
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp: In static member function 'static Address Address::make_raw(int, int, int, int, relocInfo::relocType)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +32)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
return madr;
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +24)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/assembler_x86.cpp:203:12: error: '*((void*)& rspec +16)' may be used uninitialized in this function [-Werror=maybe-uninitialized]
cc1plus: all warnings being treated as errors
-----------
Error #3: uninitialized value at interp_masm_x86.cpp
```
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::increment_mdp_data_at(Register, int, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::increment_mdp_data_at(Register, Register, int, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, reg, Address::times_1, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1388:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_called_method(Register, Register, Register)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
Address data(mdp_in, constant);
^~~~
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_virtual_call(Register, Register, Register, bool)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp: In member function 'void InterpreterMacroAssembler::profile_ret(Register, Register)':
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[2]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[3]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
/home/ysuenaga/OpenJDK/hs/hotspot/src/cpu/x86/vm/interp_masm_x86.cpp:1354:11: error: 'data.Address::_rspec.RelocationHolder::_relocbuf[4]' may be used uninitialized in this function [-Werror=maybe-uninitialized]
cc1plus: all warnings being treated as errors
-----------
* VM crash
- hs_err_pid45139.log and replay_pid45139.log
- hs_err_pid58985.log and replay_pid58985.log
- duplicates
-
JDK-8160404 RelocationHolder constructors have bugs
- Resolved
- relates to
-
JDK-8160404 RelocationHolder constructors have bugs
- Resolved