src/hotspot/share/memory/arena.cpp
changeset 51050 96ea37459ca7
parent 49734 f946776e9354
child 54786 ebf733a324d4
equal deleted inserted replaced
51049:70295a56c207 51050:96ea37459ca7
   333 }
   333 }
   334 
   334 
   335 // Total of all Chunks in arena
   335 // Total of all Chunks in arena
   336 size_t Arena::used() const {
   336 size_t Arena::used() const {
   337   size_t sum = _chunk->length() - (_max-_hwm); // Size leftover in this Chunk
   337   size_t sum = _chunk->length() - (_max-_hwm); // Size leftover in this Chunk
   338   register Chunk *k = _first;
   338   Chunk *k = _first;
   339   while( k != _chunk) {         // Whilst have Chunks in a row
   339   while( k != _chunk) {         // Whilst have Chunks in a row
   340     sum += k->length();         // Total size of this Chunk
   340     sum += k->length();         // Total size of this Chunk
   341     k = k->next();              // Bump along to next Chunk
   341     k = k->next();              // Bump along to next Chunk
   342   }
   342   }
   343   return sum;                   // Return total consumed space.
   343   return sum;                   // Return total consumed space.