2
0
mirror of https://github.com/boostorg/context.git synced 2026-01-24 05:42:16 +00:00
Files
context/src
Claudio Jeker 17945a28a2 Implement the fcontext asm for sparc64
This implements the required asm functions for sparc64_sysv_elf and
was tested on an OpenBSD/sparc64 system.

Jump_fcontext uses an extra C call frame to store the frame-pointer and
return address. Because of this the code is simply a save (to new reg
window), then forcing a window flush and finally switch stack and restore
from there.

Since jump_fcontext() uses a register window and stack frame, make_fcontext()
reserves two call frames on the stack (one for jump_fcontext() and the other
for the callback function).

OpenBSD/sparc64 uses stackghost which prevents userland from overriding the
return-address on the stack. Because of this make_fcontext() uses an extra
trampoline to implement the _exit(0) call if the callback returns.

All tests pass with this on OpenBSD/sparc64 (also the tests for fiber,
coroutine and coroutine2).
2024-02-13 11:16:42 +01:00
..
2021-06-12 22:23:08 +03:00
2013-01-07 21:24:57 +00:00
2018-04-11 06:23:29 +02:00
2014-02-20 19:41:07 +01:00