Add missing last padding / Comment

This commit is contained in:
Trustin Lee 2014-06-21 17:52:40 +09:00
parent b1a5ced729
commit 6834c2da51
2 changed files with 4 additions and 0 deletions

View File

@ -69,6 +69,9 @@ final class MpscLinkedQueue<E> extends MpscLinkedQueueTailRef<E> implements Queu
private static final long serialVersionUID = -1878402552271506449L;
long p00, p01, p02, p03, p04, p05, p06, p07;
long p30, p31, p32, p33, p34, p35, p36, p37;
// offer() occurs at the tail of the linked list.
// poll() occurs at the head of the linked list.
//

View File

@ -48,6 +48,7 @@ abstract class MpscLinkedQueueTailRef<E> extends MpscLinkedQueuePad1<E> {
@SuppressWarnings("unchecked")
protected final MpscLinkedQueueNode<E> getAndSetTailRef(MpscLinkedQueueNode<E> tailRef) {
// LOCK XCHG in JDK8, a CAS loop in JDK 7/6
return (MpscLinkedQueueNode<E>) UPDATER.getAndSet(this, tailRef);
}
}