// File: /workspace/github_c_makefile_star2_O0/vtereshkov[P]umka-lang/src/umka_compiler.c
// Function: compilerDeclareBuiltinTypes
static void compilerDeclareBuiltinTypes(Compiler *comp)
{
    comp->voidType    = typeAdd(&comp->types, &comp->blocks, TYPE_VOID);
    comp->nullType    = typeAdd(&comp->types, &comp->blocks, TYPE_NULL);
    comp->int8Type    = typeAdd(&comp->types, &comp->blocks, TYPE_INT8);
    comp->int16Type   = typeAdd(&comp->types, &comp->blocks, TYPE_INT16);
    comp->int32Type   = typeAdd(&comp->types, &comp->blocks, TYPE_INT32);
    comp->intType     = typeAdd(&comp->types, &comp->blocks, TYPE_INT);
    comp->uint8Type   = typeAdd(&comp->types, &comp->blocks, TYPE_UINT8);
    comp->uint16Type  = typeAdd(&comp->types, &comp->blocks, TYPE_UINT16);
    comp->uint32Type  = typeAdd(&comp->types, &comp->blocks, TYPE_UINT32);
    comp->uintType    = typeAdd(&comp->types, &comp->blocks, TYPE_UINT);
    comp->boolType    = typeAdd(&comp->types, &comp->blocks, TYPE_BOOL);
    comp->charType    = typeAdd(&comp->types, &comp->blocks, TYPE_CHAR);
    comp->real32Type  = typeAdd(&comp->types, &comp->blocks, TYPE_REAL32);
    comp->realType    = typeAdd(&comp->types, &comp->blocks, TYPE_REAL);
    comp->strType     = typeAdd(&comp->types, &comp->blocks, TYPE_STR);

    comp->ptrVoidType = typeAddPtrTo(&comp->types, &comp->blocks, comp->voidType);
    comp->ptrNullType = typeAddPtrTo(&comp->types, &comp->blocks, comp->nullType);

    // any
    Type *anyType = typeAdd(&comp->types, &comp->blocks, TYPE_INTERFACE);

    typeAddField(&comp->types, anyType, comp->ptrVoidType, "#self");
    typeAddField(&comp->types, anyType, comp->ptrVoidType, "#selftype");

    comp->anyType = anyType;

    // fiber
    Type *fiberType = typeAdd(&comp->types, &comp->blocks, TYPE_FIBER);

    Type *fnType = typeAdd(&comp->types, &comp->blocks, TYPE_FN);
    typeAddParam(&comp->types, &fnType->sig, comp->anyType, "#upvalues", (Const){0});

    fnType->sig.resultType = comp->voidType;

    Type *fiberClosureType = typeAdd(&comp->types, &comp->blocks, TYPE_CLOSURE);
    typeAddField(&comp->types, fiberClosureType, fnType, "#fn");
    typeAddField(&comp->types, fiberClosureType, comp->anyType, "#upvalues");
    fiberType->base = fiberClosureType;

    comp->fiberType = fiberType;

    // __file
    Type *fileDataType = typeAdd(&comp->types, &comp->blocks, TYPE_STRUCT);
    typeAddField(&comp->types, fileDataType, comp->ptrVoidType, "#data");

    comp->fileType = typeAddPtrTo(&comp->types, &comp->blocks, fileDataType);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x2, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5218(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x3, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5220(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x4, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5228(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x5, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5230(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x6, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5238(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x7, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5240(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x8, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5248(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x9, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5250(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xa, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5258(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xb, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5260(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xc, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5268(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xd, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5270(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xe, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5278(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0xf, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5280(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x14, %edx
callq 0x21950
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5288(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movq -0x8(%rbp), %rax
movq 0x5218(%rax), %rdx
callq 0x21fa0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5298(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movq -0x8(%rbp), %rax
movq 0x5220(%rax), %rdx
callq 0x21fa0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x52a0(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x17, %edx
callq 0x21950
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x10(%rbp), %rsi
movq -0x8(%rbp), %rax
movq 0x5298(%rax), %rdx
leaq 0x1cd71d(%rip), %rcx    # 0x1d43d8
callq 0x23070
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x10(%rbp), %rsi
movq -0x8(%rbp), %rax
movq 0x5298(%rax), %rdx
leaq 0x1cd6fd(%rip), %rcx    # 0x1d43de
callq 0x23070
movq -0x10(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x52a8(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x19, %edx
callq 0x21950
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x1a, %edx
callq 0x21950
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x20(%rbp), %rsi
addq $0x28, %rsi
movq -0x8(%rbp), %rax
movq 0x52a8(%rax), %rdx
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %r8
leaq 0x1cd67a(%rip), %rcx    # 0x1d43e8
callq 0x23790
movq -0x8(%rbp), %rax
movq 0x5218(%rax), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0xb8(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x18, %edx
callq 0x21950
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x30(%rbp), %rsi
movq -0x20(%rbp), %rdx
leaq 0x1cd62b(%rip), %rcx    # 0x1d43f2
callq 0x23070
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x30(%rbp), %rsi
movq -0x8(%rbp), %rax
movq 0x52a8(%rax), %rdx
leaq 0x1cd5fb(%rip), %rcx    # 0x1d43e8
callq 0x23070
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x18(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x5290(%rax)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movl $0x16, %edx
callq 0x21950
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x38(%rbp), %rsi
movq -0x8(%rbp), %rax
movq 0x5298(%rax), %rdx
leaq 0x1cd5a4(%rip), %rcx    # 0x1d43f6
callq 0x23070
movq -0x8(%rbp), %rdi
addq $0x4e18, %rdi           # imm = 0x4E18
movq -0x8(%rbp), %rsi
addq $0x4220, %rsi           # imm = 0x4220
movq -0x38(%rbp), %rdx
callq 0x21fa0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x52b0(%rax)
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)