src/share/vm/classfile/classFileParser.cpp

changeset 2201
d55217dc206f
parent 2040
0e35fa8ebccd
child 2202
a932f331ef90
     1.1 --- a/src/share/vm/classfile/classFileParser.cpp	Fri Oct 08 02:42:17 2010 -0700
     1.2 +++ b/src/share/vm/classfile/classFileParser.cpp	Mon Oct 11 04:18:58 2010 -0700
     1.3 @@ -2702,13 +2702,15 @@
     1.4        // Adjust the field type from byte to an unmanaged pointer.
     1.5        assert(fac_ptr->nonstatic_byte_count > 0, "");
     1.6        fac_ptr->nonstatic_byte_count -= 1;
     1.7 -      (*fields_ptr)->ushort_at_put(i + instanceKlass::signature_index_offset,
     1.8 -                                   word_sig_index);
     1.9 -      fac_ptr->nonstatic_word_count += 1;
    1.10 +
    1.11 +      (*fields_ptr)->ushort_at_put(i + instanceKlass::signature_index_offset, word_sig_index);
    1.12 +      if (UseCompressedOops)  fac_ptr->nonstatic_double_count += 1;
    1.13 +      else                    fac_ptr->nonstatic_word_count   += 1;
    1.14  
    1.15        FieldAllocationType atype = (FieldAllocationType) (*fields_ptr)->ushort_at(i + instanceKlass::low_offset);
    1.16        assert(atype == NONSTATIC_BYTE, "");
    1.17 -      FieldAllocationType new_atype = NONSTATIC_WORD;
    1.18 +      FieldAllocationType new_atype = (wordSize == longSize) ? NONSTATIC_DOUBLE : NONSTATIC_WORD;
    1.19 +      assert(wordSize == longSize || wordSize == jintSize, "ILP32 or LP64");
    1.20        (*fields_ptr)->ushort_at_put(i + instanceKlass::low_offset, new_atype);
    1.21  
    1.22        found_vmentry = true;

mercurial