3 ms·
The C runtime consists of stuff like malloc and free. Newer versions of C also require support for thread-local storage for example. It is not a lot, but there
by qznc 13y ago
The C runtime consists of stuff like malloc and free. Newer versions of C also require support for thread-local storage for example. It is not a lot, but there definitly is a small runtime called libc.
Of course, the C standard also defines the freestanding variant, but there is not even main() anymore.
- justincormack 13y agoIts barely a runtime though. I prefer to view Unix as the runtime for C...
- haberman 13y agoA standard library is not the same as a runtime. A library you explicitly call out to, and if you do not call it you can avoid linking the library at all. A runtime inserts calls to itself in a way that cannot be reasonably avoided, and must therefore be linked/loaded by every program.