// File: /workspace/github_c_makefile_star2_O0/BernardTatin[P]s7sh/s7.c
// Function: check_for_substring_temp
static void check_for_substring_temp(s7_scheme *sc, s7_pointer expr)
                {
                    s7_pointer nps[NUM_STRING_WRAPPERS];
                    s7_pointer p, arg;
                    int32_t pairs = 0, substrs = 0;
                    /* a bit tricky -- accept temp only if there's just one inner expression and it calls substring
                     *   and don't use this for arg if arg is returned: (reverse! (write-string (symbol->string x)))
                     */
                    for (p = cdr(expr); is_pair(p); p = cdr(p))
                    {
                        arg = car(p);
                        if (is_pair(arg))
                        {
                            pairs++;
                            if ((is_symbol(car(arg))) &&
                                    (is_safely_optimized(arg)) &&
                                    (has_fx(arg)))
                            {
                                if (c_callee(arg) == g_substring)
                                {
                                    if (substrs < NUM_STRING_WRAPPERS)
                                        nps[substrs++] = arg;
                                }
                                else
                                {
                                    if (c_callee(arg) == g_symbol_to_string)
                                        set_c_function(arg, sc->symbol_to_string_uncopied);
                                    else
                                    {
                                        if ((c_callee(arg) == g_read_line) &&
                                                (is_pair(cdr(arg))))
                                            set_c_function(arg, sc->read_line_uncopied);
                                    }}}}}
                    if ((pairs > 0) &&
                            (pairs == substrs))
                    {
                        int32_t i;
                        for (i = 0; i < substrs; i++)
                            set_c_function(nps[i], sc->substring_to_temp);
                    }
                }

// Assembly:
movq %rdi, -0x8(%rsp)
movq %rsi, -0x10(%rsp)
movl $0x0, -0x6c(%rsp)
movl $0x0, -0x70(%rsp)
movq -0x10(%rsp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x60(%rsp)
movq -0x60(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x1, %eax
jne 0x1d9208
movq -0x60(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x68(%rsp)
movq -0x68(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x1, %eax
jne 0x1d91f3
movl -0x6c(%rsp), %eax
addl $0x1, %eax
movl %eax, -0x6c(%rsp)
movq -0x68(%rsp), %rax
movq 0x8(%rax), %rax
movzbl (%rax), %eax
cmpl $0xa, %eax
jne 0x1d91f1
movq -0x68(%rsp), %rax
movq (%rax), %rax
andq $0x800800, %rax         # imm = 0x800800
cmpq $0x800, %rax            # imm = 0x800
jne 0x1d91f1
movq -0x68(%rsp), %rax
movzwl 0x6(%rax), %eax
andl $0x4, %eax
cmpl $0x0, %eax
je 0x1d91f1
movq -0x68(%rsp), %rax
leaq -0x14c223(%rip), %rcx   # 0x8cee0
cmpq %rcx, 0x20(%rax)
jne 0x1d912e
cmpl $0x8, -0x70(%rsp)
jge 0x1d9129
movq -0x68(%rsp), %rcx
movl -0x70(%rsp), %eax
movl %eax, %edx
addl $0x1, %edx
movl %edx, -0x70(%rsp)
cltq
movq %rcx, -0x58(%rsp,%rax,8)
jmp 0x1d91ef
movq -0x68(%rsp), %rax
leaq -0x17269a(%rip), %rcx   # 0x66aa0
cmpq %rcx, 0x20(%rax)
jne 0x1d9184
jmp 0x1d9142
movq -0x8(%rsp), %rax
movq 0x1af0(%rax), %rcx
movq -0x68(%rsp), %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rsp), %rax
movq 0x1af0(%rax), %rax
movq 0x10(%rax), %rcx
movq -0x68(%rsp), %rax
movq %rcx, 0x20(%rax)
movq -0x68(%rsp), %rax
movzwl 0x6(%rax), %ecx
orl $0x4, %ecx
movw %cx, 0x6(%rax)
jmp 0x1d9182
jmp 0x1d91ed
movq -0x68(%rsp), %rax
leaq -0x16c130(%rip), %rcx   # 0x6d060
cmpq %rcx, 0x20(%rax)
jne 0x1d91eb
movq -0x68(%rsp), %rax
movq 0x10(%rax), %rax
movzbl (%rax), %eax
cmpl $0x1, %eax
jne 0x1d91eb
jmp 0x1d91a9
movq -0x8(%rsp), %rax
movq 0x1bf8(%rax), %rcx
movq -0x68(%rsp), %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rsp), %rax
movq 0x1bf8(%rax), %rax
movq 0x10(%rax), %rcx
movq -0x68(%rsp), %rax
movq %rcx, 0x20(%rax)
movq -0x68(%rsp), %rax
movzwl 0x6(%rax), %ecx
orl $0x4, %ecx
movw %cx, 0x6(%rax)
jmp 0x1d91e9
jmp 0x1d91eb
jmp 0x1d91ed
jmp 0x1d91ef
jmp 0x1d91f1
jmp 0x1d91f3
jmp 0x1d91f5
movq -0x60(%rsp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x60(%rsp)
jmp 0x1d9078
cmpl $0x0, -0x6c(%rsp)
jle 0x1d928d
movl -0x6c(%rsp), %eax
cmpl -0x70(%rsp), %eax
jne 0x1d928d
movl $0x0, -0x74(%rsp)
movl -0x74(%rsp), %eax
cmpl -0x70(%rsp), %eax
jge 0x1d928b
jmp 0x1d922d
movq -0x8(%rsp), %rax
movq 0x1ac8(%rax), %rcx
movslq -0x74(%rsp), %rax
movq -0x58(%rsp,%rax,8), %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rsp), %rax
movq 0x1ac8(%rax), %rax
movq 0x10(%rax), %rcx
movslq -0x74(%rsp), %rax
movq -0x58(%rsp,%rax,8), %rax
movq %rcx, 0x20(%rax)
movslq -0x74(%rsp), %rax
movq -0x58(%rsp,%rax,8), %rax
movzwl 0x6(%rax), %ecx
orl $0x4, %ecx
movw %cx, 0x6(%rax)
jmp 0x1d927c
jmp 0x1d927e
movl -0x74(%rsp), %eax
addl $0x1, %eax
movl %eax, -0x74(%rsp)
jmp 0x1d9221
jmp 0x1d928d
retq
nop