8061234: ResourceContext.requestAccurateUpdate() is unreliable

Changing copy_allocation_context_stats to return if there are more stats available after the copy.

Reviewed-by: rriggs, jcoomes
This commit is contained in:
Stefan Johansson 2014-10-30 10:51:06 +01:00
parent 76db8ade45
commit 6306dce831
3 changed files with 8 additions and 4 deletions

View file

@ -644,10 +644,13 @@ class CollectedHeap : public CHeapObj<mtInternal> {
// For each context in contexts, set the corresponding entries in the totals
// and accuracy arrays to the current values held by the statistics. Each
// array should be of length len.
virtual void copy_allocation_context_stats(const jint* contexts,
// Returns true if there are more stats available.
virtual bool copy_allocation_context_stats(const jint* contexts,
jlong* totals,
jbyte* accuracy,
jint len) { }
jint len) {
return false;
}
/////////////// Unit tests ///////////////