// File: /workspace/github_c_makefile_star2_O1/johsteffens[P]beth/lib/bcore/bcore_name_manager.c
// Function: bcore_name_check_collision_sn
er_t bcore_name_check_collision_sn( tp_t name_space, sc_t name, uz_t n )
{
    assert( hmap_s_g != NULL );
    tp_t key = bcore_name_key_ns_n( name_space, name, n );
    if( key == 0 )
    {
        return bcore_error_push_fa( TYPEOF_general_error, "Hash of '#<sc_t>' is zero. Zero is a reserved value.", cat_name_ns_n( name_space, name, n )->sc );
    }

    bcore_mutex_s_lock( &hmap_s_g->mutex );
    bcore_name_s* node = bcore_name_map_s_get( &hmap_s_g->map, key );
    bcore_mutex_s_unlock( &hmap_s_g->mutex );

    if( node )
    {
        if( node->name_space != name_space || ( bcore_strcmp_n( name, n, node->name, bcore_strlen( node->name ) ) != 0 ) )
        {
            return bcore_error_push_fa( TYPEOF_general_error, "'#<sc_t>' collides with '#<sc_t>' at key value '#<tp_t>'", cat_name_ns_n( name_space, name, n )->sc, cat_name_ns( node->name_space, node->name )->sc, key );
        }
    }
    else
    {
        if( name_space && !bcore_name_map_s_exists( &hmap_s_g->map, name_space ) )
        {
            return bcore_error_push_fa( TYPEOF_general_error, "Namespace '#<tp_t>' not found", name_space );
        }
    }
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
testq %rdi, %rdi
je 0xe0e42
movabsq $0x100000001b3, %rax    # imm = 0x100000001B3
movq %rbx, %rcx
xorq $0x3a, %rcx
imulq %rax, %rcx
testq %r14, %r14
je 0xe0e76
xorl %edx, %edx
movzbl (%r15,%rdx), %r12d
xorq %rcx, %r12
imulq %rax, %r12
incq %rdx
movq %r12, %rcx
cmpq %rdx, %r14
jne 0xe0e29
jmp 0xe0e7e
movabsq $-0x340d631b7bdddcdb, %rdx # imm = 0xCBF29CE484222325
testq %r14, %r14
je 0xe0e7b
movabsq $0x100000001b3, %rax    # imm = 0x100000001B3
xorl %ecx, %ecx
movzbl (%r15,%rcx), %r12d
xorq %rdx, %r12
imulq %rax, %r12
incq %rcx
movq %r12, %rdx
cmpq %rcx, %r14
jne 0xe0e5d
jmp 0xe0e7e
movq %rcx, %r12
jmp 0xe0e7e
movq %rdx, %r12
testq %r12, %r12
je 0xe0f4d
movq 0xc7f4a(%rip), %rdi     # 0x1a8dd8
addq $0x30, %rdi
callq 0x11f515
movq 0xc7f3a(%rip), %rdi     # 0x1a8dd8
movq %r12, %rsi
callq 0x1370e2
movq %rax, %r13
movq 0xc7f28(%rip), %rdi     # 0x1a8dd8
addq $0x30, %rdi
callq 0x11f547
testq %r13, %r13
je 0xe0f85
cmpq %rbx, 0x8(%r13)
jne 0xe0eed
movq 0x10(%r13), %rbp
movq %rbp, %rdi
callq 0xc84d7
movq %r15, %rdi
movq %r14, %rsi
movq %rbp, %rdx
movq %rax, %rcx
callq 0xc84d2
testl %eax, %eax
je 0xe0f9d
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0xe0c2c
movq 0x8(%rax), %rbx
movq 0x8(%r13), %r14
movq 0x10(%r13), %r15
movq %r15, %rdi
callq 0xc84d7
movq %r14, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xe0c2c
movq 0x8(%rax), %rcx
leaq 0x70da6(%rip), %rsi     # 0x151cce
movabsq $0x4d9e984c5b21faea, %rdi # imm = 0x4D9E984C5B21FAEA
movq %rbx, %rdx
movq %r12, %r8
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xc87b0
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0xe0c2c
movq 0x8(%rax), %rdx
leaq 0x70d33(%rip), %rsi     # 0x151c99
movabsq $0x4d9e984c5b21faea, %rdi # imm = 0x4D9E984C5B21FAEA
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xc87b0
testq %rbx, %rbx
je 0xe0f9d
movq 0xc7e47(%rip), %rdi     # 0x1a8dd8
movq %rbx, %rsi
callq 0x13712b
testb %al, %al
je 0xe0fae
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x70d52(%rip), %rsi     # 0x151d07
movabsq $0x4d9e984c5b21faea, %rdi # imm = 0x4D9E984C5B21FAEA
movq %rbx, %rdx
jmp 0xe0f70