13 ms·
> Surprise! It is calling clock_gettime(), which has been in the libc since SUSv2, POSIX.1-2001. On clang 3.9.0/src/chrono.cpp it looks like a straight copy of
by easytiger 10y ago
> Surprise! It is calling clock_gettime(), which has been in the libc since SUSv2, POSIX.1-2001. On clang 3.9.0/src/chrono.cpp it looks like a straight copy of it:
So what? That is the preffered unix way to get time, along with gettimeofday() as the code indicates? That is the only way to get the time on unix, unless you have specialist hardware.
I think this guy has a massive failure in understanding how computers work, to be quite frank.
> Here we see gcc is shamelessly opening /dev/urandom, a Linux kernel facility
OK, now you are surely trolling us... you want them to implement their own entropy sources?
> std::threads is in fact, a gift-wrapped pthreads which was defined in POSIX.1c, Threads extensions (IEEE Std 1003.1c-1995).
Because that is the native API for lightweight threads in Linux... the windows impl will use the same native facilities. What giberish is this?
> Again std::thread is pthreads, wrapped. Oh you C++, can’t you do anything by yourself?
I don't even know how to express how much of a joke this article is, at the very best questionable misinformation.
- clishem 10y agoExactly my thoughts. These are not meant as better new implementations but as high-level abstractions.