comparison src/share/vm/memory/universe.cpp @ 6197:d2a62e0f25eb

6995781: Native Memory Tracking (Phase 1) 7151532: DCmd for hotspot native memory tracking Summary: Implementation of native memory tracking phase 1, which tracks VM native memory usage, and related DCmd Reviewed-by: acorn, coleenp, fparain
author zgu
date Thu, 28 Jun 2012 17:03:16 -0400
parents b632e80fc9dc
children da91efe96a93
comparison
equal deleted inserted replaced
6174:74533f63b116 6197:d2a62e0f25eb
762 if (DumpSharedSpaces) 762 if (DumpSharedSpaces)
763 UseSharedSpaces = false; 763 UseSharedSpaces = false;
764 764
765 FileMapInfo* mapinfo = NULL; 765 FileMapInfo* mapinfo = NULL;
766 if (UseSharedSpaces) { 766 if (UseSharedSpaces) {
767 mapinfo = NEW_C_HEAP_OBJ(FileMapInfo); 767 mapinfo = NEW_C_HEAP_OBJ(FileMapInfo, mtInternal);
768 memset(mapinfo, 0, sizeof(FileMapInfo)); 768 memset(mapinfo, 0, sizeof(FileMapInfo));
769 769
770 // Open the shared archive file, read and validate the header. If 770 // Open the shared archive file, read and validate the header. If
771 // initialization files, shared spaces [UseSharedSpaces] are 771 // initialization files, shared spaces [UseSharedSpaces] are
772 // disabled and the file is closed. 772 // disabled and the file is closed.
1544 1544
1545 if (_prev_methods == NULL) { 1545 if (_prev_methods == NULL) {
1546 // This is the first previous version so make some space. 1546 // This is the first previous version so make some space.
1547 // Start with 2 elements under the assumption that the class 1547 // Start with 2 elements under the assumption that the class
1548 // won't be redefined much. 1548 // won't be redefined much.
1549 _prev_methods = new (ResourceObj::C_HEAP) GrowableArray<jweak>(2, true); 1549 _prev_methods = new (ResourceObj::C_HEAP, mtClass) GrowableArray<jweak>(2, true);
1550 } 1550 }
1551 1551
1552 // RC_TRACE macro has an embedded ResourceMark 1552 // RC_TRACE macro has an embedded ResourceMark
1553 RC_TRACE(0x00000100, 1553 RC_TRACE(0x00000100,
1554 ("add: %s(%s): adding prev version ref for cached method @%d", 1554 ("add: %s(%s): adding prev version ref for cached method @%d",