
public class HjFastBarrierEurekaImpl extends HjFastBarrierEureka
| Constructor and Description |
|---|
HjFastBarrierEurekaImpl(int numPhases) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
check(Boolean localValue,
boolean triggerAbort)
Checks whether the locally known value can lead to a better estimate than the globally known value.
|
int |
curPhase() |
Boolean |
get()
Return the value stored in the eureka object.
|
int |
numPhases() |
boolean |
offer(Boolean newValue,
boolean triggerAbort)
Attempts to update the eureka object with a new value.
|
void |
onCleanup()
Invoked by the runtime at the end of the finish scope in which the eureka has been registered.
|
void |
onRegistration()
Invoked by the runtime at the start of the finish scope in which the eureka has been registered.
|
protected void |
register() |
boolean |
resolved()
Return true if the eureka has been resolved.
|
boolean |
shouldAbortOnOffer(boolean offerResult)
Return true if the eureka should abort the current task on a successful update.
|
protected void |
signal() |
String |
toString() |
asyncFastPhasedpublic int curPhase()
curPhase in class HjFastBarrierEurekapublic int numPhases()
numPhases in class HjFastBarrierEurekaprotected void register()
register in class HjFastBarrierEurekapublic void onRegistration()
public void onCleanup()
public boolean resolved()
public boolean shouldAbortOnOffer(boolean offerResult)
offerResult - The result of offer() if this method is called from inside the offer()
method.public Boolean get()
public boolean offer(Boolean newValue, boolean triggerAbort) throws SuspendableException
shouldAbortOnOffer() returns true and
triggerAbort is true, the task will abort instead of returning true.newValue - The new value to try and update the eureka object with.triggerAbort - Boolean value that conmfigures whether task is aborted inside this method call.offer should trigger task abortion.SuspendableException - Marker to notify that this method is suspendablepublic boolean check(Boolean localValue, boolean triggerAbort) throws SuspendableException
localValue - The local value used to compare with the globally known eureka valuetriggerAbort - Boolean value that conmfigures whether task is aborted inside this method call.offer should trigger task abortion.SuspendableException - Marker to notify that this method is suspendableprotected void signal()
throws SuspendableException
signal in class HjFastBarrierEurekaSuspendableExceptionCopyright © 2015 Rice University - Department of Computer Science. All rights reserved.