bring memory usage below totalmemoryallowed . concode_field_sep ConcurrentHashMap<String,IndexInformation> cache concode_elem_sep TezSpillRecord mapSpillRecord concode_elem_sep LinkedBlockingQueue<String> queue concode_elem_sep AtomicInteger totalMemoryUsed concode_elem_sep Logger LOG concode_elem_sep int totalMemoryAllowed concode_elem_sep Configuration conf concode_field_sep int getSize concode_elem_sep boolean checkTotalMemoryUsed concode_elem_sep void removeMap concode_elem_sep IndexInformation readIndexFileToCache concode_elem_sep TezIndexRecord getIndexInformation concode_elem_sep boolean isUnderConstruction
void function ( ) { while ( totalMemoryUsed . get ( ) > totalMemoryAllowed ) { String loc0 = queue . remove ( ) ; IndexInformation loc1 = cache . remove ( loc0 ) ; if ( loc1 != null ) { totalMemoryUsed . addAndGet ( - loc1 . getSize ( ) ) ; } } }