20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_UTILITIES_HISTOGRAM_HPP
26 #define SHARE_VM_UTILITIES_HISTOGRAM_HPP
27
28 #include "memory/allocation.hpp"
29 #include "runtime/os.hpp"
30 #include "utilities/growableArray.hpp"
31 #ifdef TARGET_OS_FAMILY_linux
32 # include "os_linux.inline.hpp"
33 #endif
34 #ifdef TARGET_OS_FAMILY_solaris
35 # include "os_solaris.inline.hpp"
36 #endif
37 #ifdef TARGET_OS_FAMILY_windows
38 # include "os_windows.inline.hpp"
39 #endif
40
41 // This class provides a framework for collecting various statistics.
42 // The current implementation is oriented towards counting invocations
43 // of various types, but that can be easily changed.
44 //
45 // To use it, you need to declare a Histogram*, and a subtype of
46 // HistogramElement:
47 //
48 // HistogramElement* MyHistogram;
49 //
50 // class MyHistogramElement : public HistogramElement {
51 // public:
52 // MyHistogramElement(char* name);
53 // };
54 //
55 // MyHistogramElement::MyHistogramElement(char* elementName) {
56 // _name = elementName;
57 //
58 // if(MyHistogram == NULL)
59 // MyHistogram = new Histogram("My Call Counts",100);
|
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_UTILITIES_HISTOGRAM_HPP
26 #define SHARE_VM_UTILITIES_HISTOGRAM_HPP
27
28 #include "memory/allocation.hpp"
29 #include "runtime/os.hpp"
30 #include "utilities/growableArray.hpp"
31 #ifdef TARGET_OS_FAMILY_linux
32 # include "os_linux.inline.hpp"
33 #endif
34 #ifdef TARGET_OS_FAMILY_solaris
35 # include "os_solaris.inline.hpp"
36 #endif
37 #ifdef TARGET_OS_FAMILY_windows
38 # include "os_windows.inline.hpp"
39 #endif
40 #ifdef TARGET_OS_FAMILY_bsd
41 # include "os_bsd.inline.hpp"
42 #endif
43
44 // This class provides a framework for collecting various statistics.
45 // The current implementation is oriented towards counting invocations
46 // of various types, but that can be easily changed.
47 //
48 // To use it, you need to declare a Histogram*, and a subtype of
49 // HistogramElement:
50 //
51 // HistogramElement* MyHistogram;
52 //
53 // class MyHistogramElement : public HistogramElement {
54 // public:
55 // MyHistogramElement(char* name);
56 // };
57 //
58 // MyHistogramElement::MyHistogramElement(char* elementName) {
59 // _name = elementName;
60 //
61 // if(MyHistogram == NULL)
62 // MyHistogram = new Histogram("My Call Counts",100);
|