template statistics
Adam D. Ruppe
destructionator at gmail.com
Thu Jun 4 02:28:03 UTC 2020
On Thursday, 4 June 2020 at 01:38:50 UTC, Walter Bright wrote:
> Furthermore, stdout has to acquire a mutex before writing to it:
No need for any of this on the OS level, a write up to like 4k is
guaranteed to be atomic.
It is the C buffer that isn't :(
And the C buffer is a consistent source of pain for
user-interactive i/o. Buffering makes a big performance
difference when you are actually outputting a block... but with
user-interactive you rarely actually *want* buffering since users
want to see their results ASAP! And remember, pipes are
frequently user-interactive too and them not being flushed
frequently is a FAQ among new users, especially IDE users.
I kinda feel buffering should not be done across function
boundaries for stdout and stderr. Other files maybe.
More information about the Digitalmars-d
mailing list