diff options
author | Shivaram Venkataraman <shivaram@eecs.berkeley.edu> | 2012-08-11 02:34:20 -0700 |
---|---|---|
committer | Shivaram Venkataraman <shivaram@eecs.berkeley.edu> | 2012-08-13 13:31:21 -0700 |
commit | 80104ce1da3f761b68e686181320da65fb110807 (patch) | |
tree | 1eeaec78e9da67bdd8faecd6a890fd6a07252c66 /core | |
parent | 00ab5490b3cef7394504f9052a408f5b956ac64e (diff) | |
download | spark-80104ce1da3f761b68e686181320da65fb110807.tar.gz spark-80104ce1da3f761b68e686181320da65fb110807.tar.bz2 spark-80104ce1da3f761b68e686181320da65fb110807.zip |
Add link to Java wiki which specifies what changes with compressed oops
Diffstat (limited to 'core')
-rw-r--r-- | core/src/main/scala/spark/SizeEstimator.scala | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/src/main/scala/spark/SizeEstimator.scala b/core/src/main/scala/spark/SizeEstimator.scala index f196a6d818..3a63b236f3 100644 --- a/core/src/main/scala/spark/SizeEstimator.scala +++ b/core/src/main/scala/spark/SizeEstimator.scala @@ -37,6 +37,9 @@ object SizeEstimator { // TODO: Get this from jvm/system property val isCompressedOops = Runtime.getRuntime.maxMemory < (Integer.MAX_VALUE.toLong*2) + // Based on https://wikis.oracle.com/display/HotSpotInternals/CompressedOops + // section, "Which oops are compressed" + // Minimum size of a java.lang.Object val OBJECT_SIZE = if (!is64bit) 8 else { if(!isCompressedOops) { |