mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
coroutine/arm32/Context.S: save/restore the registers via stack
Retry of518adcca0a
anddbe232e24e
This commit is contained in:
parent
51361272f9
commit
6df1814c08
3 changed files with 8 additions and 4 deletions
|
@ -2272,6 +2272,9 @@ AS_CASE(["$rb_cv_fiber_coroutine"], [yes|''], [
|
||||||
[x64-mingw32], [
|
[x64-mingw32], [
|
||||||
rb_cv_fiber_coroutine=win64
|
rb_cv_fiber_coroutine=win64
|
||||||
],
|
],
|
||||||
|
[armv7*-linux-*], [
|
||||||
|
rb_cv_fiber_coroutine=arm32
|
||||||
|
],
|
||||||
[aarch64-linux], [
|
[aarch64-linux], [
|
||||||
rb_cv_fiber_coroutine=arm64
|
rb_cv_fiber_coroutine=arm64
|
||||||
],
|
],
|
||||||
|
|
|
@ -9,6 +9,7 @@
|
||||||
|
|
||||||
.globl coroutine_transfer
|
.globl coroutine_transfer
|
||||||
coroutine_transfer:
|
coroutine_transfer:
|
||||||
stmia r1!, {r4-r11,sp,lr}
|
push {r4-r11,lr}
|
||||||
ldmia r0!, {r4-r11,sp,pc}
|
str sp, [r0]
|
||||||
bx lr
|
ldr sp, [r1]
|
||||||
|
pop {r4-r11,pc}
|
||||||
|
|
|
@ -16,7 +16,7 @@ extern "C" {
|
||||||
|
|
||||||
#define COROUTINE __attribute__((noreturn)) void
|
#define COROUTINE __attribute__((noreturn)) void
|
||||||
|
|
||||||
enum {COROUTINE_REGISTERS = 9};
|
enum {COROUTINE_REGISTERS = 8};
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue