private static int spinsFor(Node pred,boolean haveData){
  if (MP && pred != null) {
    if (pred.isData != haveData)     return FRONT_SPINS + CHAINED_SPINS;
    if (pred.isMatched())     return FRONT_SPINS;
    if (pred.waiter == null)     return CHAINED_SPINS;
  }
  return 0;
}

private static int spinsFor ( Node pred , boolean haveData ) { if ( MP && pred != null ) { if ( pred . isData != haveData ) return FRONT_SPINS + CHAINED_SPINS ; if ( pred . isMatched ( ) ) return FRONT_SPINS ; if ( pred . waiter == null ) return CHAINED_SPINS ; } return 0 ; }
returns spin / yield value for a node with given predecessor and data mode . see above for explanation .
