// File: /workspace/github_c_makefile_star2_O0/BernardTatin[P]s7sh/s7.c
// Function: g_bv_set_3
static s7_pointer g_bv_set_3(s7_scheme *sc, s7_pointer args)
                {
                    s7_pointer v, index, value;
                    s7_int ind, uval;
                    v = car(args);
                    if (!is_byte_vector(v))
                        return(method_or_bust(sc, v, sc->byte_vector_set_symbol, args, T_BYTE_VECTOR, 1));
                    if (vector_rank(v) != 1)
                        return(univect_set(sc, args, sc->byte_vector_set_symbol, T_BYTE_VECTOR));
                    index = cadr(args);
                    if (!s7_is_integer(index))
                        return(method_or_bust(sc, index, sc->byte_vector_set_symbol, args, T_INTEGER, 2));
                    ind = s7_integer(index);
                    if ((ind < 0) || (ind >= vector_length(v)))
                        return(simple_out_of_range(sc, sc->byte_vector_set_symbol, index, (ind < 0) ? its_negative_string : its_too_large_string));
                    value = caddr(args);
                    if (!s7_is_integer(value))
                        return(method_or_bust(sc, value, sc->byte_vector_set_symbol, args, T_INTEGER, 3));
                    if ((ind < 0) || (ind >= vector_length(v)))
                        return(simple_out_of_range(sc, sc->byte_vector_set_symbol, index, (ind < 0) ? its_negative_string : its_too_large_string));
                    uval = s7_integer(value);
                    if ((uval < 0) || (uval > 255))
                        simple_wrong_type_argument_with_type(sc, sc->byte_vector_set_symbol, value, an_unsigned_byte_string);
                    if (is_immutable_vector(v))
                        return(immutable_object_error(sc, set_elist_3(sc, immutable_error_string, sc->byte_vector_set_symbol, v)));
                    byte_vector(v, ind) = (uint8_t)uval;
                    return(value);
                }

// Assembly:
subq $0x98, %rsp
movq %rdi, 0x88(%rsp)
movq %rsi, 0x80(%rsp)
movq 0x80(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x78(%rsp)
movq 0x78(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x18, %eax
je 0x1d63b7
movq 0x88(%rsp), %rdi
movq 0x78(%rsp), %rsi
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rdx
movq 0x80(%rsp), %rcx
movl $0x18, %r8d
movl $0x1, %r9d
callq 0x13c50
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x78(%rsp), %rax
movq 0x18(%rax), %rax
cmpq $0x0, 0x20(%rax)
je 0x1d63df
movq 0x78(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, 0x50(%rsp)
jmp 0x1d63eb
movl $0x1, %eax
movq %rax, 0x50(%rsp)
jmp 0x1d63eb
movq 0x50(%rsp), %rax
cmpq $0x1, %rax
je 0x1d642c
movq 0x88(%rsp), %rdi
movq 0x80(%rsp), %rsi
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rdx
movl $0x18, %ecx
callq 0x1cca10
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x80(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, 0x70(%rsp)
movq 0x70(%rsp), %rdi
callq 0x11340
testb $0x1, %al
jne 0x1d6491
movq 0x88(%rsp), %rdi
movq 0x70(%rsp), %rsi
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rdx
movq 0x80(%rsp), %rcx
movl $0xb, %r8d
movl $0x2, %r9d
callq 0x13c50
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x70(%rsp), %rdi
callq 0x10790
movq %rax, 0x60(%rsp)
cmpq $0x0, 0x60(%rsp)
jl 0x1d64b8
movq 0x60(%rsp), %rax
movq 0x78(%rsp), %rcx
cmpq 0x8(%rcx), %rax
jl 0x1d652f
movq 0x88(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, 0x40(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x48(%rsp)
cmpq $0x0, 0x60(%rsp)
jge 0x1d64fd
movq 0x44082(%rip), %rax     # 0x21a578
movq %rax, 0x30(%rsp)
jmp 0x1d6509
movq 0x4406c(%rip), %rax     # 0x21a570
movq %rax, 0x30(%rsp)
movq 0x48(%rsp), %rdx
movq 0x40(%rsp), %rsi
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rcx
callq 0x45240
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x80(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, 0x68(%rsp)
movq 0x68(%rsp), %rdi
callq 0x11340
testb $0x1, %al
jne 0x1d6598
movq 0x88(%rsp), %rdi
movq 0x68(%rsp), %rsi
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rdx
movq 0x80(%rsp), %rcx
movl $0xb, %r8d
movl $0x3, %r9d
callq 0x13c50
movq %rax, 0x90(%rsp)
jmp 0x1d6709
cmpq $0x0, 0x60(%rsp)
jl 0x1d65b0
movq 0x60(%rsp), %rax
movq 0x78(%rsp), %rcx
cmpq 0x8(%rcx), %rax
jl 0x1d6627
movq 0x88(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, 0x20(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x60(%rsp)
jge 0x1d65f5
movq 0x43f8a(%rip), %rax     # 0x21a578
movq %rax, 0x10(%rsp)
jmp 0x1d6601
movq 0x43f74(%rip), %rax     # 0x21a570
movq %rax, 0x10(%rsp)
movq 0x28(%rsp), %rdx
movq 0x20(%rsp), %rsi
movq 0x18(%rsp), %rdi
movq 0x10(%rsp), %rcx
callq 0x45240
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x68(%rsp), %rdi
callq 0x10790
movq %rax, 0x58(%rsp)
cmpq $0x0, 0x58(%rsp)
jl 0x1d6649
cmpq $0xff, 0x58(%rsp)
jle 0x1d6684
movq 0x88(%rsp), %rdi
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rax
movq 0x8(%rax), %rsi
movq 0x68(%rsp), %rdx
movq 0x88(%rsp), %rax
movq 0x140(%rax), %rcx
movq 0x4c531(%rip), %r8      # 0x222bb0
callq 0x14a60
movq 0x78(%rsp), %rax
movq (%rax), %rax
andq $0x1000000, %rax        # imm = 0x1000000
cmpq $0x0, %rax
je 0x1d66e4
movq 0x88(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x88(%rsp), %rdi
movq 0x43de4(%rip), %rsi     # 0x21a498
movq 0x88(%rsp), %rax
movq 0xc38(%rax), %rdx
movq 0x78(%rsp), %rcx
callq 0xf240
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0xb800
movq %rax, 0x90(%rsp)
jmp 0x1d6709
movq 0x58(%rsp), %rax
movb %al, %dl
movq 0x78(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x60(%rsp), %rcx
movb %dl, (%rax,%rcx)
movq 0x68(%rsp), %rax
movq %rax, 0x90(%rsp)
movq 0x90(%rsp), %rax
addq $0x98, %rsp
retq
nopl (%rax)