< prev index next >

src/hotspot/share/gc/shared/gcName.hpp

Print this page

22  *
23  */
24 
25 #ifndef SHARE_GC_SHARED_GCNAME_HPP
26 #define SHARE_GC_SHARED_GCNAME_HPP
27 
28 #include "utilities/debug.hpp"
29 
30 enum GCName {
31   ParallelOld,
32   SerialOld,
33   ParallelScavenge,
34   DefNew,
35   G1New,
36   G1Old,
37   G1Full,
38   ZMinor,
39   ZMajor,
40   Z, // Support for the legacy, single-gen mode
41   Shenandoah,


42   NA,
43   GCNameEndSentinel
44 };
45 
46 class GCNameHelper {
47  public:
48   static const char* to_string(GCName name) {
49     switch(name) {
50       case ParallelOld: return "ParallelOld";
51       case SerialOld: return "SerialOld";
52       case ParallelScavenge: return "ParallelScavenge";
53       case DefNew: return "DefNew";
54       case G1New: return "G1New";
55       case G1Old: return "G1Old";
56       case G1Full: return "G1Full";
57       case ZMinor: return "ZGC Minor";
58       case ZMajor: return "ZGC Major";
59       case Z: return "Z";
60       case Shenandoah: return "Shenandoah";


61       case NA: return "N/A";
62       default: ShouldNotReachHere(); return nullptr;
63     }
64   }
65 };
66 
67 #endif // SHARE_GC_SHARED_GCNAME_HPP

22  *
23  */
24 
25 #ifndef SHARE_GC_SHARED_GCNAME_HPP
26 #define SHARE_GC_SHARED_GCNAME_HPP
27 
28 #include "utilities/debug.hpp"
29 
30 enum GCName {
31   ParallelOld,
32   SerialOld,
33   ParallelScavenge,
34   DefNew,
35   G1New,
36   G1Old,
37   G1Full,
38   ZMinor,
39   ZMajor,
40   Z, // Support for the legacy, single-gen mode
41   Shenandoah,
42   ShenandoahYoung,
43   ShenandoahOld,
44   NA,
45   GCNameEndSentinel
46 };
47 
48 class GCNameHelper {
49  public:
50   static const char* to_string(GCName name) {
51     switch(name) {
52       case ParallelOld: return "ParallelOld";
53       case SerialOld: return "SerialOld";
54       case ParallelScavenge: return "ParallelScavenge";
55       case DefNew: return "DefNew";
56       case G1New: return "G1New";
57       case G1Old: return "G1Old";
58       case G1Full: return "G1Full";
59       case ZMinor: return "ZGC Minor";
60       case ZMajor: return "ZGC Major";
61       case Z: return "Z";
62       case Shenandoah: return "Shenandoah";
63       case ShenandoahYoung: return "Shenandoah Young";
64       case ShenandoahOld: return "Shenandoah Old";
65       case NA: return "N/A";
66       default: ShouldNotReachHere(); return nullptr;
67     }
68   }
69 };
70 
71 #endif // SHARE_GC_SHARED_GCNAME_HPP
< prev index next >