comparison src/cpu/sparc/vm/stubGenerator_sparc.cpp @ 422:05db98ed59ba

6760773: UseCompressedOops is broken with UseParNewGC Summary: sparc code for gen_subtype_check was doing an ld for a compressed oop with the sign bit set so not comparing, leading to a ClassCastException. Reviewed-by: phh, never, acorn, kvn, xlu
author coleenp
date Fri, 07 Nov 2008 11:03:32 -0500
parents 1ee8caae33af
children 660978a2a31a
comparison
equal deleted inserted replaced
414:348be627a148 422:05db98ed59ba
954 __ add(L3,arrayOopDesc::base_offset_in_bytes(T_OBJECT),L1_ary_ptr); 954 __ add(L3,arrayOopDesc::base_offset_in_bytes(T_OBJECT),L1_ary_ptr);
955 __ clr(L3_index); // zero index 955 __ clr(L3_index); // zero index
956 // Load a little early; will load 1 off the end of the array. 956 // Load a little early; will load 1 off the end of the array.
957 // Ok for now; revisit if we have other uses of this routine. 957 // Ok for now; revisit if we have other uses of this routine.
958 if (UseCompressedOops) { 958 if (UseCompressedOops) {
959 __ ld(L1_ary_ptr,0,L2_super);// Will load a little early 959 __ lduw(L1_ary_ptr,0,L2_super);// Will load a little early
960 } else { 960 } else {
961 __ ld_ptr(L1_ary_ptr,0,L2_super);// Will load a little early 961 __ ld_ptr(L1_ary_ptr,0,L2_super);// Will load a little early
962 } 962 }
963 963
964 assert(heapOopSize != 0, "heapOopSize should be initialized"); 964 assert(heapOopSize != 0, "heapOopSize should be initialized");
971 971
972 if (UseCompressedOops) { 972 if (UseCompressedOops) {
973 #ifdef _LP64 973 #ifdef _LP64
974 __ subcc(L2_super,L4_ooptmp,Rret); // Check for match; zero in Rret for a hit 974 __ subcc(L2_super,L4_ooptmp,Rret); // Check for match; zero in Rret for a hit
975 __ br( Assembler::notEqual, false, Assembler::pt, loop ); 975 __ br( Assembler::notEqual, false, Assembler::pt, loop );
976 __ delayed()->ld(L1_ary_ptr,0,L2_super);// Will load a little early 976 __ delayed()->lduw(L1_ary_ptr,0,L2_super);// Will load a little early
977 #else 977 #else
978 ShouldNotReachHere(); 978 ShouldNotReachHere();
979 #endif 979 #endif
980 } else { 980 } else {
981 __ subcc(L2_super,Rsuper,Rret); // Check for match; zero in Rret for a hit 981 __ subcc(L2_super,Rsuper,Rret); // Check for match; zero in Rret for a hit