--- old/src/share/vm/memory/metaspace.cpp 2014-06-12 03:58:36.000000000 -0400 +++ new/src/share/vm/memory/metaspace.cpp 2014-06-12 03:58:36.000000000 -0400 @@ -1460,7 +1460,7 @@ (size_t)MIN2(min_tmp, double(max_uintx)); // Don't shrink less than the initial generation size minimum_desired_capacity = MAX2(minimum_desired_capacity, - MetaspaceSize); + (size_t)MetaspaceSize); if (PrintGCDetails && Verbose) { gclog_or_tty->print_cr("\nMetaspaceGC::compute_new_size: "); @@ -1516,7 +1516,7 @@ const double max_tmp = used_after_gc / minimum_used_percentage; size_t maximum_desired_capacity = (size_t)MIN2(max_tmp, double(max_uintx)); maximum_desired_capacity = MAX2(maximum_desired_capacity, - MetaspaceSize); + (size_t)MetaspaceSize); if (PrintGCDetails && Verbose) { gclog_or_tty->print_cr(" " " maximum_free_percentage: %6.2f" @@ -3179,7 +3179,7 @@ // Make the first class chunk bigger than a medium chunk so it's not put // on the medium chunk list. The next chunk will be small and progress // from there. This size calculated by -version. - _first_class_chunk_word_size = MIN2((size_t)MediumChunk*6, + _first_class_chunk_word_size = MIN2((uintx)MediumChunk*6, (CompressedClassSpaceSize/BytesPerWord)*2); _first_class_chunk_word_size = align_word_size_up(_first_class_chunk_word_size); // Arbitrarily set the initial virtual space to a multiple