RFR: 8231955: ARM32: Address displacement is 0 for volatile field access because of Unsafe field access.
dean.long at oracle.com
dean.long at oracle.com
Fri Nov 1 08:05:27 UTC 2019
On 10/31/19 2:12 AM, christoph.goettschkes at microdoc.com wrote:
>> I see now that BarrierSetC1::resolve_address() is calling
>> generate_address(), at least when access isn't patched. So now I'm
>> thinking that the address passed to
>> volatile_field_load/volatile_field_store should be correct, and the call
>> to add_large_constant() isn't necessary.
> Yes, this is correct. The LIR_Address is created by
> LIRGenerator::generate_address and has a displacement of 0.
> I attached a backtrace of the failing assert at the end of this mail.
>
> Do you think the patch makes sense and can be pushed?
> The HotSpot tier1 JTreg tests are passing with this and other patches I am
> working on applied with a debug VM.
Yes, it looks fine now that I am reminded that arm32 is using
ldmia/stmia in volatile_move_op, which means the displacement must be 0.
dl
> -- Christoph
>
> #0 0x7636b860 in LIRGenerator::add_large_constant
> (this=0x641ae2f0, src=0xe500b, c=0, dest=0xe900b)
> at src/hotspot/cpu/arm/c1_LIRGenerator_arm.cpp:166
> #1 0x7636f266 in LIRGenerator::volatile_field_load
> (this=0x641ae2f0, address=0x6429c970, result=0xdd093, info=0x0)
> at src/hotspot/cpu/arm/c1_LIRGenerator_arm.cpp:1326
> #2 0x762d9806 in BarrierSetC1::load_at_resolved
> (this=0x7602b1f0, access=..., result=0xdd093)
> at src/hotspot/share/gc/shared/c1/barrierSetC1.cpp:183
> #3 0x762d929a in BarrierSetC1::load_at
> (this=0x7602b1f0, access=..., result=0xdd093)
> at src/hotspot/share/gc/shared/c1/barrierSetC1.cpp:94
> #4 0x7635f6cc in LIRGenerator::access_load_at
> (this=0x641ae2f0, decorators=9127331840, type=T_LONG, base=...,
> offset=0xd900b, result=0xdd093, patch_info=0x0, load_emit_info=0x0)
> at src/hotspot/share/c1/c1_LIRGenerator.cpp:1618
> #5 0x7636133e in LIRGenerator::do_UnsafeGetObject
> (this=0x641ae2f0, x=0x6429a0d0)
> at src/hotspot/share/c1/c1_LIRGenerator.cpp:2173
> #6 0x76328bdc in UnsafeGetObject::visit
> (this=0x6429a0d0, v=0x641ae2f0)
> at src/hotspot/share/c1/c1_Instruction.hpp:2407
> #7 0x7635b2d2 in LIRGenerator::do_root
> (this=0x641ae2f0, instr=0x6429a0d0)
> at src/hotspot/share/c1/c1_LIRGenerator.cpp:373
> #8 0x7635b1f2 in LIRGenerator::block_do
> (this=0x641ae2f0, block=0x64299788)
> at src/hotspot/share/c1/c1_LIRGenerator.cpp:354
> #9 0x76337d5a in BlockList::iterate_forward
> (this=0x6429bf00, closure=0x641ae2f4)
> at src/hotspot/share/c1/c1_Instruction.cpp:921
> #10 0x76332936 in IR::iterate_linear_scan_order
> (this=0x642994d0, closure=0x641ae2f4)
> at src/hotspot/share/c1/c1_IR.cpp:1221
> #11 0x7630ed10 in Compilation::emit_lir
> (this=0x641ae5c0)
> at src/hotspot/share/c1/c1_Compilation.cpp:259
> #12 0x7630f2be in Compilation::compile_java_method
> (this=0x641ae5c0)
> at src/hotspot/share/c1/c1_Compilation.cpp:398
> #13 0x7630f566 in Compilation::compile_method
> (this=0x641ae5c0)
> at src/hotspot/share/c1/c1_Compilation.cpp:460
> #14 0x7630fabc in Compilation::Compilation
> (this=0x641ae5c0, compiler=0x760eb610, env=0x641ae848,
> method=0x63d2edc8, osr_bci=-1, buffer_blob=0x73eb7448,
> directive=0x760cf858)
> at src/hotspot/share/c1/c1_Compilation.cpp:583
> #15 0x76312d6e in Compiler::compile_method
> (this=0x760eb610, env=0x641ae848, method=0x63d2edc8, entry_bci=-1,
> directive=0x760cf858)
> at src/hotspot/share/c1/c1_Compiler.cpp:247
> #16 0x76453704 in CompileBroker::invoke_compiler_on_method
> (task=0x642cfa50)
> at src/hotspot/share/compiler/compileBroker.cpp:2115
> #17 0x764529ba in CompileBroker::compiler_thread_loop
> ()
> at src/hotspot/share/compiler/compileBroker.cpp:1800
> #18 0x7693548c in compiler_thread_entry
> (thread=0x6423b400, __the_thread__=0x6423b400)
> at src/hotspot/share/runtime/thread.cpp:3401
> #19 0x769315d4 in JavaThread::thread_main_inner
> (this=0x6423b400)
> at src/hotspot/share/runtime/thread.cpp:1917
> #20 0x769314ac in JavaThread::run
> (this=0x6423b400)
> at src/hotspot/share/runtime/thread.cpp:1900
> #21 0x7692e884 in Thread::call_run
> (this=0x6423b400)
> at src/hotspot/share/runtime/thread.cpp:398
> #22 0x768285ce in thread_native_entry
> (thread=0x6423b400)
> at src/hotspot/os/linux/os_linux.cpp:790
> #23 0x76f84568 in start_thread() from target:/usr/lib/libpthread.so.0
> #24 0x76ef8ac8 in ?? () from target:/usr/lib/libc.so.6
>
More information about the hotspot-gc-dev
mailing list