• David Gibson's avatar
    altstack: Consolidate thread-local variables · 2da0271f
    David Gibson authored
    altstack uses a number of __thread variables to track internal state.  This
    allows altstack to be thread-safe, although it's still not re-entrant.
    This patch gathers all these variables into a single per-thread state
    structure.  This makes it easy to see at a glance what the whole of the
    required state is, and thereby easier to reason about correctness of
    changes to the implementation.
    Signed-off-by: default avatarDavid Gibson <david@gibson.dropbear.id.au>
    2da0271f
altstack.c 3.11 KB