Mercurial > hg > truffle
diff src/share/vm/gc_interface/collectedHeap.hpp @ 20804:7848fc12602b
Merge with jdk8u40-b25
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Tue, 07 Apr 2015 14:58:49 +0200 |
parents | 8f2fb6bec986 ef9eda2c1abe |
children |
line wrap: on
line diff
--- a/src/share/vm/gc_interface/collectedHeap.hpp Tue Apr 07 11:20:51 2015 +0200 +++ b/src/share/vm/gc_interface/collectedHeap.hpp Tue Apr 07 14:58:49 2015 +0200 @@ -351,6 +351,12 @@ fill_with_object(start, pointer_delta(end, start), zap); } + // Return the address "addr" aligned by "alignment_in_bytes" if such + // an address is below "end". Return NULL otherwise. + inline static HeapWord* align_allocation_or_fail(HeapWord* addr, + HeapWord* end, + unsigned short alignment_in_bytes); + // Some heaps may offer a contiguous region for shared non-blocking // allocation, via inlined code (by exporting the address of the top and // end fields defining the extent of the contiguous allocation region.) @@ -389,15 +395,6 @@ // allocation from them and necessitating allocation of new TLABs. virtual void ensure_parsability(bool retire_tlabs); - // Return an estimate of the maximum allocation that could be performed - // without triggering any collection or expansion activity. In a - // generational collector, for example, this is probably the largest - // allocation that could be supported (without expansion) in the youngest - // generation. It is "unsafe" because no locks are taken; the result - // should be treated as an approximation, not a guarantee, for use in - // heuristic resizing decisions. - virtual size_t unsafe_max_alloc() = 0; - // Section on thread-local allocation buffers (TLABs) // If the heap supports thread-local allocation buffers, it should override // the following methods: @@ -640,6 +637,18 @@ // actual number may be germane. static bool use_parallel_gc_threads() { return ParallelGCThreads > 0; } + // Copy the current allocation context statistics for the specified contexts. + // 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. + // Returns true if there are more stats available. + virtual bool copy_allocation_context_stats(const jint* contexts, + jlong* totals, + jbyte* accuracy, + jint len) { + return false; + } + /////////////// Unit tests /////////////// NOT_PRODUCT(static void test_is_in();)