Tagged Questions
1
vote
2answers
48 views
How does the Exchanger supports GC-less Java?
While reading about concurrent api of java, i came to know about Exchanger class.
From Java docs,
"A synchronization point at which threads can pair and swap elements within pairs. Each thread ...
2
votes
1answer
80 views
How to make Weakrefernce in Concurrent HashMap
In my Program I have a scenario, where Mutiple Thread will operate (put and get) on a single Map. Like Thread a using put a key/value in the map and the same time another thread is retrieving the ...
2
votes
1answer
140 views
OpenJDK's LinkedBlockingQueue implementation: Node class and GC
I'm a little confused by the structure of the Node class in OpenJDK's implementation of LinkedBlockingQueue (in java.util.concurrent).
I've reproduced the description of the node class below:
static ...
11
votes
4answers
470 views
Strange code in java.util.concurrent.LinkedBlockingQueue
All!
I found strange code in LinkedBlockingQueue:
private E dequeue() {
// assert takeLock.isHeldByCurrentThread();
Node<E> h = head;
Node<E> first = h.next;
...