// File: /workspace/github_c_makefile_star2_O3/BernardTatin[P]s7sh/s7.c
// Function: subvector
static s7_pointer subvector(s7_scheme *sc, s7_pointer vect, s7_int skip_dims, s7_int index)
                {
                    s7_pointer x;
                    s7_int dims;

                    new_cell(sc, x, (typeflag(vect) & (~T_COLLECTED)) | T_SUBVECTOR | T_SAFE_PROCEDURE);
                    vector_length(x) = 0;
                    vector_block(x) = mallocate_vector(sc, 0);
                    vector_elements(x) = NULL;
                    vector_getter(x) = vector_getter(vect);
                    vector_setter(x) = vector_setter(vect);

                    dims = vector_ndims(vect) - skip_dims;
                    if (dims > 1)
                    {
                        vdims_t *v;
                        v = (vdims_t *)mallocate_block(sc);
                        vdims_rank(v) = dims;
                        vdims_dims(v) = (s7_int *)(vector_dimensions(vect) + skip_dims);
                        vdims_offsets(v) = (s7_int *)(vector_offsets(vect) + skip_dims);
                        vdims_original(v) = vect;
                        vector_elements_should_be_freed(v) = false;
                        vector_set_dimension_info(x, v);
                    }
                    else
                    {
                        vector_set_dimension_info(x, NULL);
                        subvector_set_vector(x, vect);
                    }

                    if (is_normal_vector(vect))
                        mark_function[T_VECTOR] = mark_vector_possibly_shared;
                    else mark_function[type(vect)] = mark_int_or_float_vector_possibly_shared;

                    if (skip_dims > 0)
                        vector_length(x) = vector_offset(vect, skip_dims - 1);
                    else vector_length(x) = vector_length(vect);

                    if (is_int_vector(vect))
                        int_vector_ints(x) = (s7_int *)(int_vector_ints(vect) + index);
                    else
                    {
                        if (is_float_vector(vect))
                            float_vector_floats(x) = (s7_double *)(float_vector_floats(vect) + index);
                        else
                        {
                            if (is_normal_vector(vect))
                                vector_elements(x) = (s7_pointer *)(vector_elements(vect) + index);
                            else byte_vector_bytes(x) = (uint8_t *)(byte_vector_bytes(vect) + index);
                        }
                    }
                    add_multivector(sc, x);
                    return(x);
                }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r15
movq %rdx, %r13
movq %rsi, %r12
movq %rdi, %r14
movq 0x90(%rdi), %rax
cmpq 0x98(%rdi), %rax
ja 0xd5f15
movq %r14, %rdi
callq 0xa550
movq 0x90(%r14), %rax
leaq -0x8(%rax), %rcx
movq %rcx, 0x90(%r14)
movq -0x8(%rax), %rbx
movq $-0x20220001, %rax      # imm = 0xDFDDFFFF
andq (%r12), %rax
orq $0x20200000, %rax       # imm = 0x20200000
movq %rax, (%rbx)
movq $0x0, 0x8(%rbx)
movq 0x838(%r14), %rax
testq %rax, %rax
jne 0xd5f8b
movl $0x2800, %edi           # imm = 0x2800
callq 0x8480
movq %rax, 0x838(%r14)
movq %rax, %rcx
addq $0x28, %rcx
movl $0xff, %edx
movq %rcx, -0x10(%rcx)
movl $0x0, -0x20(%rcx)
addq $0x28, %rcx
decl %edx
jne 0xd5f69
movq $0x0, -0x10(%rcx)
movl $0x0, -0x20(%rcx)
movq 0x18(%rax), %rcx
movq %rcx, 0x838(%r14)
movl $0x0, 0x8(%rax)
xorl %ecx, %ecx
movq %rcx, (%rax)
movq %rcx, 0x20(%rax)
movq %rax, 0x18(%rbx)
movq %rcx, 0x10(%rbx)
movq 0x20(%r12), %rcx
movq %rcx, 0x20(%rbx)
movq 0x28(%r12), %rcx
movq %rcx, 0x28(%rbx)
movq 0x18(%r12), %rcx
movq 0x20(%rcx), %rcx
movq 0x10(%rcx), %rbp
subq %r13, %rbp
cmpq $0x2, %rbp
jl 0xd6075
movq 0x838(%r14), %rax
testq %rax, %rax
jne 0xd6025
movl $0x2800, %edi           # imm = 0x2800
callq 0x8480
movq %rax, 0x838(%r14)
movq %rax, %rcx
addq $0x28, %rcx
movl $0xff, %edx
movq %rcx, -0x10(%rcx)
movl $0x0, -0x20(%rcx)
addq $0x28, %rcx
decl %edx
jne 0xd6003
movq $0x0, -0x10(%rcx)
movl $0x0, -0x20(%rcx)
movq 0x18(%rax), %rcx
movq %rcx, 0x838(%r14)
movl $0x0, 0x8(%rax)
movq %rbp, 0x10(%rax)
movq 0x18(%r12), %rcx
movq 0x20(%rcx), %rcx
leaq (,%r13,8), %rdx
movq (%rcx), %rcx
addq %rdx, %rcx
movq %rcx, (%rax)
movq 0x18(%r12), %rcx
movq 0x20(%rcx), %rcx
addq 0x18(%rcx), %rdx
movq %rdx, 0x18(%rax)
movq %r12, 0x20(%rax)
movb $0x0, 0xc(%rax)
movl $0x20, %ecx
jmp 0xd6085
movq $0x0, 0x20(%rax)
movl $0x18, %ecx
movq %r12, %rax
movq 0x18(%rbx), %rdx
movq %rax, (%rdx,%rcx)
movzbl (%r12), %eax
cmpq $0x15, %rax
jne 0xd60a8
leaq 0x608(%rip), %rax       # 0xd66a7
movq %rax, 0x70772(%rip)     # 0x146818
jmp 0xd60ba
leaq 0x706c1(%rip), %rcx     # 0x146770
leaq 0x634(%rip), %rdx       # 0xd66ea
movq %rdx, (%rcx,%rax,8)
testq %r13, %r13
jle 0xd60d6
movq 0x18(%r12), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %rax
leaq (%rax,%r13,8), %rax
addq $-0x8, %rax
jmp 0xd60db
leaq 0x8(%r12), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
movzbl (%r12), %ecx
movq 0x10(%r12), %rax
cmpl $0x15, %ecx
je 0xd60fb
cmpl $0x17, %ecx
je 0xd60fb
cmpl $0x16, %ecx
jne 0xd6101
leaq (%rax,%r15,8), %rax
jmp 0xd6104
addq %r15, %rax
movq %rax, 0x10(%rbx)
movq 0x790(%r14), %r14
movq (%r14), %rax
movq 0x10(%r14), %rsi
cmpq 0x8(%r14), %rsi
jne 0xd6137
leaq (%rsi,%rsi), %rcx
movq %rcx, 0x8(%r14)
shlq $0x4, %rsi
movq %rax, %rdi
callq 0x8510
movq %rax, (%r14)
movq 0x10(%r14), %rsi
leaq 0x1(%rsi), %rcx
movq %rcx, 0x10(%r14)
movq %rbx, (%rax,%rsi,8)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq