changeset 3727:94e9408dbf50

8000753: compiler/6912517 crashes on 64bit sparc with compressed oops off Summary: code generated by c1 for getClass intrinsic broken when klass field is loaded on 64bit with compressed klass off. Reviewed-by: kvn
author roland
date Thu, 11 Oct 2012 18:21:01 +0200
parents d336b3173277
children 19eb999cb72c
files src/cpu/sparc/vm/c1_LIRAssembler_sparc.cpp
diffstat 1 files changed, 5 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/src/cpu/sparc/vm/c1_LIRAssembler_sparc.cpp	Tue Oct 09 16:09:31 2012 -0700
+++ b/src/cpu/sparc/vm/c1_LIRAssembler_sparc.cpp	Thu Oct 11 18:21:01 2012 +0200
@@ -976,14 +976,13 @@
         break;
       case T_METADATA:  __ ld_ptr(base, offset, to_reg->as_register()); break;
       case T_ADDRESS:
-        if (offset == oopDesc::klass_offset_in_bytes()) {
+#ifdef _LP64
+        if (offset == oopDesc::klass_offset_in_bytes() && UseCompressedKlassPointers) {
           __ lduw(base, offset, to_reg->as_register());
-#ifdef _LP64
-          if (UseCompressedKlassPointers) {
-            __ decode_klass_not_null(to_reg->as_register());
-          }
+          __ decode_klass_not_null(to_reg->as_register());
+        } else
 #endif
-        } else {
+        {
           __ ld_ptr(base, offset, to_reg->as_register());
         }
         break;