当前位置: 首页>>代码示例>>Java>>正文


Java VMConfiguration类代码示例

本文整理汇总了Java中com.sun.max.vm.VMConfiguration的典型用法代码示例。如果您正苦于以下问题:Java VMConfiguration类的具体用法?Java VMConfiguration怎么用?Java VMConfiguration使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


VMConfiguration类属于com.sun.max.vm包,在下文中一共展示了VMConfiguration类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: doIt

import com.sun.max.vm.VMConfiguration; //导入依赖的package包/类
@Override
protected void doIt() {
    cellPointerTagger.setOperationMode(cellPointerTagger.pointerIndexTagger.actionMode);
    VmThreadLocal.prepareCurrentStackReferenceMap();
    Heap.invokeGCCallbacks(Heap.GCCallbackPhase.BEFORE);
    if (TraceMaxSimTagging) {
        Log.println(cellPointerTagger.pointerIndexTagger.actionMode + " of heap roots.");
    }
    heapRootsTagger.run();
    if (TraceMaxSimTagging) {
        Log.println(cellPointerTagger.pointerIndexTagger.actionMode + " of code.");
    }
    Code.visitCells(cellPointerTagger, true);
    if (TraceMaxSimTagging) {
        Log.println(cellPointerTagger.pointerIndexTagger.actionMode + " of heap.");
    }
    VMConfiguration.vmConfig().heapScheme().walkHeap(cellPointerTagger);
    Heap.invokeGCCallbacks(Heap.GCCallbackPhase.AFTER);
}
 
开发者ID:arodchen,项目名称:MaxSim,代码行数:20,代码来源:MaxSimTaggingScheme.java

示例2: run

import com.sun.max.vm.VMConfiguration; //导入依赖的package包/类
public void run() {
    while (true) {
        // Xen gives us the target in units of 1K
        final long target = toPages(HeapPool.toUnit(GUK.guk_watch_memory_target() * 1024));
        if (target != _current) {
            if (_log) {
                Log.print("PhysicalPagePool.watchTarget, current: "); logMB(_current, false); Log.print(", target: ");  logMB(target, true);
                logState();
            }
            long change = target - _current;
            if (target > _current) {
                change = GUKPagePool.increasePagePool(change);
                VMConfiguration.vmConfig().heapScheme().increaseMemory(Size.fromLong(toBytes(change)));
            } else {
                change = _current - target;
                VMConfiguration.vmConfig().heapScheme().decreaseMemory(Size.fromLong(toBytes(change)));
                long possibleDecrease = GUKPagePool.decreaseablePagePool();
                if (possibleDecrease > 0) {
                    // keep decrease in heap units
                    possibleDecrease = toPages(HeapPool.toUnit(toBytes(possibleDecrease)));
                    GUKPagePool.decreasePagePool(possibleDecrease <= change ? possibleDecrease : change);
                }
                change = -possibleDecrease;
            }
            _current += change;
            if (_log) {
                Log.print("PhysicalPagePool..watchTarget, change: "); logMB(change, false); Log.print(", current: "); logMB(_current, true);
                GUKPagePool.logState();
            }
        }
    }
}
 
开发者ID:SnakeDoc,项目名称:GuestVM,代码行数:33,代码来源:GUKPagePool.java

示例3: isPartOfMaxineVM

import com.sun.max.vm.VMConfiguration; //导入依赖的package包/类
@Override
public boolean isPartOfMaxineVM(VMConfiguration vmConfiguration) {
    return isOAT1X(CompilationBroker.optName()) || isOAT1X(CompilationBroker.baselineName());
}
 
开发者ID:beehive-lab,项目名称:Maxine-VM,代码行数:5,代码来源:Package.java

示例4: isPartOfMaxineVM

import com.sun.max.vm.VMConfiguration; //导入依赖的package包/类
@Override
public boolean isPartOfMaxineVM(VMConfiguration vmConfiguration) {
    return vmConfiguration.runPackage.equals(this);
}
 
开发者ID:beehive-lab,项目名称:Maxine-VM,代码行数:5,代码来源:Package.java

示例5: shrinkHeap

import com.sun.max.vm.VMConfiguration; //导入依赖的package包/类
private static void shrinkHeap(int amount) {
    VMConfiguration.vmConfig().heapScheme().decreaseMemory(VMTestHelper.fromInt(amount));
}
 
开发者ID:SnakeDoc,项目名称:GuestVM,代码行数:4,代码来源:KernelTest.java


注:本文中的com.sun.max.vm.VMConfiguration类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。