// File: /workspace/github_c_makefile_star2_O3/johsteffens[P]beth/lib/bcore/bcore_sources.c
// Function: bcore_source_point_s_source_reference_to_sink
void bcore_source_point_s_source_reference_to_sink( const bcore_source_point_s* o, bl_t file_name_only, bcore_sink* sink )
{
    if( !o->source ) return;

    BLM_INIT();
    sz_t index = bcore_source_a_get_index( o->source );
    bcore_source_a_set_index( o->source, o->index );

    bcore_source_context_s* context = BLM_CREATE( bcore_source_context_s );
    bcore_source_a_get_context( o->source, context );

    if( context->file_path )
    {
        st_s* file = BLM_CLONE( st_s, context->file_path );
        if( file_name_only )
        {
            st_s_copy( file, BLM_A_PUSH( st_s_create_sc( bcore_file_name( file->sc ) ) ) );
        }
        bcore_sink_a_push_fa( sink, "#<sc_t>", file->sc );
    }

    bcore_sink_a_push_fa( sink, ":#<sz_t>:#<sz_t>", context->line, context->col );

    bcore_source_a_set_index( o->source, index );
    BLM_DOWN();
}

// Assembly:
cmpq $0x0, 0x8(%rdi)
je 0xe7407
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, %r14
movl %esi, 0xc(%rsp)
movq %rdx, 0x18(%rsp)
leaq 0xb4d1c(%rip), %rax     # 0x19bdd0
movq (%rax), %rsi
leaq 0x28(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0xd6675
movq 0x8(%r14), %r12
movq (%r12), %rbx
leaq 0xb5bf3(%rip), %r15     # 0x19ccc8
movl (%r15), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%r15,%rax,8), %rcx
movq 0x18(%r15,%rax,8), %rdx
andq %rbx, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %rbx, %rdx
je 0xe712b
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %rbx, %rdx
je 0xe712b
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %rbx, %rdx
je 0xe712b
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %rbx, %rdx
jne 0xe7134
movq (%rax,%rcx), %r13
testq %r13, %r13
jne 0xe715b
movabsq $-0x7e8ee9b9b4bbaa8, %rdi # imm = 0xF817116464B44558
movq %rbx, %rsi
callq 0xe9bc5
movq %rax, %r13
leaq 0xb5b78(%rip), %rdi     # 0x19ccc8
movq %rbx, %rsi
movq %rax, %rdx
callq 0x115fac
movq %r13, %rdi
movq %r12, %rsi
callq 0xffe72
movq %rax, 0x10(%rsp)
movq 0x8(%r14), %r13
movq 0x10(%r14), %rbx
movq (%r13), %r12
movl (%r15), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%r15,%rax,8), %rcx
movq 0x18(%r15,%rax,8), %rdx
andq %r12, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r12, %rdx
je 0xe71cd
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r12, %rdx
je 0xe71cd
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r12, %rdx
je 0xe71cd
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r12, %rdx
jne 0xe71d6
movq (%rax,%rcx), %rbp
testq %rbp, %rbp
jne 0xe71fd
movabsq $-0x7e8ee9b9b4bbaa8, %rdi # imm = 0xF817116464B44558
movq %r12, %rsi
callq 0xe9bc5
movq %rax, %rbp
leaq 0xb5ad6(%rip), %rdi     # 0x19ccc8
movq %r12, %rsi
movq %rax, %rdx
callq 0x115fac
movq %rbp, %rdi
movq %r13, %rsi
movq %rbx, %rdx
callq 0xffe83
xorl %eax, %eax
callq 0xff39f
leaq 0x28(%rsp), %rdi
movabsq $0x420d5f875454e1c, %rsi # imm = 0x420D5F875454E1C
movq %rax, %rdx
callq 0xd67bd
movq %rax, %r13
movq 0x8(%r14), %rbx
movq (%rbx), %r12
movl (%r15), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%r15,%rax,8), %rcx
movq 0x18(%r15,%rax,8), %rdx
andq %r12, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r12, %rdx
je 0xe7289
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r12, %rdx
je 0xe7289
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r12, %rdx
je 0xe7289
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r12, %rdx
jne 0xe7292
movq (%rax,%rcx), %rbp
testq %rbp, %rbp
jne 0xe72b9
movabsq $-0x7e8ee9b9b4bbaa8, %rdi # imm = 0xF817116464B44558
movq %r12, %rsi
callq 0xe9bc5
movq %rax, %rbp
leaq 0xb5a1a(%rip), %rdi     # 0x19ccc8
movq %r12, %rsi
movq %rax, %rdx
callq 0x115fac
movq %rbp, %rdi
movq %rbx, %rsi
movq %r13, %rdx
callq 0xffa74
movq 0x8(%r13), %rdi
testq %rdi, %rdi
movq 0x18(%rsp), %r12
je 0xe7339
callq 0x10a2da
leaq 0x28(%rsp), %rdi
movabsq $-0x503db0e6e1c2e704, %rsi # imm = 0xAFC24F191E3D18FC
movq %rax, %rdx
callq 0xd67bd
movq %rax, %rbx
cmpb $0x0, 0xc(%rsp)
je 0xe7324
movq 0x8(%rbx), %rdi
callq 0xbf4cf
movq %rax, %rdi
callq 0x109f0e
leaq 0x28(%rsp), %rdi
movq %rax, %rsi
callq 0xd6a3c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1094fa
movq 0x8(%rbx), %rdx
leaq 0x5d946(%rip), %rsi     # 0x144c75
movq %r12, %rdi
xorl %eax, %eax
callq 0xfe6d6
movq 0x18(%r13), %rdx
movq 0x20(%r13), %rcx
leaq 0x5004b(%rip), %rsi     # 0x137393
movq %r12, %rdi
xorl %eax, %eax
callq 0xfe6d6
movq 0x8(%r14), %rbx
movq (%rbx), %r14
movl (%r15), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%r15,%rax,8), %rcx
movq 0x18(%r15,%rax,8), %rdx
andq %r14, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r14, %rdx
je 0xe73af
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r14, %rdx
je 0xe73af
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r14, %rdx
je 0xe73af
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r14, %rdx
jne 0xe73b8
movq (%rax,%rcx), %r15
testq %r15, %r15
jne 0xe73df
movabsq $-0x7e8ee9b9b4bbaa8, %rdi # imm = 0xF817116464B44558
movq %r14, %rsi
callq 0xe9bc5
movq %rax, %r15
leaq 0xb58f4(%rip), %rdi     # 0x19ccc8
movq %r14, %rsi
movq %rax, %rdx
callq 0x115fac
movq %r15, %rdi
movq %rbx, %rsi
movq 0x10(%rsp), %rdx
callq 0xffe83
leaq 0x20(%rsp), %rdi
callq 0xd6d0d
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq