Top


定義場所(file name)

hotspot/src/share/vm/gc_implementation/shared/mutableNUMASpace.cpp

説明(description)

// Update space layout. Perform adaptation.

名前(function name)

void MutableNUMASpace::update() {

本体部(body)

  {- -------------------------------------------
  (1) 
      ---------------------------------------- -}

      if (update_layout(false)) {
        // If the topology has changed, make all chunks zero-sized.
        // And clear the alloc-rate statistics.
        // In future we may want to handle this more gracefully in order
        // to avoid the reallocation of the pages as much as possible.
        for (int i = 0; i < lgrp_spaces()->length(); i++) {
          LGRPSpace *ls = lgrp_spaces()->at(i);
          MutableSpace *s = ls->space();
          s->set_end(s->bottom());
          s->set_top(s->bottom());
          ls->clear_alloc_rate();
        }
        // A NUMA space is never mangled
        initialize(region(),
                   SpaceDecorator::Clear,
                   SpaceDecorator::DontMangle);
      } else {
        bool should_initialize = false;
        if (!os::numa_has_static_binding()) {
          for (int i = 0; i < lgrp_spaces()->length(); i++) {
            if (!lgrp_spaces()->at(i)->invalid_region().is_empty()) {
              should_initialize = true;
              break;
            }
          }
        }

        if (should_initialize ||
            (UseAdaptiveNUMAChunkSizing && adaptation_cycles() < samples_count())) {
          // A NUMA space is never mangled
          initialize(region(),
                     SpaceDecorator::Clear,
                     SpaceDecorator::DontMangle);
        }
      }

      if (NUMAStats) {
        for (int i = 0; i < lgrp_spaces()->length(); i++) {
          lgrp_spaces()->at(i)->accumulate_statistics(page_size());
        }
      }

      scan_pages(NUMAPageScanRate);
    }

This document is available under the GNU GENERAL PUBLIC LICENSE Version 2.