DUE TO SPAM, SIGN-UP IS DISABLED. Goto Selfserve wiki signup and request an account.
...
Another data item that should, eventually, be included in the TLS data is the process ID (pid) if the currently exectuting thread. In some analysis of PROTECTED and KERNEL builds, it was found that getpid() was the most highly accessed OS interface. By moving the pid into TLS, we could eliminate this system call overhead (at least in the aligned TLS case). The same mechanism would be used by pthread_self() which, in NuttX, would be the equivalent function, but following pthread semantics.
Re-Entrant getopt()
getopt() is an important C library function used by applications for parsing of task command line paramters. It is, however, not re-entrant due to the use of global variables: optarg, opterr, optind, and optopt. There are several, non-standard implementations for a re-entrant version of called getopt_r(), however, these are all wildly different and do not conform to any standard. Non-standard interfaces are not desirable in NuttX.
...