Cygwin: signal: make context structures registers handling portable
authorRadek Bartoň <radek.barton@microsoft.com>
Wed, 4 Jun 2025 12:55:34 +0000 (14:55 +0200)
committerCorinna Vinschen <corinna@vinschen.de>
Mon, 14 Jul 2025 13:20:05 +0000 (15:20 +0200)
commitaeea9ae363f0f73af5eb393fcc6fee2316c31f21
treef176ac0da0e2cbd2c4c1cd9530cd87b3a6447a1b
parent9653999c2f4429ab8e8867f3b33c8acc8fea787c
Cygwin: signal: make context structures registers handling portable

This patch extracts macros from winsup/cygwin/exceptions.cc serving for portable
register access to context structures into a separate local header
winsup/cygwin/local_includes/register.h and implements their AArch64
counterparts.

Then, it adds AArch64 declaration of __mcontext structure based on
mingw-w64-headers/include/winnt.h header to
winsup/cygwin/include/cygwin/singal.h header.

Then, it includes the registers.h header and uses the macros where applicable,
namely at:
 - winsup/cygwin/exceptions.cc
 - winsup/cygwin/profil.c
 - winsup/cygwin/tread.cc

The motivation is to make usage of the context structures portable without
unnecessary #if defined(__x86_64__) while implementations of signal handling
code will be developed later, e.g. implementation of makecontext.

Signed-off-by: Radek Bartoň <radek.barton@microsoft.com>
winsup/cygwin/exceptions.cc
winsup/cygwin/include/cygwin/signal.h
winsup/cygwin/local_includes/register.h [new file with mode: 0644]
winsup/cygwin/profil.c
winsup/cygwin/thread.cc
winsup/utils/profiler.cc
This page took 0.030188 seconds and 5 git commands to generate.