Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-04-04 Thread Joe Darcy
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v15]

2025-03-28 Thread Viktor Klang
On Thu, 27 Mar 2025 23:20:56 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v14]

2025-03-27 Thread Simon Hartley
On Thu, 27 Mar 2025 17:37:04 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v14]

2025-03-27 Thread Doug Lea
On Thu, 27 Mar 2025 19:29:53 GMT, Simon Hartley wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address review comments > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3927: > >> 3925:

Re: RFR: 8319447: Improve performance of delayed task handling [v15]

2025-03-27 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-27 Thread Doug Lea
On Thu, 27 Mar 2025 13:27:30 GMT, Alan Bateman wrote: >> Personally I think it's worth it. @AlanBateman, what do you think? > > Right now it's hard to envisage needing to have >2B delayed tasks queued. > Maybe in a few years we might regret this. So maybe better to change it to > return long, I

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-27 Thread Doug Lea
On Tue, 25 Mar 2025 19:17:32 GMT, Doug Lea wrote: >> The schedule(Runnable ..) and schedule(Callable ..) methods are a single >> sentence in the interface. The ForkJoinPool methods has more to say about >> cancellation and shutdown. So while it could inherit, doesn't seem to be >> worth it her

Re: RFR: 8319447: Improve performance of delayed task handling [v14]

2025-03-27 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-27 Thread Alan Bateman
On Thu, 27 Mar 2025 09:06:40 GMT, Viktor Klang wrote: >> Arguably better, but not sure it is worth regenerating diffs for? (An int >> was used for the same reason as in FJT.getQueueSize -- they need to be >> valid array bounds. Which might someday allow long, but if so many things >> would ch

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-27 Thread Viktor Klang
On Wed, 26 Mar 2025 19:52:16 GMT, Doug Lea wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3932: >> >>> 3930: * @since 25 >>> 3931: */ >>> 3932: public int getDelayedTaskCount() { >> >> @DougLea It would seem more consistent to have this return a

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Doug Lea
On Wed, 26 Mar 2025 13:14:08 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The pull request now contains 49 commits: >> >> - Merge branch 'openjdk:master' into JDK-8319447 >> - Address review comments >> - Merge branch

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Doug Lea
On Wed, 26 Mar 2025 13:23:12 GMT, Viktor Klang wrote: >> The commonPool can't be shutdown (both shutdown methods are specified to >> have no effect on the common pool) so I suppose it doesn't really matter. > > Heh, that's a fair point, Alan. :) Clarified: * Arranges that scheduled tasks t

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Doug Lea
On Wed, 26 Mar 2025 13:12:47 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The pull request now contains 49 commits: >> >> - Merge branch 'openjdk:master' into JDK-8319447 >> - Address review comments >> - Merge branch

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Doug Lea
On Wed, 26 Mar 2025 13:05:46 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The pull request now contains 49 commits: >> >> - Merge branch 'openjdk:master' into JDK-8319447 >> - Address review comments >> - Merge branch

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Alan Bateman
On Wed, 26 Mar 2025 13:11:40 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The pull request now contains 49 commits: >> >> - Merge branch 'openjdk:master' into JDK-8319447 >> - Address review comments >> - Merge branch

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Viktor Klang
On Tue, 25 Mar 2025 19:57:54 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Viktor Klang
On Wed, 26 Mar 2025 13:14:45 GMT, Alan Bateman wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3743: >> >>> 3741: * @since 25 >>> 3742: */ >>> 3743: public void cancelDelayedTasksOnShutdown() { >> >> @DougLea Should this really be possible to enab

Re: RFR: 8319447: Improve performance of delayed task handling

2025-03-26 Thread Viktor Klang
On Tue, 25 Feb 2025 22:41:07 GMT, Doug Lea wrote: >>> @sunmisc You are right that it would be nice if there were a way to >>> efficiently use getAndSet here because a failed reference CAS hits slow >>> paths that vary across GCs. But all of the ways I know to do this are much >>> worse. >> >>

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-26 Thread Viktor Klang
On Tue, 25 Mar 2025 19:57:54 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 12:06:30 GMT, Alan Bateman wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3507: >> >>> 3505: >>> 3506: /** >>> 3507: * Submits a one-shot task that becomes enabled after the given >> >> If the javadoc for the new methods from the

Re: RFR: 8319447: Improve performance of delayed task handling [v13]

2025-03-25 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 16:41:41 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 16:40:57 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 16:38:55 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 15:40:08 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 15:35:52 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 15:30:22 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Doug Lea
On Tue, 25 Mar 2025 15:14:56 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-25 Thread Alan Bateman
On Mon, 24 Mar 2025 20:03:47 GMT, Joe Darcy wrote: >> Doug Lea has updated the pull request with a new target base due to a merge >> or a rebase. The incremental webrev excludes the unrelated changes brought >> in by the merge/rebase. The pull request contains 47 additional commits >> since th

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-24 Thread Viktor Klang
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-24 Thread Alan Bateman
On Sat, 22 Mar 2025 11:09:03 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v12]

2025-03-22 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v11]

2025-03-19 Thread Dmitry Chuyko
On Fri, 14 Mar 2025 09:36:43 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v11]

2025-03-14 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v10]

2025-03-13 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v9]

2025-03-13 Thread Doug Lea
On Thu, 13 Mar 2025 14:17:29 GMT, Alan Bateman wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Use SharedSecrets for ThreadLocalRandomProbe; other tweaks > > src/java.base/share/classes/java/util/concurrent/atomic/Stri

Re: RFR: 8319447: Improve performance of delayed task handling [v9]

2025-03-13 Thread Alan Bateman
On Tue, 11 Mar 2025 20:29:20 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v9]

2025-03-13 Thread Alan Bateman
On Tue, 11 Mar 2025 20:29:20 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v8]

2025-03-11 Thread Doug Lea
On Tue, 11 Mar 2025 13:46:52 GMT, Viktor Klang wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 1301: >> >>> 1299: if ((room == 0 ||// pad if no caller-run >>> 1300: a[m & (s - ((internal || task == null || >>> 1301:

Re: RFR: 8319447: Improve performance of delayed task handling [v9]

2025-03-11 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v8]

2025-03-11 Thread Viktor Klang
On Sun, 9 Mar 2025 17:17:50 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (as

Re: RFR: 8319447: Improve performance of delayed task handling [v8]

2025-03-11 Thread Viktor Klang
On Mon, 10 Mar 2025 14:34:42 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Disambiguate caller-runs vs Interruptible > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 1301:

Re: RFR: 8319447: Improve performance of delayed task handling [v8]

2025-03-09 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-09 Thread Doug Lea
On Thu, 6 Mar 2025 14:34:00 GMT, Alan Bateman wrote: >> Maybe it's worth using java.time.Duration, although it doesn't fit into the >> API very elegantly. > >> I wonder if the variance of the Consumer to this method should be more >> permissible. Something like: >> >> public ForkJoinTask submi

Re: RFR: 8319447: Improve performance of delayed task handling [v7]

2025-03-08 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-06 Thread Alan Bateman
On Wed, 5 Mar 2025 23:55:52 GMT, Sunmisc Unsafe wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3741: >> >>> 3739: public ForkJoinTask submitWithTimeout(Callable callable, >>> 3740: long timeout, >>> TimeUni

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-05 Thread Sunmisc Unsafe
On Wed, 5 Mar 2025 15:13:06 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Reduce volatile reads > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3741: > >> 3739: publ

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-05 Thread Viktor Klang
On Sat, 1 Mar 2025 15:43:17 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (as

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-03 Thread Doug Lea
On Sun, 2 Mar 2025 15:49:26 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Reduce volatile reads > > src/java.base/share/classes/java/util/concurrent/DelayScheduler.java line 255: > >> 253:

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-02 Thread Viktor Klang
On Sat, 1 Mar 2025 15:43:17 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (as

Re: RFR: 8319447: Improve performance of delayed task handling [v6]

2025-03-01 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v5]

2025-02-28 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-27 Thread Doug Lea
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-26 Thread Doug Lea
On Wed, 26 Feb 2025 13:30:56 GMT, Viktor Klang wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3131: >> >>> 3129: if ((p = (cp = common).parallelism) < 2) >>> 3130: U.compareAndSetInt(cp, PARALLELISM, p, 2); >>> 3131: return cp; >> >

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-26 Thread Viktor Klang
On Wed, 26 Feb 2025 10:13:12 GMT, Alan Bateman wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3131: > >> 3129

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-26 Thread Doug Lea
On Wed, 26 Feb 2025 10:13:12 GMT, Alan Bateman wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3131: > >> 3129

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-26 Thread Alan Bateman
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 19:42:01 GMT, Sunmisc Unsafe wrote: >> Is it possible to use getAndSet instead of cas-loop on #pend? >> >> final Task t = tail.getAndSet(task); >> t.next = task; >> >> but that would require a new head field to bypass, probably not worth the >> gamble if the footprint incre

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 17:23:07 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > test/jdk/java/util/concurrent/tck/ForkJoinPool20Test.java line 649: > >> 647:

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 17:21:56 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > test/jdk/java/util/concurrent/tck/ForkJoinPool20Test.java line 630: > >> 628:

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 17:06:31 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > test/jdk/java/util/concurrent/tck/ForkJoinPool20Test.java line 577: > >> 575:

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 17:04:20 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > test/jdk/java/util/concurrent/tck/ForkJoinPool20Test.java line 523: > >> 521:

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 14:51:29 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > src/java.base/share/classes/java/util/concurrent/DelayScheduler.java line 455: > >> 453

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 14:46:07 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > src/java.base/share/classes/java/util/concurrent/DelayScheduler.java line 356: > >> 354

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Doug Lea
On Tue, 25 Feb 2025 14:37:49 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Standardize parameter checking > > src/java.base/share/classes/java/util/concurrent/DelayScheduler.java line 99: > >> 97:

Re: RFR: 8319447: Improve performance of delayed task handling

2025-02-25 Thread Sunmisc Unsafe
On Thu, 20 Feb 2025 22:35:07 GMT, Sunmisc Unsafe wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottlen

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-25 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-24 Thread Viktor Klang
On Sun, 23 Feb 2025 15:26:48 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v3]

2025-02-23 Thread Doug Lea
On Sat, 22 Feb 2025 14:30:11 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v4]

2025-02-23 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v3]

2025-02-22 Thread Doug Lea
> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) > > The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is > both ill-suited for many (if not most) of its applications, and is a > performance bottleneck (as seen especially in Loom and CompletableFuture > usages

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:10:24 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 146: > >> 144: * and invoke

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:16:55 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 187: > >> 185: * are used. I

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:38:00 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3526: > >> 3524: if (

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:23:23 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 2585: > >> 2583: * throw

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:11:31 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 160: > >> 158: * do not incl

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 16:52:41 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/ForkJoinTask.java line 1668: > >> 1666:

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 16:34:32 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/CompletableFuture.java line > 2947: > >> 2945:

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 16:28:15 GMT, Viktor Klang wrote: >> Doug Lea has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address feedback > > src/java.base/share/classes/java/util/concurrent/CompletableFuture.java line > 2840: > >> 2838:

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-22 Thread Doug Lea
On Fri, 21 Feb 2025 17:30:46 GMT, Alan Bateman wrote: >> Added: >> Delayed actions become enabled and behave as ordinary submitted >> tasks when their delays elapse. > > Thanks. Also here we have ".. after the given delay, At which" so need to > smooth that out. OK. I also renamed executeRea

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Alan Bateman
On Fri, 21 Feb 2025 12:52:10 GMT, Doug Lea wrote: >> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 3537: >> >>> 3535: * pool is {@link #shutdownNow}, or is {@link #shutdown} when >>> 3536: * otherwise quiescent and {@link #cancelDelayedTasksOnShutdown} >>> 353

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling [v2]

2025-02-21 Thread Viktor Klang
On Fri, 21 Feb 2025 13:16:10 GMT, Doug Lea wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottleneck (a

Re: RFR: 8319447: Improve performance of delayed task handling

2025-02-21 Thread Doug Lea
On Thu, 20 Feb 2025 22:35:07 GMT, Sunmisc Unsafe wrote: >> (Copied from https://bugs.openjdk.org/browse/JDK-8319447) >> >> The problems addressed by this CR/PR are that ScheduledThreadPoolExecutor is >> both ill-suited for many (if not most) of its applications, and is a >> performance bottlen

  1   2   >