コード例 #1
0
ファイル: Array.java プロジェクト: OS2World/LIB-JAVA-OpenJDK
 public long getObjectSize() {
   ArrayKlass klass = (ArrayKlass) getKlass();
   // We have to fetch the length of the array, shift (multiply) it
   // appropriately, up to wordSize, add the header, and align to
   // object size.
   long s = getLength() << klass.getLog2ElementSize();
   s += klass.getArrayHeaderInBytes();
   s = Oop.alignObjectSize(s);
   return s;
 }