GDC - program runs in one thread, DMD - in 4 threads, why?
eugene
dee0xeed at gmail.com
Fri Sep 10 12:46:36 UTC 2021
On Friday, 10 September 2021 at 12:10:58 UTC, Adam D Ruppe wrote:
> btw why do the threads cause you trouble?
Well... probably it is subjective thing -
just do not 'like' when a program is doing something
that is not explicitly in it's source (I am C coder, you guessed).
More specifically - I have event driven state machine engine
(reactor pattern, written in C), which I have been using
over recent 5 years in various data acquisition and
network client/servers programs. All these programs
by their nature are single-threaded, since
'event/message driven' + 'state machines' combination gives me
very
high-grained concurrency within single thread
(and I don't like fibers/greenlets/coroutines).
Recently I tried to re-implement that engine in D
(I also tried Rust and C#, but D appeared to be less
'problematic').
I can give a link to sources of those echo-client/server pair
if someone is interested (but there is a 'little' problem
remained - when compliled with dmd, it sometimes crashes
upon receiving SIGINT).
More information about the Digitalmars-d-learn
mailing list