// File: /workspace/github_c_makefile_star2_O1/BernardTatin[P]s7sh/s7.c
// Function: op_tc_case_la
static bool op_tc_case_la(s7_scheme *sc, s7_pointer code)
                {
                    /* opt1_any(clause) = key, has_tc(arg) = is tc call, opt2_any(clause) = result: has_tc(la arg) has_fx(val) or ((...)...) */
                    s7_pointer clauses, la_slot, endp, selp;
                    s7_int len;

                    len = integer(opt3_arglen(code));
                    la_slot = let_slots(sc->envir);
                    selp = cdr(code);
                    clauses = cddr(code);

                    if (len == 3)
                    {
                        while (true)
                        {
                            s7_pointer selector, p;
                            selector = fx_call(sc, selp);
                            if (selector == opt1_any(clauses))
                                endp = opt2_any(clauses);
                            else
                            {
                                p = cdr(clauses);
                                if (selector == opt1_any(p))
                                    endp = opt2_any(p);
                                else endp = opt2_any(cdr(p));
                            }
                            if (has_tc(endp))
                                slot_set_value(la_slot, fx_call(sc, cdr(endp)));
                            else break;
                        }
                    }
                    else
                    {
                        while (true)
                        {
                            s7_pointer selector, p;
                            selector = fx_call(sc, selp);
                            for (p = clauses; is_pair(cdr(p)); p = cdr(p))
                                if (selector == opt1_any(p)) {endp = opt2_any(p); goto CASE_ALA_END;}
                            endp = opt2_any(p);
CASE_ALA_END:
                            if (has_tc(endp))
                                slot_set_value(la_slot, fx_call(sc, cdr(endp)));
                            else break;
                        }
                    }
                    if (has_fx(endp))
                    {
                        sc->value = fx_call(sc, endp);
                        return(true); /* goto START */
                    }
                    sc->code = endp;
                    return(false);    /* goto BEGIN (not like op_tc_z below) */
                }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x10(%rsi), %r14
movq 0x10(%r14), %r15
movq 0x28(%r14), %rax
movq 0x8(%rdi), %rcx
movq 0x8(%rcx), %r12
cmpq $0x3, 0x8(%rax)
jne 0xcd71a
leaq 0x20(%r15), %r13
movq 0x8(%r14), %rsi
movq %rbx, %rdi
callq *0x20(%r14)
movq %r13, %rcx
cmpq 0x18(%r15), %rax
je 0xcd6fc
movq 0x10(%r15), %rcx
cmpq 0x18(%rcx), %rax
je 0xcd6f8
movq 0x10(%rcx), %rcx
addq $0x20, %rcx
movq (%rcx), %rax
testb $0x10, 0x2(%rax)
je 0xcd759
movq 0x10(%rax), %rax
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq *0x20(%rax)
movq %rax, 0x10(%r12)
jmp 0xcd6d6
movq 0x8(%r14), %rsi
movq %rbx, %rdi
callq *0x20(%r14)
movq %r15, %rdx
movq %rdx, %rcx
movq 0x10(%rdx), %rdx
cmpb $0x1, (%rdx)
jne 0xcd73a
cmpq 0x18(%rcx), %rax
jne 0xcd728
movq 0x20(%rcx), %rax
testb $0x10, 0x2(%rax)
je 0xcd759
movq 0x10(%rax), %rax
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq *0x20(%rax)
movq %rax, 0x10(%r12)
jmp 0xcd71a
movzwl 0x6(%rax), %ebp
testb $0x4, %bpl
je 0xcd773
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq *0x20(%rax)
movq %rax, 0x20(%rbx)
jmp 0xcd776
movq %rax, (%rbx)
andl $0x4, %ebp
shrl $0x2, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq