Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stubs for ThirdParty #8

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions MMTk/src/org/mmtk/plan/ThirdParty.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*
* This file is part of the Jikes RVM project (http://jikesrvm.org).
*
* This file is licensed to You under the Eclipse Public License (EPL);
* You may not use this file except in compliance with the License. You
* may obtain a copy of the License at
*
* http://www.opensource.org/licenses/eclipse-1.0.php
*
* See the COPYRIGHT.txt file distributed with this work for information
* regarding copyright ownership.
*/
package org.mmtk.plan;

import org.mmtk.policy.Space;
import org.mmtk.utility.Log;
import org.mmtk.utility.alloc.Allocator;
import org.mmtk.utility.options.*;
import org.mmtk.utility.statistics.Timer;
import org.mmtk.vm.VM;

import org.vmmagic.pragma.*;

/**
* This abstract class implements the core functionality for
* simple collectors.<p>
*
* This class defines the collection phases, and provides base
* level implementations of them. Subclasses should provide
* implementations for the spaces that they introduce, and
* delegate up the class hierarchy.<p>
*
* For details of the split between global and thread-local operations
* @see org.mmtk.plan.Plan
*/
@Uninterruptible
public class ThirdParty extends Simple {

}
36 changes: 36 additions & 0 deletions MMTk/src/org/mmtk/plan/ThirdPartyCollector.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
* This file is part of the Jikes RVM project (http://jikesrvm.org).
*
* This file is licensed to You under the Eclipse Public License (EPL);
* You may not use this file except in compliance with the License. You
* may obtain a copy of the License at
*
* http://www.opensource.org/licenses/eclipse-1.0.php
*
* See the COPYRIGHT.txt file distributed with this work for information
* regarding copyright ownership.
*/
package org.mmtk.plan;

import org.mmtk.utility.Log;
import org.mmtk.utility.options.Options;
import org.mmtk.utility.sanitychecker.SanityCheckerLocal;

import org.mmtk.vm.VM;

import org.vmmagic.pragma.*;

/**
* This class (and its sub-classes) implement <i>per-collector thread</i>
* behavior and state.<p>
*
* MMTk assumes that the VM instantiates instances of CollectorContext
* in thread local storage (TLS) for each thread participating in
* collection. Accesses to this state are therefore assumed to be
* low-cost during mutator time.
*
* @see CollectorContext
*/
@Uninterruptible
public class ThirdPartyCollector extends SimpleCollector {
}
38 changes: 38 additions & 0 deletions MMTk/src/org/mmtk/plan/ThirdPartyConstraints.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/*
* This file is part of the Jikes RVM project (http://jikesrvm.org).
*
* This file is licensed to You under the Eclipse Public License (EPL);
* You may not use this file except in compliance with the License. You
* may obtain a copy of the License at
*
* http://www.opensource.org/licenses/eclipse-1.0.php
*
* See the COPYRIGHT.txt file distributed with this work for information
* regarding copyright ownership.
*/
package org.mmtk.plan;

import org.vmmagic.pragma.*;

/**
* Constraints specific to simple collectors.
*/
@Uninterruptible
public class ThirdPartyConstraints extends SimpleConstraints {
// A third party GC may not move objects. But unless we have a way for a TPH
// to configure this, we need this to be true to be correct.
@Override
public boolean movesObjects() {
return true;
}
// The number doesnt matter.
@Override
public int gcHeaderBits() {
return 0;
}
// The number doesnt matter.
@Override
public int gcHeaderWords() {
return 0;
}
}