Mercurial > hg > graal-jvmci-8
comparison src/share/vm/services/management.cpp @ 2230:55cc33cf55bc
7018257: jmm_DumpThreads allocates into permgen
Summary: Don't allocate in permgen
Reviewed-by: ysr, sla
author | stefank |
---|---|
date | Fri, 11 Feb 2011 14:15:16 +0100 |
parents | 3582bf76420e |
children | f7702f8c0e25 |
comparison
equal
deleted
inserted
replaced
2229:183658a2d0b3 | 2230:55cc33cf55bc |
---|---|
1308 objArrayHandle synchronizers_array; | 1308 objArrayHandle synchronizers_array; |
1309 | 1309 |
1310 if (locked_monitors) { | 1310 if (locked_monitors) { |
1311 // Constructs Object[] and int[] to contain the object monitor and the stack depth | 1311 // Constructs Object[] and int[] to contain the object monitor and the stack depth |
1312 // where the thread locked it | 1312 // where the thread locked it |
1313 objArrayOop array = oopFactory::new_system_objArray(num_locked_monitors, CHECK_NULL); | 1313 objArrayOop array = oopFactory::new_system_objArray(num_locked_monitors, false, CHECK_NULL); |
1314 objArrayHandle mh(THREAD, array); | 1314 objArrayHandle mh(THREAD, array); |
1315 monitors_array = mh; | 1315 monitors_array = mh; |
1316 | 1316 |
1317 typeArrayOop tarray = oopFactory::new_typeArray(T_INT, num_locked_monitors, CHECK_NULL); | 1317 typeArrayOop tarray = oopFactory::new_typeArray(T_INT, num_locked_monitors, CHECK_NULL); |
1318 typeArrayHandle dh(THREAD, tarray); | 1318 typeArrayHandle dh(THREAD, tarray); |
1350 assert(ts->threadObj() != NULL, "Must be a valid JavaThread"); | 1350 assert(ts->threadObj() != NULL, "Must be a valid JavaThread"); |
1351 ThreadConcurrentLocks* tcl = ts->get_concurrent_locks(); | 1351 ThreadConcurrentLocks* tcl = ts->get_concurrent_locks(); |
1352 GrowableArray<instanceOop>* locks = (tcl != NULL ? tcl->owned_locks() : NULL); | 1352 GrowableArray<instanceOop>* locks = (tcl != NULL ? tcl->owned_locks() : NULL); |
1353 int num_locked_synchronizers = (locks != NULL ? locks->length() : 0); | 1353 int num_locked_synchronizers = (locks != NULL ? locks->length() : 0); |
1354 | 1354 |
1355 objArrayOop array = oopFactory::new_system_objArray(num_locked_synchronizers, CHECK_NULL); | 1355 objArrayOop array = oopFactory::new_system_objArray(num_locked_synchronizers, false, CHECK_NULL); |
1356 objArrayHandle sh(THREAD, array); | 1356 objArrayHandle sh(THREAD, array); |
1357 synchronizers_array = sh; | 1357 synchronizers_array = sh; |
1358 | 1358 |
1359 for (int k = 0; k < num_locked_synchronizers; k++) { | 1359 for (int k = 0; k < num_locked_synchronizers; k++) { |
1360 synchronizers_array->obj_at_put(k, locks->at(k)); | 1360 synchronizers_array->obj_at_put(k, locks->at(k)); |