Request for reviews (M): 7145346: VerifyStackAtCalls is broken

Tom Rodriguez tom.rodriguez at oracle.com
Thu Feb 16 12:01:19 PST 2012


On Feb 16, 2012, at 11:47 AM, Vladimir Kozlov wrote:

> Tom Rodriguez wrote:
>> On Feb 16, 2012, at 11:04 AM, Vladimir Kozlov wrote:
>>> http://cr.openjdk.java.net/~kvn/7145346/webrev
>>> 
>>> 7145346: VerifyStackAtCalls is broken
>>> 
>>> A lot of duplicated code was removed.
>> Very nice.  In chaitin.cpp, regs_per_slot can be replaced with VMRegImpl::slots_per_word.
> 
> OK.
> 
>>> The failure was due to an incorrect branch distance was used in call_epilog(). Replace it's encoding with macroassembler use. Moved duplicated code to x86.ad.
>>> 
>>> After that fix I found an other problem - return_addr() definition in .ad files was not taking into account EBP save.
>> What kind of bug could that lead to?  Or does it just work out to be benign?
> 
> Incorrect return_pc passed to OptoRuntime::rethrow_C() with -XX:+VerifyStackAtCalls.

Ok.  Looks good.

tom

> 
> Thanks,
> Vladimir
> 
> #
> # A fatal error has been detected by the Java Runtime Environment:
> #
> #  Internal Error (/net/irkutsk.us.oracle.com/export/home/kvn/work2/hg/7145346/s
> rc/share/vm/runtime/sharedRuntime.cpp:501), pid=28761, tid=2
> #  assert(frame::verify_return_pc(return_address)) failed: must be a return addr
> ess: 0xffffffffbadb100d
> #
> # JRE version: 6.0_22-b03
> # Java VM: Java HotSpot(TM) 64-Bit Server VM (23.0-b15-internal-jvmg compiled mo
> de solaris-amd64 compressed oops)
> # Failed to write core dump. Core dumps have been disabled. To enable core dumpi
> ng, try "ulimit -c unlimited" before starting Java again
> #
> # If you would like to submit a bug report, please visit:
> #   http://bugreport.sun.com/bugreport/crash.jsp
> #
> 
> ---------------  T H R E A D  ---------------
> 
> Current thread (0x000000000042b000):  JavaThread "main" [_thread_in_Java, id=2,
> stack(0xfffffcfffef9f000,0xfffffcffff09f000)]
> 
> Stack: [0xfffffcfffef9f000,0xfffffcffff09f000],  sp=0xfffffcffff09d9c0,  free sp
> ace=1018k
> Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
> V  [libjvm.so+0x18e49a4]  void VMError::report(outputStream*)+0x1304
> V  [libjvm.so+0x18e61a0]  void VMError::report_and_die()+0x9b0
> V  [libjvm.so+0x10ead1a]  void report_vm_error(const char*,int,const char*,const
> char*)+0x9a
> V  [libjvm.so+0x1789fd7]  unsigned char*SharedRuntime::raw_exception_handler_for
> _return_address(JavaThread*,unsigned char*)+0x97
> V  [libjvm.so+0x1779ff3]  unsigned char*OptoRuntime::rethrow_C(oopDesc*,JavaThre
> ad*,unsigned char*)+0xf3
> 
> Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
> v  ~RuntimeStub::_rethrow_Java
> J  java.lang.ClassLoader.loadClass(Ljava/lang/String;Z)Ljava/lang/Class;
> J  sun.misc.Launcher$AppClassLoader.loadClass(Ljava/lang/String;Z)Ljava/lang/Cla
> ss;
> J  java.lang.ClassLoader.loadClass(Ljava/lang/String;)Ljava/lang/Class;
> v  ~StubRoutines::call_stub
> 
> 
>> tom
>>> Used in_preserve_stack_slots() value which is correctly defined. Also fixed frame dump for OptoAssembly output (in chaitin.cpp).
>>> 
>>> Thanks,
>>> Vladimir



More information about the hotspot-compiler-dev mailing list