ack/lang/cem/libcc.ansi/core
2022-07-16 07:27:46 +00:00
..
ctype Realise that the libc core can safely call other libc core functions, even if 2018-06-21 23:24:23 +02:00
errno Move stdio into (mostly) sys. 2018-06-23 18:54:40 +02:00
locale Realise that the libc core can safely call other libc core functions, even if 2018-06-21 23:24:23 +02:00
math libc floating point and stdio floating point can now be turned on and off using 2018-06-23 00:04:14 +02:00
misc libcc.ansi: make abort() try harder to abort the process 2022-07-16 07:27:46 +00:00
printf Don't try to allocate a ridiculous 1025 bytes on the stack (which completely 2020-02-05 23:05:33 +01:00
scanf Now that printf and scanf contain no FILE*-specific code, we can move them into 2019-06-15 13:53:20 +02:00
setjmp Realise that the libc core can safely call other libc core functions, even if 2018-06-21 23:24:23 +02:00
stdio Partially working port of stdio to CP/M. I'm not sure this will work; it's 2019-06-15 22:22:01 +02:00
stdlib Move the string-to-float functions into core, after marking them as 2018-06-23 11:14:24 +02:00
string Realise that the libc core can safely call other libc core functions, even if 2018-06-21 23:24:23 +02:00
time Move the portable time code into core. clock() goes into sys (as it calls 2018-06-23 19:49:29 +02:00
README.md Realise that the libc core can safely call other libc core functions, even if 2018-06-21 23:24:23 +02:00

This directory contains the libc core: functions here may depend on other libc functions only (so, no unistd.h stuff). Plats don't get to configure this, so nothing here should add any overhead if the function isn't linked.

Examples of what goes here:

  • strcmp() --- because it's pure code.
  • setjmp() --- in EM, it's portable.
  • assert() --- because it only calls other core functions (fputs() and abort()).

Examples of what doesn't go here:

  • malloc() --- because it calls the unistd.h function sbrk() (and so a plat might want to swap it out).
  • stdio --- because it calls the unistd.h functions read(), write() etc.
  • signal() --- because it can't be implemented portably and needs to go in the plat.