Home
last modified time | relevance | path

Searched refs:pred (Results 1 – 13 of 13) sorted by relevance

/libcore/ojluni/src/main/java/java/util/concurrent/
DLinkedTransferQueue.java636 Node pred = tryAppend(s, haveData); in xfer() local
637 if (pred == null) in xfer()
640 return awaitMatch(s, pred, e, (how == TIMED), nanos); in xfer()
693 private E awaitMatch(Node s, Node pred, E e, boolean timed, long nanos) { in awaitMatch() argument
708 unsplice(pred, s); // try to unlink and cancel in awaitMatch()
713 if ((spins = spinsFor(pred, s.isData)) > 0) in awaitMatch()
739 private static int spinsFor(Node pred, boolean haveData) { in spinsFor() argument
740 if (MP && pred != null) { in spinsFor()
741 if (pred.isData != haveData) // phase change in spinsFor()
743 if (pred.isMatched()) // probably at front in spinsFor()
[all …]
DFutureTask.java469 for (WaitNode pred = null, q = waiters, s; q != null; q = s) { in removeWaiter()
472 pred = q; in removeWaiter()
473 else if (pred != null) { in removeWaiter()
474 pred.next = s; in removeWaiter()
475 if (pred.thread == null) // check for race in removeWaiter()
DConcurrentLinkedQueue.java477 Node<E> next, pred = null; in remove() local
478 for (Node<E> p = first(); p != null; pred = p, p = next) { in remove()
490 if (pred != null && next != null) // unlink in remove()
491 casNext(pred, p, next); in remove()
732 final Node<E> pred = nextNode; in next() local
733 if (pred == null) throw new NoSuchElementException(); in next()
735 lastRet = pred; in next()
738 for (Node<E> p = succ(pred), q;; p = q) { in next()
747 casNext(pred, p, q); in next()
DForkJoinTask.java527 ExceptionNode pred = null; in clearExceptionalCompletion() local
531 if (pred == null) in clearExceptionalCompletion()
534 pred.next = next; in clearExceptionalCompletion()
537 pred = e; in clearExceptionalCompletion()
610 ExceptionNode pred = null; in expungeStaleExceptions() local
614 if (pred == null) in expungeStaleExceptions()
617 pred.next = next; in expungeStaleExceptions()
620 pred = e; in expungeStaleExceptions()
DSynchronousQueue.java769 void clean(QNode pred, QNode s) { in clean() argument
779 while (pred.next == s) { // Return early if already unlinked in clean()
798 if (sn == s || pred.casNext(s, sn)) in clean()
813 if (dp == pred) in clean()
815 } else if (casCleanMe(null, pred)) in clean()
DArrayBlockingQueue.java201 int pred = i; in removeAt() local
204 items[pred] = null; in removeAt()
205 this.putIndex = pred; in removeAt()
208 items[pred] = items[i]; in removeAt()
DConcurrentLinkedDeque.java731 final Node<E> pred(Node<E> p) { in pred() method in ConcurrentLinkedDeque
912 for (Node<E> p = last(); p != null; p = pred(p)) { in peekLast()
946 for (Node<E> p = last(); p != null; p = pred(p)) { in pollLast()
1056 for (Node<E> p = last(); p != null; p = pred(p)) { in removeLastOccurrence()
1436 Node<E> nextNode(Node<E> p) { return pred(p); } in nextNode()
/libcore/ojluni/src/main/java/java/util/concurrent/locks/
DAbstractQueuedLongSynchronizer.java316 Node pred = node.prev; in cancelAcquire() local
317 while (pred.waitStatus > 0) in cancelAcquire()
318 node.prev = pred = pred.prev; in cancelAcquire()
323 Node predNext = pred.next; in cancelAcquire()
331 if (node == tail && compareAndSetTail(node, pred)) { in cancelAcquire()
332 pred.compareAndSetNext(predNext, null); in cancelAcquire()
337 if (pred != head && in cancelAcquire()
338 ((ws = pred.waitStatus) == Node.SIGNAL || in cancelAcquire()
339 (ws <= 0 && pred.compareAndSetWaitStatus(ws, Node.SIGNAL))) && in cancelAcquire()
340 pred.thread != null) { in cancelAcquire()
[all …]
DAbstractQueuedSynchronizer.java782 Node pred = node.prev; in cancelAcquire() local
783 while (pred.waitStatus > 0) in cancelAcquire()
784 node.prev = pred = pred.prev; in cancelAcquire()
789 Node predNext = pred.next; in cancelAcquire()
797 if (node == tail && compareAndSetTail(node, pred)) { in cancelAcquire()
798 pred.compareAndSetNext(predNext, null); in cancelAcquire()
803 if (pred != head && in cancelAcquire()
804 ((ws = pred.waitStatus) == Node.SIGNAL || in cancelAcquire()
805 (ws <= 0 && pred.compareAndSetWaitStatus(ws, Node.SIGNAL))) && in cancelAcquire()
806 pred.thread != null) { in cancelAcquire()
[all …]
DStampedLock.java1351 for (WNode pred = node.prev; pred != null; ) { // unsplice in cancelWaiter()
1363 U.compareAndSwapObject(this, WTAIL, node, pred); in cancelWaiter()
1367 if (pred.next == node) // unsplice pred link in cancelWaiter()
1368 U.compareAndSwapObject(pred, WNEXT, node, succ); in cancelWaiter()
1373 if (pred.status != CANCELLED || (pp = pred.prev) == null) in cancelWaiter()
1376 U.compareAndSwapObject(pp, WNEXT, pred, succ); in cancelWaiter()
1377 pred = pp; in cancelWaiter()
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/lang/invoke/
DSerializedLambdaTest.java102 Predicate<String> pred = (Predicate<String> & Serializable) s -> true; in testSimpleSerializedInstantiation() local
103 assertSerial(pred, in testSimpleSerializedInstantiation()
128 Predicate<String> pred = (Predicate<String>) s -> true; in testNonserializableInstantiation() local
129 assertNotSerial(pred, in testNonserializableInstantiation()
145 Predicate<String> pred = new Moo().foo(3); in testSerializeCapturingInt() local
146 assertSerial(pred, p -> { in testSerializeCapturingInt()
160 Predicate<String> pred = new Moo().foo("goo"); in testSerializeCapturingString() local
161 assertSerial(pred, p -> { in testSerializeCapturingString()
180 Predicate<String> pred = new Moo().foo(new Box("goo")); in testSerializeCapturingNonSerializable() local
181 assertNotSerial(pred, p -> { in testSerializeCapturingNonSerializable()
/libcore/ojluni/src/main/java/java/util/
DLinkedList.java157 final Node<E> pred = succ.prev; in linkBefore() local
158 final Node<E> newNode = new Node<>(pred, e, succ); in linkBefore()
160 if (pred == null) in linkBefore()
163 pred.next = newNode; in linkBefore()
413 Node<E> pred, succ; in addAll()
416 pred = last; in addAll()
419 pred = succ.prev; in addAll()
424 Node<E> newNode = new Node<>(pred, e, null); in addAll()
425 if (pred == null) in addAll()
428 pred.next = newNode; in addAll()
[all …]
DHashMap.java2034 TreeNode<K,V> succ = (TreeNode<K,V>)next, pred = prev; in removeTreeNode() local
2035 if (pred == null) in removeTreeNode()
2038 pred.next = succ; in removeTreeNode()
2040 succ.prev = pred; in removeTreeNode()