Warning, /cpukit/libcsupport/src/README.md is written in an unsupported language. File is not indexed.
0001 libcsupport
0002 ===========
0003
0004 Overview of newlib support (newlib is from CYGNUS)
0005 Each task can have its own libc state including:
0006 open stdio files
0007 strtok
0008 multi precision arithmetic state
0009 etc.
0010
0011 This is implemented by a reentrancy data structure for each task.
0012
0013 When a task is "started" (in RTEMS sense) the reentrancy structure
0014 is allocated.
0015
0016 When task is switched to, the value of global variable _impure_ptr
0017 is changed to the value of the new tasks reentrancy structure.
0018
0019 When a task is deleted
0020 atexit() processing (for that task) happens
0021 task's stdio buffers are flushed
0022
0023 When exit(3) is called
0024 calling task's atexit processing done
0025 global libc state atexit processing done
0026 (this will include any atexit routines installed by drivers)
0027 executive is shutdown
0028 causes a context switch back to bsp land
0029
0030
0031 NOTE:
0032 libc extension are installed by bsp_libc_init()
0033 iff we are using clock interrupts.
0034 This hack is necessary to allow the tmtests to avoid
0035 timing the extensions.
0036
0037
0038 Cases
0039 -----
0040 This is a list of cases to consider when implementing a file system:
0041
0042
0043 ```
0044 + Given a tree of this form:
0045
0046 a ----- b
0047 /
0048 c
0049 ```
0050
0051 Where a and b are directories and c is a link to directory b. Consider
0052 this sequence:
0053
0054 - rmdir a/b
0055 - mknod c/b/x
0056 - unlink c
0057
0058
0059 TODO
0060 ----
0061 + newlib 1.8.0 has the wrong prototype for at least read() and write().
0062
0063 + There should be a "eat it" stub for all system calls which are
0064 available to make filling out an operations table easier.
0065 See device_lseek() for an example of where this would be nice.
0066
0067 + Fix strerror() so it prints all error numbers.
0068
0069 + Check the node allocation coment in the fchdir call.
0070 + Add an interface somewhere for this call.