@@ -1124,7 +1124,7 @@ impl SideMetadataContext {
1124
1124
/// # Arguments
1125
1125
/// * `start` - The starting address of the source data.
1126
1126
/// * `size` - The size of the source data (in bytes).
1127
- /// * `no_reserve` - whether to invoke mmap with a noreserve flag (we use this flag to quanrantine address range)
1127
+ /// * `no_reserve` - whether to invoke mmap with a noreserve flag (we use this flag to quarantine address range)
1128
1128
fn map_metadata_internal ( & self , start : Address , size : usize , no_reserve : bool ) -> Result < ( ) > {
1129
1129
for spec in self . global . iter ( ) {
1130
1130
match try_mmap_contiguous_metadata_space ( start, size, spec, no_reserve) {
@@ -1137,15 +1137,17 @@ impl SideMetadataContext {
1137
1137
let mut lsize: usize = 0 ;
1138
1138
1139
1139
for spec in self . local . iter ( ) {
1140
- // For local side metadata, we always have to reserve address space for all
1141
- // local metadata required by all policies in MMTk to be able to calculate a constant offset for each local metadata at compile-time
1142
- // (it's like assigning an ID to each policy).
1143
- // As the plan is chosen at run-time, we will never know which subset of policies will be used during run-time.
1144
- // We can't afford this much address space in 32-bits.
1140
+ // For local side metadata, we always have to reserve address space for all local
1141
+ // metadata required by all policies in MMTk to be able to calculate a constant offset
1142
+ // for each local metadata at compile-time (it's like assigning an ID to each policy).
1143
+ //
1144
+ // As the plan is chosen at run-time, we will never know which subset of policies will
1145
+ // be used during run-time. We can't afford this much address space in 32-bits.
1145
1146
// So, we switch to the chunk-based approach for this specific case.
1146
1147
//
1147
- // The global metadata is different in that for each plan, we can calculate its constant base addresses at compile-time.
1148
- // Using the chunk-based approach will need the same address space size as the current not-chunked approach.
1148
+ // The global metadata is different in that for each plan, we can calculate its constant
1149
+ // base addresses at compile-time. Using the chunk-based approach will need the same
1150
+ // address space size as the current not-chunked approach.
1149
1151
#[ cfg( target_pointer_width = "64" ) ]
1150
1152
{
1151
1153
match try_mmap_contiguous_metadata_space ( start, size, spec, no_reserve) {
@@ -1191,13 +1193,13 @@ impl SideMetadataContext {
1191
1193
debug_assert ! ( size % BYTES_IN_PAGE == 0 ) ;
1192
1194
1193
1195
for spec in self . global . iter ( ) {
1194
- ensure_munmap_contiguos_metadata_space ( start, size, spec) ;
1196
+ ensure_munmap_contiguous_metadata_space ( start, size, spec) ;
1195
1197
}
1196
1198
1197
1199
for spec in self . local . iter ( ) {
1198
1200
#[ cfg( target_pointer_width = "64" ) ]
1199
1201
{
1200
- ensure_munmap_contiguos_metadata_space ( start, size, spec) ;
1202
+ ensure_munmap_contiguous_metadata_space ( start, size, spec) ;
1201
1203
}
1202
1204
#[ cfg( target_pointer_width = "32" ) ]
1203
1205
{
0 commit comments