Re: Low-latency pause in JDK
Francesco Nigro via Concurrency-interest <[email protected]>
| Newsgroups | gmane.comp.java.jsr.166-concurrency |
|---|---|
| Message-ID | <CAKxGtTU2eoVQ5N=Fcs8VbkO-Pz1mdo3smsA6PC5JOWFAht7zVg@mail.gmail.com> |
+100 totally agree! Il ven 25 ott 2019, 20:30 Viktor Klang <[email protected]> ha scritto: > Sounds like a good reason for a JDK-official method for it… > > On Fri, Oct 25, 2019 at 10:28 AM Francesco Nigro <[email protected]> > wrote: > >> To not mention that you need to consider counted loops/safepoint polls in >> the equation >> >> Il ven 25 ott 2019, 19:26 Francesco Nigro <[email protected]> ha >> scritto: >> >>> I haven't seen anything yet if not on some initial implementations of >>> the fork join pool, lately removed. If you need something that is more >>> aware of the OS behaviour eg timeslack_ns probably is something you need to >>> implement by yourself afaik :( (see >>> https://github.com/JCTools/JCTools/pull/248#pullrequestreview-248613337) >>> >>> Il ven 25 ott 2019, 19:14 Viktor Klang via Concurrency-interest < >>> [email protected]> ha scritto: >>> >>>> Hey, >>>> >>>> Is there any jdk-builtin Java8+ method which tries to be clever about >>>> low-nanos/micros parking? >>>> >>>> I'm currently considering LockSupport.parkNanos but want to avoid >>>> having the Thread parked when parking + wake-up latency is more likely to >>>> be much greater than the requested time. >>>> >>>> I.e. some combination of onSpinWait + some non-cache-polluting >>>> computation + yielding + actual parking. I'd like to avoid having to >>>> custom-roll it, hence the question for prior art ;) >>>> >>>> -- >>>> Cheers, >>>> √ >>>> _______________________________________________ >>>> Concurrency-interest mailing list >>>> [email protected] >>>> http://cs.oswego.edu/mailman/listinfo/concurrency-interest >>>> >>> > > -- > Cheers, > √ > _______________________________________________ Concurrency-interest mailing list [email protected] http://cs.oswego.edu/mailman/listinfo/concurrency-interest