equal
deleted
inserted
replaced
375 |
375 |
376 |
376 |
377 JVM_ENTRY_NO_ENV(jlong, JVM_FreeMemory(void)) |
377 JVM_ENTRY_NO_ENV(jlong, JVM_FreeMemory(void)) |
378 JVMWrapper("JVM_FreeMemory"); |
378 JVMWrapper("JVM_FreeMemory"); |
379 CollectedHeap* ch = Universe::heap(); |
379 CollectedHeap* ch = Universe::heap(); |
380 size_t n = ch->capacity() - ch->used(); |
380 size_t n; |
|
381 { |
|
382 MutexLocker x(Heap_lock); |
|
383 n = ch->capacity() - ch->used(); |
|
384 } |
381 return convert_size_t_to_jlong(n); |
385 return convert_size_t_to_jlong(n); |
382 JVM_END |
386 JVM_END |
383 |
387 |
384 |
388 |
385 JVM_ENTRY_NO_ENV(jlong, JVM_MaxMemory(void)) |
389 JVM_ENTRY_NO_ENV(jlong, JVM_MaxMemory(void)) |