// File: /workspace/github_c_makefile_star2_O3/johsteffens[P]beth/lib/bcore/bcore_spect_array.c
// Function: set_dyn_solid_typed
static void set_dyn_solid_typed( const bcore_array_s* p, vd_t o, uz_t index, sr_s src )
{
    bcore_array_dyn_solid_typed_s* arr = obj_vd( p, o );
    if( arr->type == 0 ) arr->type = sr_s_type( &src );
    if( index >= arr->size ) bcore_array_p_set_size( p, o, index + 1 );
    if( src.o )
    {
        if( sr_s_type( &src ) == arr->type )
        {
            const bcore_inst_s* inst_p = sr_s_get_spect( TYPEOF_bcore_inst_s, &src );
            vd_t dst = ( u0_t* )arr->data + inst_p->size * index;
            bcore_inst_p_copy( inst_p, dst, src.o );
        }
        else
        {
            const bcore_inst_s* inst_p = bcore_inst_s_get_typed( arr->type );
            vd_t dst = ( u0_t* )arr->data + inst_p->size * index;
            bcore_inst_p_copy_typed( inst_p, dst, sr_s_type( &src ), src.o );
        }
    }
    sr_down( src );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x40(%rsp), %r13
movq 0x20(%rdi), %rbp
cmpq $0x0, 0x18(%rsi,%rbp)
jne 0xf1a31
movq 0x8(%r13), %rax
testq %rax, %rax
je 0xf1a2a
movq 0x8(%rax), %rax
jmp 0xf1a2c
xorl %eax, %eax
movq %rax, 0x18(%r14,%rbp)
cmpq %rbx, 0x8(%r14,%rbp)
ja 0xf1a44
leaq 0x1(%rbx), %rdx
movq %r14, %rsi
callq 0xec548
movq (%r13), %r12
testq %r12, %r12
je 0xf1b90
movq 0x8(%r13), %rdi
testq %rdi, %rdi
je 0xf1a8b
movq 0x8(%rdi), %rsi
movq 0x18(%r14,%rbp), %r15
cmpq %r15, %rsi
jne 0xf1a99
movabsq $0x782b96602f424981, %rax # imm = 0x782B96602F424981
cmpq %rax, (%rdi)
je 0xf1b76
movq %rax, %rdi
callq 0xe9bc5
movq %rax, %rdi
jmp 0xf1b76
movq 0x18(%r14,%rbp), %r15
testq %r15, %r15
je 0xf1b74
leaq 0xaa9c8(%rip), %rax     # 0x19c468
movl (%rax), %ecx
movslq %ecx, %rcx
leaq (%rcx,%rcx,2), %rcx
movq 0x20(%rax,%rcx,8), %rdx
movq 0x18(%rax,%rcx,8), %rcx
andq %r15, %rcx
shlq $0x4, %rcx
leaq (%rdx,%rcx), %rax
movq (%rdx,%rcx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0xf1af6
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0xf1af6
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0xf1af6
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0xf1aff
movq (%rax,%rcx), %r12
testq %r12, %r12
jne 0xf1b26
movabsq $0x782b96602f424981, %rdi # imm = 0x782B96602F424981
movq %r15, %rsi
callq 0xe9bc5
movq %rax, %r12
leaq 0xaa94d(%rip), %rdi     # 0x19c468
movq %r15, %rsi
movq %rax, %rdx
callq 0x115fac
imulq 0x18(%r12), %rbx
addq (%r14,%rbp), %rbx
movq 0x8(%r13), %rax
testq %rax, %rax
je 0xf1b3f
movq 0x8(%rax), %rdx
jmp 0xf1b41
xorl %edx, %edx
movq (%r13), %rcx
cmpq %rcx, %rbx
je 0xf1b90
cmpq %rdx, 0x8(%r12)
jne 0xf1b64
movq %r12, %rdi
movq %rbx, %rsi
movq %rcx, %rdx
callq *0x90(%r12)
jmp 0xf1b90
movq %r12, %rdi
movq %rbx, %rsi
callq *0x98(%r12)
jmp 0xf1b90
xorl %edi, %edi
imulq 0x18(%rdi), %rbx
addq (%r14,%rbp), %rbx
cmpq %r12, %rbx
je 0xf1b90
movq %rbx, %rsi
movq %r12, %rdx
callq *0x90(%rdi)
testb $0x2, 0x10(%r13)
jne 0xf1ba6
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x107590