Gary Willoughby: "Why Go's design is a disservice to intelligent programmers"
via Digitalmars-d-announce
digitalmars-d-announce at puremagic.com
Fri Mar 27 08:28:29 PDT 2015
On Friday, 27 March 2015 at 14:47:08 UTC, Dicebot wrote:
> On Friday, 27 March 2015 at 14:18:33 UTC, Ola Fosheim Grøstad
> wrote:
>> On Friday, 27 March 2015 at 12:15:03 UTC, Sönke Ludwig wrote:
>>> distribution across the cores, but in most scenarios the
>>> number of concurrent tasks should be high enough to keep all
>>> cores busy anyhow. There are also additional costs for moving
>>> fibers (synchronization, cache misses).
>>
>> It is a complete disaster to not move fibers between threads
>> if you want good latency.
>
> Only if execution time between fibers is very unevenly
> distributed and/or their amount is low.
No... E.g.:
On the same thread:
1. fiber A receives request and queries DB (async)
2. fiber B computes for 1 second
3. fiber A sends response.
Latency: 1 second even if all the other threads are free.
More information about the Digitalmars-d-announce
mailing list