mirror of
https://github.com/openjdk/jdk.git
synced 2026-03-12 00:43:14 +00:00
Reduce reliance on noUserHelp
This commit is contained in:
parent
caeb66bbff
commit
1ba9fc6efd
File diff suppressed because it is too large
Load Diff
@ -641,10 +641,15 @@ public abstract class ForkJoinTask<V> implements Future<V>, Serializable {
|
||||
*/
|
||||
public final ForkJoinTask<V> fork() {
|
||||
Thread t; ForkJoinWorkerThread wt;
|
||||
if ((t = Thread.currentThread()) instanceof ForkJoinWorkerThread)
|
||||
((wt = (ForkJoinWorkerThread)t).workQueue).push(this, wt.pool, 1);
|
||||
ForkJoinPool p; ForkJoinPool.WorkQueue q; boolean internal;
|
||||
if (internal =
|
||||
(t = Thread.currentThread()) instanceof ForkJoinWorkerThread) {
|
||||
q = (wt = (ForkJoinWorkerThread)t).workQueue;
|
||||
p = wt.pool;
|
||||
}
|
||||
else
|
||||
ForkJoinPool.common.externalPush(this, true, false);
|
||||
q = (p = ForkJoinPool.common).externalSubmissionQueue(false);
|
||||
q.push(this, p, internal);
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user