mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-17 01:24:33 +02:00
8256955: Move includes of events.hpp out of header files
Reviewed-by: kbarrett, coleenp
This commit is contained in:
parent
8b8b1f9a37
commit
3462f7a918
7 changed files with 31 additions and 27 deletions
|
@ -45,6 +45,7 @@
|
||||||
#include "utilities/growableArray.hpp"
|
#include "utilities/growableArray.hpp"
|
||||||
#include "utilities/macros.hpp"
|
#include "utilities/macros.hpp"
|
||||||
#include "utilities/ostream.hpp"
|
#include "utilities/ostream.hpp"
|
||||||
|
#include "utilities/vmError.hpp"
|
||||||
|
|
||||||
volatile size_t ClassLoaderDataGraph::_num_array_classes = 0;
|
volatile size_t ClassLoaderDataGraph::_num_array_classes = 0;
|
||||||
volatile size_t ClassLoaderDataGraph::_num_instance_classes = 0;
|
volatile size_t ClassLoaderDataGraph::_num_instance_classes = 0;
|
||||||
|
|
|
@ -52,17 +52,38 @@
|
||||||
#include "services/heapDumper.hpp"
|
#include "services/heapDumper.hpp"
|
||||||
#include "utilities/align.hpp"
|
#include "utilities/align.hpp"
|
||||||
#include "utilities/copy.hpp"
|
#include "utilities/copy.hpp"
|
||||||
|
#include "utilities/events.hpp"
|
||||||
|
|
||||||
class ClassLoaderData;
|
class ClassLoaderData;
|
||||||
|
|
||||||
size_t CollectedHeap::_filler_array_max_size = 0;
|
size_t CollectedHeap::_filler_array_max_size = 0;
|
||||||
|
|
||||||
|
class GCMessage : public FormatBuffer<1024> {
|
||||||
|
public:
|
||||||
|
bool is_before;
|
||||||
|
};
|
||||||
|
|
||||||
template <>
|
template <>
|
||||||
void EventLogBase<GCMessage>::print(outputStream* st, GCMessage& m) {
|
void EventLogBase<GCMessage>::print(outputStream* st, GCMessage& m) {
|
||||||
st->print_cr("GC heap %s", m.is_before ? "before" : "after");
|
st->print_cr("GC heap %s", m.is_before ? "before" : "after");
|
||||||
st->print_raw(m);
|
st->print_raw(m);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class GCHeapLog : public EventLogBase<GCMessage> {
|
||||||
|
private:
|
||||||
|
void log_heap(CollectedHeap* heap, bool before);
|
||||||
|
|
||||||
|
public:
|
||||||
|
GCHeapLog() : EventLogBase<GCMessage>("GC Heap History", "gc") {}
|
||||||
|
|
||||||
|
void log_heap_before(CollectedHeap* heap) {
|
||||||
|
log_heap(heap, true);
|
||||||
|
}
|
||||||
|
void log_heap_after(CollectedHeap* heap) {
|
||||||
|
log_heap(heap, false);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
void GCHeapLog::log_heap(CollectedHeap* heap, bool before) {
|
void GCHeapLog::log_heap(CollectedHeap* heap, bool before) {
|
||||||
if (!should_log()) {
|
if (!should_log()) {
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -36,7 +36,6 @@
|
||||||
#include "runtime/safepoint.hpp"
|
#include "runtime/safepoint.hpp"
|
||||||
#include "services/memoryUsage.hpp"
|
#include "services/memoryUsage.hpp"
|
||||||
#include "utilities/debug.hpp"
|
#include "utilities/debug.hpp"
|
||||||
#include "utilities/events.hpp"
|
|
||||||
#include "utilities/formatBuffer.hpp"
|
#include "utilities/formatBuffer.hpp"
|
||||||
#include "utilities/growableArray.hpp"
|
#include "utilities/growableArray.hpp"
|
||||||
|
|
||||||
|
@ -48,6 +47,7 @@
|
||||||
class AbstractGangTask;
|
class AbstractGangTask;
|
||||||
class AdaptiveSizePolicy;
|
class AdaptiveSizePolicy;
|
||||||
class BarrierSet;
|
class BarrierSet;
|
||||||
|
class GCHeapLog;
|
||||||
class GCHeapSummary;
|
class GCHeapSummary;
|
||||||
class GCTimer;
|
class GCTimer;
|
||||||
class GCTracer;
|
class GCTracer;
|
||||||
|
@ -62,31 +62,6 @@ class VirtualSpaceSummary;
|
||||||
class WorkGang;
|
class WorkGang;
|
||||||
class nmethod;
|
class nmethod;
|
||||||
|
|
||||||
class GCMessage : public FormatBuffer<1024> {
|
|
||||||
public:
|
|
||||||
bool is_before;
|
|
||||||
|
|
||||||
public:
|
|
||||||
GCMessage() {}
|
|
||||||
};
|
|
||||||
|
|
||||||
class CollectedHeap;
|
|
||||||
|
|
||||||
class GCHeapLog : public EventLogBase<GCMessage> {
|
|
||||||
private:
|
|
||||||
void log_heap(CollectedHeap* heap, bool before);
|
|
||||||
|
|
||||||
public:
|
|
||||||
GCHeapLog() : EventLogBase<GCMessage>("GC Heap History", "gc") {}
|
|
||||||
|
|
||||||
void log_heap_before(CollectedHeap* heap) {
|
|
||||||
log_heap(heap, true);
|
|
||||||
}
|
|
||||||
void log_heap_after(CollectedHeap* heap) {
|
|
||||||
log_heap(heap, false);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
class ParallelObjectIterator : public CHeapObj<mtGC> {
|
class ParallelObjectIterator : public CHeapObj<mtGC> {
|
||||||
public:
|
public:
|
||||||
virtual void object_iterate(ObjectClosure* cl, uint worker_id) = 0;
|
virtual void object_iterate(ObjectClosure* cl, uint worker_id) = 0;
|
||||||
|
|
|
@ -85,6 +85,7 @@
|
||||||
#include "runtime/vmThread.hpp"
|
#include "runtime/vmThread.hpp"
|
||||||
#include "services/mallocTracker.hpp"
|
#include "services/mallocTracker.hpp"
|
||||||
#include "services/memTracker.hpp"
|
#include "services/memTracker.hpp"
|
||||||
|
#include "utilities/events.hpp"
|
||||||
#include "utilities/powerOfTwo.hpp"
|
#include "utilities/powerOfTwo.hpp"
|
||||||
|
|
||||||
class ShenandoahPretouchHeapTask : public AbstractGangTask {
|
class ShenandoahPretouchHeapTask : public AbstractGangTask {
|
||||||
|
|
|
@ -33,6 +33,7 @@
|
||||||
#include "memory/resourceArea.hpp"
|
#include "memory/resourceArea.hpp"
|
||||||
#include "memory/universe.hpp"
|
#include "memory/universe.hpp"
|
||||||
#include "runtime/arguments.hpp"
|
#include "runtime/arguments.hpp"
|
||||||
|
#include "utilities/events.hpp"
|
||||||
|
|
||||||
JVMCIRuntime* JVMCI::_compiler_runtime = NULL;
|
JVMCIRuntime* JVMCI::_compiler_runtime = NULL;
|
||||||
JVMCIRuntime* JVMCI::_java_runtime = NULL;
|
JVMCIRuntime* JVMCI::_java_runtime = NULL;
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
|
|
||||||
#include "compiler/compiler_globals.hpp"
|
#include "compiler/compiler_globals.hpp"
|
||||||
#include "compiler/compilerDefinitions.hpp"
|
#include "compiler/compilerDefinitions.hpp"
|
||||||
#include "utilities/events.hpp"
|
|
||||||
#include "utilities/exceptions.hpp"
|
#include "utilities/exceptions.hpp"
|
||||||
|
|
||||||
class BoolObjectClosure;
|
class BoolObjectClosure;
|
||||||
|
@ -39,6 +38,11 @@ class MetadataHandleBlock;
|
||||||
class OopClosure;
|
class OopClosure;
|
||||||
class OopStorage;
|
class OopStorage;
|
||||||
|
|
||||||
|
template <size_t>
|
||||||
|
class FormatStringEventLog;
|
||||||
|
|
||||||
|
typedef FormatStringEventLog<256> StringEventLog;
|
||||||
|
|
||||||
struct _jmetadata;
|
struct _jmetadata;
|
||||||
typedef struct _jmetadata *jmetadata;
|
typedef struct _jmetadata *jmetadata;
|
||||||
|
|
||||||
|
|
|
@ -103,6 +103,7 @@
|
||||||
#include "utilities/globalDefinitions.hpp"
|
#include "utilities/globalDefinitions.hpp"
|
||||||
#include "utilities/hashtable.hpp"
|
#include "utilities/hashtable.hpp"
|
||||||
#include "utilities/macros.hpp"
|
#include "utilities/macros.hpp"
|
||||||
|
#include "utilities/vmError.hpp"
|
||||||
|
|
||||||
#include CPU_HEADER(vmStructs)
|
#include CPU_HEADER(vmStructs)
|
||||||
#include OS_HEADER(vmStructs)
|
#include OS_HEADER(vmStructs)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue