// File: /workspace/github_c_makefile_star2_O1/johsteffens[P]beth/xoico/src/xoico.xo.c
// Function: xoico_source_s_parse
er_t xoico_source_s_parse( xoico_source_s* o, const xoico_host* host, x_source* source, sc_t group_name, sc_t trait_name, tp_t embed_method )
{
    // xoico_source.x:227:1
    BLM_INIT_LEVEL(0);
    xoico_compiler_s* compiler = o->target->compiler;
    
    if( embed_method == TYPEOF_as_header )
    {
        while( !x_source_eos(source) )
        {
            if( x_source_parse_bl(source," #?w'XOILA_DEFINE_GROUP'" ) )
            {BLM_INIT_LEVEL(3);
                st_s st_trait_name;BLM_T_INIT_SPUSH(st_s, &st_trait_name);;
                st_s st_group_name;BLM_T_INIT_SPUSH(st_s, &st_group_name);;
                BLM_TRY(x_source_parse_fa(source," ( #name , #name", (&(st_group_name)), (&(st_trait_name)) ))
                xoico_group_s* group = NULL;
                BLM_TRY(xoico_source_s_get_group_if_preexsting(o,host, source, st_group_name.sc, st_trait_name.sc, (&(group)) ))
                if( !group )
                {
                    group = xoico_source_s_push_d(o,xoico_group_s_create() );
                    group->xoico_source = o;
                    group->compiler = compiler;
                    xoico_group_s_set_name_sc(group,host, st_group_name.sc );
                    group->trait_name = xoico_compiler_s_entypeof(compiler,st_trait_name.sc );
                }
    
                if( x_source_parse_bl(source," #=?','" ) )
                {
                    while( x_source_parse_bl(source," #?','" ) )
                    {BLM_INIT_LEVEL(5);
                        st_s* embed_file = ((st_s*)BLM_LEVEL_T_PUSH(5,st_s,st_s_create()));
                        BLM_TRY(x_source_parse_fa(source," #string", embed_file ))
                        x_source* embed_source = NULL;
                        BLM_TRY(xoico_embed_file_open(source, embed_file->sc, (&(embed_source)) ))
                        ((x_source*)BLM_LEVEL_A_PUSH(0,embed_source));
                        bcore_arr_st_s_push_st(&(group->explicit_embeddings),embed_file );
                        BLM_TRY(xoico_group_s_parse(group,((const xoico_host*)(o)), false, embed_source ))
                    BLM_DOWN();}
                    BLM_TRY(x_source_parse_fa(source," )" ))
                }
                else
                {
                    BLM_TRY(x_source_parse_fa(source," )" ))
                    BLM_TRY(xoico_group_s_parse(group,((const xoico_host*)(o)), false, source ))
                }
                BLM_TRY(xoico_compiler_s_register_group(o->target->compiler,group ))
            BLM_DOWN();}
            else
            {
                x_source_get_u0(source);
            }
        }
    }
    else
    {
        xoico_group_s* group = NULL;
    
        BLM_TRY(xoico_source_s_get_group_if_preexsting(o,host, source, group_name, trait_name, (&(group)) ))
        if( group )
        {
            if( group->xoico_source != o )
            {BLM_INIT_LEVEL(3);
                bcore_arr_st_s_push_st(&(group->explicit_embeddings),((st_s*)BLM_LEVEL_T_PUSH(3,st_s,st_s_create_fa("#<sc_t>.#<sc_t>", o->name.sc, o->ext.sc ))) );
            BLM_DOWN();}
        }
        else
        {
            group = xoico_source_s_push_d(o,xoico_group_s_create() );
            group->xoico_source = o;
            group->compiler = compiler;
            xoico_group_s_set_name_sc(group,host, group_name );
            group->trait_name = xoico_compiler_s_entypeof(compiler,trait_name );
            group->is_manifesto = true;
        }
    
        if( embed_method == TYPEOF_as_group )
        {
            BLM_TRY(xoico_group_s_parse(group,((const xoico_host*)(o)), false, source ))
        }
        else
        {
            BLM_TRY(xoico_group_s_parse_embed(group,((const xoico_host*)(o)), source, embed_method ))
        }
    
        BLM_TRY(xoico_compiler_s_register_group(compiler,group ))
    }
    
    BLM_RETURNV(er_t, 0)
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x128, %rsp            # imm = 0x128
movq %r9, %r15
movq %r8, 0x38(%rsp)
movq %rcx, %rbp
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r12
leaq 0x17a793(%rip), %rax    # 0x1a8dd0
movq (%rax), %rsi
leaq 0x58(%rsp), %r13
movq %r13, %rdi
callq 0xe0431
movq $0x0, 0x10(%r13)
movq 0x90(%r12), %rax
movq 0x138(%rax), %rcx
movabsq $-0x9b90fe183067569, %rax # imm = 0xF646F01E7CF98A97
movq %r15, 0x50(%rsp)
cmpq %rax, %r15
movq %rbx, 0x40(%rsp)
movq %rcx, 0x30(%rsp)
jne 0x2ed46
movq %r12, 0x18(%rsp)
movabsq $-0x7e8ee9b9b4bbaa8, %rbp # imm = 0xF817116464B44558
leaq 0x140(%rcx), %rax
movq %rax, 0x38(%rsp)
leaq 0x17b620(%rip), %rbx    # 0x1a9cc8
movq (%r14), %r15
movl (%rbx), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%rbx,%rax,8), %rcx
movq 0x18(%rbx,%rax,8), %rdx
andq %r15, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0x2e704
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0x2e704
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0x2e704
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0x2e88a
movq (%rax,%rcx), %r12
testq %r12, %r12
jne 0x2e729
movq %rbp, %rdi
movq %r15, %rsi
callq 0xf3f85
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x12128c
cmpq $0x0, 0x40(%r12)
jne 0x2e740
movq %r12, %rdi
leaq 0x1167d6(%rip), %rsi    # 0x144f11
callq 0xf592c
movq %r14, %rdi
callq *0x40(%r12)
testb %al, %al
jne 0x2eee1
movq (%r14), %r15
movl (%rbx), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%rbx,%rax,8), %rcx
movq 0x18(%rbx,%rax,8), %rdx
andq %r15, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0x2e7ac
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0x2e7ac
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0x2e7ac
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0x2e892
movq (%rax,%rcx), %r12
testq %r12, %r12
jne 0x2e7d1
movq %rbp, %rdi
movq %r15, %rsi
callq 0xf3f85
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x12128c
movq %r12, %rdi
movq %r14, %rsi
leaq 0x10bb49(%rip), %rdx    # 0x13a327
callq 0x10aa16
testb %al, %al
jne 0x2e89f
movq (%r14), %r15
movl (%rbx), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%rbx,%rax,8), %rcx
movq 0x18(%rbx,%rax,8), %rdx
andq %r15, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0x2e843
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0x2e843
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0x2e843
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0x2e89a
movq (%rax,%rcx), %r12
testq %r12, %r12
jne 0x2e868
movq %rbp, %rdi
movq %r15, %rsi
callq 0xf3f85
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x12128c
movb $0x0, 0xf8(%rsp)
movl $0x1, %edx
movq %r14, %rdi
leaq 0xf8(%rsp), %rsi
callq *0x10(%r12)
jmp 0x2e6a8
xorl %r12d, %r12d
jmp 0x2e708
xorl %r12d, %r12d
jmp 0x2e7b0
xorl %r12d, %r12d
jmp 0x2e847
leaq 0xf8(%rsp), %rdi
movq %rdi, 0x10(%rsp)
leaq 0x58(%rsp), %rsi
callq 0xe0431
movq 0x10(%rsp), %r15
movq $0x3, 0x10(%r15)
movq %r13, 0x8(%rsp)
leaq 0xb8(%rsp), %r13
movq %r13, %rdi
callq 0x113f7c
movq %r15, %rdi
movabsq $-0x503db0e6e1c2e704, %r12 # imm = 0xAFC24F191E3D18FC
movq %r12, %rsi
movq %r13, %rdx
callq 0xe06ab
leaq 0xd8(%rsp), %rbp
movq %rbp, %rdi
callq 0x113f7c
movq %r15, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0xe06ab
movq %r14, %rdi
leaq 0x10ba28(%rip), %rsi    # 0x13a340
movq %rbp, %rdx
movq %r13, %rcx
movq 0x8(%rsp), %r13
xorl %eax, %eax
callq 0xda10
movq %rax, %r15
testq %rax, %rax
movq 0x40(%rsp), %r12
je 0x2e944
movq 0x10(%rsp), %rdi
callq 0xe0b30
movq %r15, %r13
testq %r15, %r15
je 0x2e957
xorl %eax, %eax
movabsq $-0x7e8ee9b9b4bbaa8, %rbp # imm = 0xF817116464B44558
jmp 0x2e9ab
movq $0x0, 0x20(%rsp)
movq 0xe0(%rsp), %rcx
movq 0xc0(%rsp), %r8
movq 0x18(%rsp), %rdi
movq %r12, %rsi
movq %r14, %rdx
leaq 0x20(%rsp), %r9
callq 0x26884
movq %rax, %r15
testq %rax, %rax
movabsq $-0x7e8ee9b9b4bbaa8, %rbp # imm = 0xF817116464B44558
je 0x2e9a4
movq 0x10(%rsp), %rdi
callq 0xe0b30
movq %r15, %r13
testq %r15, %r15
je 0x2e9b8
xorl %eax, %eax
testb %al, %al
jne 0x2e6a8
jmp 0x2eeee
cmpq $0x0, 0x20(%rsp)
jne 0x2ea22
callq 0x2117b
movq 0x18(%rsp), %r12
movq (%r12), %rsi
movq %r12, %rdi
movq %rax, %rdx
callq 0x5b3a7
movq %rax, %r15
movq %rax, 0x20(%rsp)
movq %r12, 0x138(%rax)
movq 0x30(%rsp), %rax
movq %rax, 0x140(%r15)
movq 0xe0(%rsp), %rdx
movq %r15, %rdi
movq 0x40(%rsp), %rsi
callq 0x213b0
movq 0xc0(%rsp), %rsi
movq 0x38(%rsp), %rdi
callq 0xddb52
movq %rax, 0xb0(%r15)
movq (%r14), %r15
movl (%rbx), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%rbx,%rax,8), %rcx
movq 0x18(%rbx,%rax,8), %rdx
andq %r15, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0x2ea7e
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0x2ea7e
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0x2ea7e
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0x2ed3e
movq (%rax,%rcx), %r12
testq %r12, %r12
jne 0x2eaa3
movq %rbp, %rdi
movq %r15, %rsi
callq 0xf3f85
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x12128c
movq %r12, %rdi
movq %r14, %rsi
leaq 0x10b8a1(%rip), %rdx    # 0x13a351
callq 0x10aa16
testb %al, %al
je 0x2ec8f
movq (%r14), %r15
movl (%rbx), %eax
cltq
leaq (%rax,%rax,2), %rax
movq 0x20(%rbx,%rax,8), %rcx
movq 0x18(%rbx,%rax,8), %rdx
andq %r15, %rdx
shlq $0x4, %rdx
leaq (%rcx,%rdx), %rax
movq (%rcx,%rdx), %rdx
movl $0x8, %ecx
cmpq %r15, %rdx
je 0x2eb19
movq 0x10(%rax), %rdx
movl $0x18, %ecx
cmpq %r15, %rdx
je 0x2eb19
movq 0x20(%rax), %rdx
movl $0x28, %ecx
cmpq %r15, %rdx
je 0x2eb19
movq 0x30(%rax), %rdx
movl $0x38, %ecx
cmpq %r15, %rdx
jne 0x2ec79
movq (%rax,%rcx), %r12
movq %r13, 0x8(%rsp)
testq %r12, %r12
jne 0x2eb43
movq %rbp, %rdi
movq %r15, %rsi
callq 0xf3f85
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x12128c
movq %r12, %rdi
movq %r14, %rsi
leaq 0x10b809(%rip), %rdx    # 0x13a359
callq 0x10aa16
testb %al, %al
je 0x2ecdc
movq 0x10(%rsp), %rsi
leaq 0x88(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0xe0431
movq 0x28(%rsp), %r12
movq $0x5, 0x10(%r12)
xorl %eax, %eax
callq 0x114bbb
movl $0x5, %esi
movq %r12, %rdi
movabsq $-0x503db0e6e1c2e704, %rdx # imm = 0xAFC24F191E3D18FC
movq %rax, %rcx
callq 0xe0676
movq %rax, %r15
movq %r14, %rdi
leaq 0x10a6ab(%rip), %rsi    # 0x13925b
movq %rax, %rdx
xorl %eax, %eax
callq 0xda10
movq %rax, %r13
testq %rax, %rax
je 0x2ebd1
movq 0x28(%rsp), %rdi
callq 0xe0b30
movq %r13, 0x8(%rsp)
testq %r13, %r13
jne 0x2ec0c
movq $0x0, 0x48(%rsp)
movq 0x8(%r15), %rsi
movq %r14, %rdi
leaq 0x48(%rsp), %rdx
callq 0xdb5d
movq %rax, %r13
testq %rax, %rax
je 0x2ec07
movq 0x28(%rsp), %rdi
callq 0xe0b30
movq %r13, 0x8(%rsp)
testq %r13, %r13
je 0x2ec20
xorl %eax, %eax
movq 0x8(%rsp), %r13
testb %al, %al
jne 0x2eabd
jmp 0x2e9a9
movq 0x48(%rsp), %r13
movq %r12, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0xe0900
movq 0x20(%rsp), %r12
leaq 0x68(%r12), %rdi
movq %r15, %rsi
callq 0xc38cb
movq %r12, %rdi
movq 0x18(%rsp), %rsi
xorl %edx, %edx
movq %r13, %rcx
callq 0x22898
movq %rax, %r15
testq %rax, %rax
movq 0x8(%rsp), %r13
je 0x2ec70
movq 0x28(%rsp), %rdi
callq 0xe0b30
movq %r15, %r13
testq %r15, %r15
je 0x2ec81
xorl %eax, %eax
jmp 0x2ec13
xorl %r12d, %r12d
jmp 0x2eb1d
leaq 0x28(%rsp), %rdi
callq 0xe0b11
movb $0x1, %al
jmp 0x2ec13
movq %r14, %rdi
leaq 0x1272a3(%rip), %rsi    # 0x155f3c
xorl %eax, %eax
callq 0xda10
movq %rax, %r15
testq %rax, %rax
je 0x2ecb5
movq 0x10(%rsp), %rdi
callq 0xe0b30
movq %r15, %r13
testq %r15, %r15
jne 0x2e9a9
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
xorl %edx, %edx
movq %r14, %rcx
callq 0x22898
movq %rax, %r15
testq %rax, %rax
jne 0x2ecfa
jmp 0x2ed07
movq %r14, %rdi
leaq 0x127256(%rip), %rsi    # 0x155f3c
xorl %eax, %eax
callq 0xda10
movq %rax, %r15
testq %rax, %rax
movq 0x8(%rsp), %r13
je 0x2ed07
movq 0x10(%rsp), %rdi
callq 0xe0b30
movq %r15, %r13
testq %r15, %r15
jne 0x2e9a9
movq 0x18(%rsp), %rax
movq 0x90(%rax), %rax
movq 0x138(%rax), %rdi
movq 0x20(%rsp), %rsi
callq 0x26c3a
leaq 0x10(%rsp), %rdi
callq 0xe0b11
movb $0x1, %al
jmp 0x2e9ab
xorl %r12d, %r12d
jmp 0x2ea82
leaq 0x88(%rsp), %r9
movq $0x0, (%r9)
movq %r12, %r15
movq %r12, %rdi
movq %rbx, %rsi
movq %r14, %rdx
movq %rbp, %rcx
movq 0x38(%rsp), %r12
movq %r12, %r8
callq 0x26884
movq %rax, %r13
testq %rax, %rax
je 0x2ed88
leaq 0x58(%rsp), %rdi
callq 0xe0b30
jmp 0x2eedb
movq %rbp, %rbx
movq %r15, %rbp
movq %r13, 0x8(%rsp)
movq 0x88(%rsp), %r13
testq %r13, %r13
je 0x2ee1f
cmpq %rbp, 0x138(%r13)
je 0x2ee89
leaq 0xf8(%rsp), %rdi
leaq 0xb8(%rsp), %r15
movq %rdi, (%r15)
leaq 0x58(%rsp), %rsi
callq 0xe0431
movq (%r15), %r12
movq $0x3, 0x10(%r12)
addq $0x68, %r13
movq 0x30(%rbp), %rsi
movq 0x50(%rbp), %rdx
leaq 0x10c25f(%rip), %rdi    # 0x13b048
xorl %eax, %eax
callq 0x114d03
movabsq $-0x503db0e6e1c2e704, %rdx # imm = 0xAFC24F191E3D18FC
movl $0x3, %esi
movq %r12, %rdi
movq %rax, %rcx
callq 0xe0676
movq %r13, %rdi
movq %rax, %rsi
callq 0xc38cb
movq %r15, %rdi
callq 0xe0b11
jmp 0x2ee89
callq 0x2117b
movq (%rbp), %rsi
movq %rbp, %rdi
movq %rax, %rdx
callq 0x5b3a7
movq %rax, %r13
movq %rax, 0x88(%rsp)
movq %rbp, 0x138(%rax)
movq %rbp, 0x18(%rsp)
movq 0x30(%rsp), %rbp
movq %rbp, 0x140(%rax)
movq %rax, %rdi
movq 0x40(%rsp), %rsi
movq %rbx, %rdx
callq 0x213b0
leaq 0x140(%rbp), %rdi
movq 0x18(%rsp), %rbp
movq %r12, %rsi
callq 0xddb52
movq %rax, 0xb0(%r13)
movb $0x1, 0xc9(%r13)
movabsq $0x56176620137ff69, %rax # imm = 0x56176620137FF69
movq 0x88(%rsp), %rdi
movq 0x50(%rsp), %rcx
movq %rbp, %rsi
cmpq %rax, %rcx
jne 0x2eeb4
xorl %edx, %edx
movq %r14, %rcx
callq 0x22898
jmp 0x2eebc
movq %r14, %rdx
callq 0x26c77
movq %rax, %rbx
testq %rax, %rax
movq 0x8(%rsp), %r13
je 0x2eed6
leaq 0x58(%rsp), %rdi
callq 0xe0b30
movq %rbx, %r13
testq %rbx, %rbx
je 0x2ef03
xorl %eax, %eax
testb %al, %al
je 0x2eeee
leaq 0x58(%rsp), %rdi
callq 0xe0b30
xorl %r13d, %r13d
movq %r13, %rax
addq $0x128, %rsp            # imm = 0x128
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x88(%rsp), %rsi
movq 0x30(%rsp), %rdi
callq 0x26c3a
movb $0x1, %al
jmp 0x2eedd