Mercurial > hg > truffle
diff src/share/vm/services/management.cpp @ 489:2494ab195856
6653214: MemoryPoolMXBean.setUsageThreshold() does not support large heap sizes.
Reviewed-by: ysr, mchung
author | swamyv |
---|---|
date | Mon, 15 Dec 2008 13:58:57 -0800 |
parents | d28aa69f0959 |
children | 0fbdb4381b99 |
line wrap: on
line diff
--- a/src/share/vm/services/management.cpp Fri Dec 12 19:55:26 2008 -0800 +++ b/src/share/vm/services/management.cpp Mon Dec 15 13:58:57 2008 -0800 @@ -694,10 +694,10 @@ -1); } - if (threshold > max_intx) { - THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(), - "Invalid threshold value > max value of size_t", - -1); + if ((size_t)threshold > max_uintx) { + stringStream st; + st.print("Invalid valid threshold value. Threshold value (" UINT64_FORMAT ") > max value of size_t (" SIZE_FORMAT ")", (size_t)threshold, max_uintx); + THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(), st.as_string(), -1); } MemoryPool* pool = get_memory_pool_from_jobject(obj, CHECK_(0L));