// File: /workspace/github_c_makefile_star2_O3/BernardTatin[P]s7sh/s7.c
// Function: s7_dynamic_wind
s7_pointer s7_dynamic_wind(s7_scheme *sc, s7_pointer init, s7_pointer body, s7_pointer finish)
                {
                    /* this is essentially s7_call with a dynamic-wind wrapper around "body" */
                    s7_pointer p;
                    declare_jump_info();

                    sc->temp1 = ((init == sc->F) ? finish : init);
                    sc->temp2 = body;

                    store_jump_info(sc);
                    set_jump_info(sc, DYNAMIC_WIND_SET_JUMP);
                    if (jump_loc != NO_JUMP)
                    {
                        if (jump_loc != ERROR_JUMP)
                            eval(sc, sc->cur_op);
                    }
                    else
                    {
                        push_stack(sc, OP_EVAL_DONE, sc->args, sc->code);
                        sc->args = sc->nil;

                        new_cell(sc, p, T_DYNAMIC_WIND);
                        dynamic_wind_in(p) = T_Pos(init);
                        dynamic_wind_body(p) = T_Pos(body);
                        dynamic_wind_out(p) = T_Pos(finish);
                        push_stack(sc, OP_DYNAMIC_WIND, sc->nil, p);
                        if (init != sc->F)
                        {
                            dynamic_wind_state(p) = DWIND_INIT;
                            sc->code = init;
                        }
                        else
                        {
                            dynamic_wind_state(p) = DWIND_BODY;
                            sc->code = body;
                        }
                        eval(sc, OP_APPLY);
                    }
                    restore_jump_info(sc);
                    sc->temp1 = sc->nil;
                    sc->temp2 = sc->nil;

                    if (is_multiple_value(sc->value))
                        sc->value = splice_in_values(sc, multiple_value(sc->value));
                    return(sc->value);
                }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rcx, %r13
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
cmpq %rsi, 0x120(%rdi)
movq %rsi, %rax
cmoveq %rcx, %rax
movq %rax, 0x4f8(%rdi)
movq %rdx, 0x500(%rdi)
movb 0x678(%rdi), %bpl
movl 0x67c(%rdi), %eax
movl %eax, 0xc(%rsp)
leaq 0x5b0(%rdi), %r14
leaq 0x10(%rsp), %rdi
movl $0xc8, %edx
movq %r14, %rsi
callq 0x83e0
movb $0x1, 0x678(%rbx)
movl $0x3, 0x67c(%rbx)
movq %r14, %rdi
callq 0x8350
testl %eax, %eax
je 0x439ee
cmpl $0x4, %eax
jne 0x43ac2
movb %bpl, 0x678(%rbx)
movl 0xc(%rsp), %eax
movl %eax, 0x67c(%rbx)
leaq 0x10(%rsp), %rsi
movl $0xc8, %edx
movq %r14, %rdi
callq 0x83e0
testb %bpl, %bpl
je 0x43af1
movq %r14, %rdi
movl $0x4, %esi
callq 0x8530
movq (%rbx), %rax
movq 0x50(%rbx), %rcx
movq %rax, (%rcx)
movq 0x8(%rbx), %rax
movq 0x50(%rbx), %rcx
movq %rax, 0x8(%rcx)
movq 0x10(%rbx), %rax
movq 0x50(%rbx), %rcx
movq %rax, 0x10(%rcx)
movq 0x50(%rbx), %rax
movq $0x1df, 0x18(%rax)      # imm = 0x1DF
addq $0x20, 0x50(%rbx)
movq 0x90(%rbx), %rcx
movq 0x110(%rbx), %rax
movq %rax, 0x10(%rbx)
movq %rcx, %rax
cmpq 0x98(%rbx), %rcx
ja 0x43a4e
movq %rbx, %rdi
callq 0xa550
movq 0x90(%rbx), %rax
leaq -0x8(%rax), %rcx
movq %rcx, 0x90(%rbx)
movq -0x8(%rax), %rax
movq $0x1a, (%rax)
movq %r12, 0x8(%rax)
movq %r15, 0x18(%rax)
movq %r13, 0x10(%rax)
movq 0x50(%rbx), %rcx
movq %rax, (%rcx)
movq 0x8(%rbx), %rcx
movq 0x50(%rbx), %rdx
movq %rcx, 0x8(%rdx)
movq 0x50(%rbx), %rcx
movq 0x110(%rbx), %rdx
movq %rdx, 0x10(%rcx)
movq 0x50(%rbx), %rcx
movq $0x1e1, 0x18(%rcx)      # imm = 0x1E1
addq $0x20, 0x50(%rbx)
xorl %ecx, %ecx
cmpq %r12, 0x120(%rbx)
sete %dl
movb %dl, %cl
cmoveq %r15, %r12
movl %ecx, 0x20(%rax)
movq %r12, (%rbx)
movl $0x198, %esi            # imm = 0x198
jmp 0x43ac6
movq 0x18(%rbx), %rsi
movq %rbx, %rdi
callq 0xfd85
movb %bpl, 0x678(%rbx)
movl 0xc(%rsp), %eax
movl %eax, 0x67c(%rbx)
leaq 0x10(%rsp), %rsi
movl $0xc8, %edx
movq %r14, %rdi
callq 0x83e0
movq 0x20(%rbx), %rsi
movq 0x110(%rbx), %rax
movq %rax, 0x4f8(%rbx)
movq %rax, 0x500(%rbx)
cmpw $0x0, (%rsi)
js 0x43b15
movq %rsi, %rax
jmp 0x43b21
movq %rbx, %rdi
callq 0x35a2c
movq %rax, 0x20(%rbx)
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq