53 static int _max_alignment; 54 static bool _link_classes_made_progress; 55 static bool _check_classes_made_progress; 56 static bool _has_error_classes; 57 static bool _archive_loading_failed; 58 public: 59 enum { 60 vtbl_list_size = 17, // number of entries in the shared space vtable list. 61 num_virtuals = 200, // maximum number of virtual functions 62 // If virtual functions are added to Metadata, 63 // this number needs to be increased. Also, 64 // SharedMiscCodeSize will need to be increased. 65 // The following 2 sizes were based on 66 // MetaspaceShared::generate_vtable_methods() 67 vtbl_method_size = 16, // conservative size of the mov1 and jmp instructions 68 // for the x64 platform 69 vtbl_common_code_size = (1*K) // conservative size of the "common_code" for the x64 platform 70 }; 71 72 enum { 73 ro = 0, // read-only shared space in the heap 74 rw = 1, // read-write shared space in the heap 75 md = 2, // miscellaneous data for initializing tables, etc. 76 mc = 3, // miscellaneous code - vtable replacement. 77 n_regions = 4 78 }; 79 80 // Accessor functions to save shared space created for metadata, which has 81 // extra space allocated at the end for miscellaneous data and code. 82 static void set_max_alignment(int alignment) { 83 CDS_ONLY(_max_alignment = alignment); 84 } 85 86 static int max_alignment() { 87 CDS_ONLY(return _max_alignment); 88 NOT_CDS(return 0); 89 } 90 91 static void prepare_for_dumping() NOT_CDS_RETURN; 92 static void preload_and_dump(TRAPS) NOT_CDS_RETURN; | 53 static int _max_alignment; 54 static bool _link_classes_made_progress; 55 static bool _check_classes_made_progress; 56 static bool _has_error_classes; 57 static bool _archive_loading_failed; 58 public: 59 enum { 60 vtbl_list_size = 17, // number of entries in the shared space vtable list. 61 num_virtuals = 200, // maximum number of virtual functions 62 // If virtual functions are added to Metadata, 63 // this number needs to be increased. Also, 64 // SharedMiscCodeSize will need to be increased. 65 // The following 2 sizes were based on 66 // MetaspaceShared::generate_vtable_methods() 67 vtbl_method_size = 16, // conservative size of the mov1 and jmp instructions 68 // for the x64 platform 69 vtbl_common_code_size = (1*K) // conservative size of the "common_code" for the x64 platform 70 }; 71 72 enum { 73 min_ro_size = NOT_LP64(8*M) LP64_ONLY(9*M), // minimum ro and rw regions sizes based on dumping 74 min_rw_size = NOT_LP64(7*M) LP64_ONLY(12*M) // of a shared archive using the default classlist 75 }; 76 77 enum { 78 ro = 0, // read-only shared space in the heap 79 rw = 1, // read-write shared space in the heap 80 md = 2, // miscellaneous data for initializing tables, etc. 81 mc = 3, // miscellaneous code - vtable replacement. 82 n_regions = 4 83 }; 84 85 // Accessor functions to save shared space created for metadata, which has 86 // extra space allocated at the end for miscellaneous data and code. 87 static void set_max_alignment(int alignment) { 88 CDS_ONLY(_max_alignment = alignment); 89 } 90 91 static int max_alignment() { 92 CDS_ONLY(return _max_alignment); 93 NOT_CDS(return 0); 94 } 95 96 static void prepare_for_dumping() NOT_CDS_RETURN; 97 static void preload_and_dump(TRAPS) NOT_CDS_RETURN; |