Mercurial > hg > graal-compiler
comparison src/share/vm/code/stubs.hpp @ 6197:d2a62e0f25eb
6995781: Native Memory Tracking (Phase 1)
7151532: DCmd for hotspot native memory tracking
Summary: Implementation of native memory tracking phase 1, which tracks VM native memory usage, and related DCmd
Reviewed-by: acorn, coleenp, fparain
author | zgu |
---|---|
date | Thu, 28 Jun 2012 17:03:16 -0400 |
parents | f08d439fab8c |
children | b31471cdc53e 8c5333c80cfd |
comparison
equal
deleted
inserted
replaced
6174:74533f63b116 | 6197:d2a62e0f25eb |
---|---|
99 // stub interface implementation is a subclass of StubInterface, | 99 // stub interface implementation is a subclass of StubInterface, |
100 // forwarding its virtual function calls to non-virtual calls | 100 // forwarding its virtual function calls to non-virtual calls |
101 // of the concrete stub (see also macro below). There's exactly | 101 // of the concrete stub (see also macro below). There's exactly |
102 // one stub interface instance required per stub queue. | 102 // one stub interface instance required per stub queue. |
103 | 103 |
104 class StubInterface: public CHeapObj { | 104 class StubInterface: public CHeapObj<mtCode> { |
105 public: | 105 public: |
106 // Initialization/finalization | 106 // Initialization/finalization |
107 virtual void initialize(Stub* self, int size) = 0; // called after creation (called twice if allocated via (request, commit)) | 107 virtual void initialize(Stub* self, int size) = 0; // called after creation (called twice if allocated via (request, commit)) |
108 virtual void finalize(Stub* self) = 0; // called before deallocation | 108 virtual void finalize(Stub* self) = 0; // called before deallocation |
109 | 109 |
150 | 150 |
151 | 151 |
152 // A StubQueue maintains a queue of stubs. | 152 // A StubQueue maintains a queue of stubs. |
153 // Note: All sizes (spaces) are given in bytes. | 153 // Note: All sizes (spaces) are given in bytes. |
154 | 154 |
155 class StubQueue: public CHeapObj { | 155 class StubQueue: public CHeapObj<mtCode> { |
156 friend class VMStructs; | 156 friend class VMStructs; |
157 private: | 157 private: |
158 StubInterface* _stub_interface; // the interface prototype | 158 StubInterface* _stub_interface; // the interface prototype |
159 address _stub_buffer; // where all stubs are stored | 159 address _stub_buffer; // where all stubs are stored |
160 int _buffer_size; // the buffer size in bytes | 160 int _buffer_size; // the buffer size in bytes |