# HG changeset patch # User Thomas Wuerthinger # Date 1305108641 -7200 # Node ID 3e47aeb60ab32c5cb7fc77ed180e787a4d58f17d # Parent 152d4a8dc7adc5bfc1f91bc048938a1f4e4e94d4 Deopt instead of throwing exception for checkcast. diff -r 152d4a8dc7ad -r 3e47aeb60ab3 graal/GraalRuntime/src/com/oracle/graal/runtime/HotSpotXirGenerator.java --- a/graal/GraalRuntime/src/com/oracle/graal/runtime/HotSpotXirGenerator.java Wed May 11 11:57:11 2011 +0200 +++ b/graal/GraalRuntime/src/com/oracle/graal/runtime/HotSpotXirGenerator.java Wed May 11 12:10:41 2011 +0200 @@ -710,7 +710,8 @@ asm.jneq(end, objHub, asm.o(null)); XirOperand scratch = asm.createRegisterTemp("scratch", CiKind.Object, AMD64.r10); asm.mov(scratch, object); - asm.callRuntime(config.throwClassCastException, null); + + asm.callRuntime(CiRuntimeCall.Deoptimize, null); asm.shouldNotReachHere(); if (is(UNRESOLVED, flags)) {