Mercurial > hg > truffle
comparison src/share/vm/services/virtualMemoryTracker.cpp @ 20365:3adc0e278f49
8055061: assert at share/vm/services/virtualMemoryTracker.cpp:332 Error: ShouldNotReachHere() when running NMT tests
Summary: Handled CDS mapping region and added test for the scenario
Reviewed-by: coleenp, ctornqvi
author | zgu |
---|---|
date | Tue, 19 Aug 2014 09:05:55 -0400 |
parents | c6211b707068 |
children | 417e3b8d04c5 |
comparison
equal
deleted
inserted
replaced
20364:c6211b707068 | 20365:3adc0e278f49 |
---|---|
335 // Add new region | 335 // Add new region |
336 VirtualMemorySummary::record_reserved_memory(rgn.size(), flag); | 336 VirtualMemorySummary::record_reserved_memory(rgn.size(), flag); |
337 | 337 |
338 *reserved_rgn = rgn; | 338 *reserved_rgn = rgn; |
339 return true; | 339 return true; |
340 } else { | 340 } |
341 ShouldNotReachHere(); | 341 |
342 return false; | 342 // CDS mapping region. |
343 } | 343 // CDS reserves the whole region for mapping CDS archive, then maps each section into the region. |
344 // NMT reports CDS as a whole. | |
345 if (reserved_rgn->flag() == mtClassShared) { | |
346 assert(reserved_rgn->contain_region(base_addr, size), "Reserved CDS region should contain this mapping region"); | |
347 return true; | |
348 } | |
349 | |
350 ShouldNotReachHere(); | |
351 return false; | |
344 } | 352 } |
345 } | 353 } |
346 } | 354 } |
347 | 355 |
348 void VirtualMemoryTracker::set_reserved_region_type(address addr, MEMFLAGS flag) { | 356 void VirtualMemoryTracker::set_reserved_region_type(address addr, MEMFLAGS flag) { |