kernel: add per-thread errno support
Saves an errno per-thread, retrieved via _get_errno(), instead of changing the value of a global variable during context switches to avoid a hit to the context switch performance. Per-arch asm implementations are provided for maximum performance. Enabled by default, but can be disabled via the CONFIG_ERRNO option. Change-Id: I81d57a2e318c94c68eee913ae0d4ca3a3609c7a4 Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
This commit is contained in:
parent
6eeec2137f
commit
3181df6db4
11 changed files with 143 additions and 1 deletions
|
@ -180,6 +180,9 @@ struct tcs {
|
|||
#ifdef CONFIG_NANO_TIMEOUTS
|
||||
struct _nano_timeout nano_timeout;
|
||||
#endif
|
||||
#ifdef CONFIG_ERRNO
|
||||
int errno_var;
|
||||
#endif
|
||||
};
|
||||
|
||||
struct s_NANO {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue