|
microfmt
Zero-allocation C++ formatting for constrained environments
|
Fallible local address space with signal-safe fault recovery and customizable TLS. More...
#include <cstddef>#include <cstdint>#include <cstring>#include <functional>#include <setjmp.h>#include <signal.h>#include <type_traits>#include <unistd.h>#include "../microfmt.hpp"#include <reloco/tls_provider.hpp>#include "address_space.hpp"
Go to the source code of this file.
Classes | |
| struct | microfmt::fallible_local_space_tag |
| Tag identifying the fallible local address space. More... | |
| struct | microfmt::detail::fault_recovery_context |
| Context holding the jump buffer and active state for signal-safe memory fault recovery. More... | |
| struct | microfmt::detail::fallible_space_tls_tag |
| Unique tag to isolate the fallible address space's TLS storage slot. More... | |
| struct | microfmt::address_space_traits< fallible_local_space_tag > |
| Traits for fallible_local_space_tag providing fault-safe memory reads and writes. More... | |
Namespaces | |
| namespace | microfmt |
| namespace | microfmt::detail |
Typedefs | |
| using | microfmt::detail::fallible_tls = reloco::tls_provider< fault_recovery_context *, fallible_space_tls_tag > |
Functions | |
| fault_recovery_context * | microfmt::detail::fallible_tls_get () noexcept |
Unwraps fallible_tls::get()'s result to a plain pointer. | |
| bool | microfmt::detail::fallible_tls_set (fault_recovery_context *ctx) noexcept |
Sets the calling thread's recovery-context slot; returns false if the underlying tls_provider::set() itself failed (surfaced to callers the same way a fault during the guarded copy is). | |
| void | microfmt::detail::fallible_signal_handler (int sig, siginfo_t *, void *) noexcept |
| bool | microfmt::detail::install_fallible_handlers () noexcept |
Fallible local address space with signal-safe fault recovery and customizable TLS.