// File: /workspace/github_c_makefile_star2_O0/leiradel[P]zx48k-libretro/src/main.c
// Function: main_get_register
static uint64_t main_get_register(unsigned reg) {
    switch (reg) {
        case HC_Z80_A: return z80_a(&zx48k.zx.cpu);
        case HC_Z80_F: return z80_f(&zx48k.zx.cpu);
        case HC_Z80_BC: return z80_bc(&zx48k.zx.cpu);
        case HC_Z80_DE: return z80_de(&zx48k.zx.cpu);
        case HC_Z80_HL: return z80_hl(&zx48k.zx.cpu);
        case HC_Z80_IX: return z80_ix(&zx48k.zx.cpu);
        case HC_Z80_IY: return z80_iy(&zx48k.zx.cpu);
        case HC_Z80_AF2: return z80_af_(&zx48k.zx.cpu);
        case HC_Z80_BC2: return z80_bc_(&zx48k.zx.cpu);
        case HC_Z80_DE2: return z80_de_(&zx48k.zx.cpu);
        case HC_Z80_HL2: return z80_hl_(&zx48k.zx.cpu);
        case HC_Z80_I: return z80_i(&zx48k.zx.cpu);
        case HC_Z80_R: return z80_r(&zx48k.zx.cpu);
        case HC_Z80_SP: return z80_sp(&zx48k.zx.cpu);
        case HC_Z80_PC: return z80_pc(&zx48k.zx.cpu);
        case HC_Z80_IFF: return z80_iff1(&zx48k.zx.cpu) << 1 | z80_iff2(&zx48k.zx.cpu);
        case HC_Z80_IM: return z80_im(&zx48k.zx.cpu);
        case HC_Z80_WZ: return z80_wz(&zx48k.zx.cpu);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq %rax, -0x18(%rbp)
subq $0x11, %rax
ja 0x23831
movq -0x18(%rbp), %rax
leaq 0x1251(%rip), %rcx      # 0x248b8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x9d99(%rip), %rdi      # 0x2d410
callq 0x30c0
movzbl %al, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d81(%rip), %rdi      # 0x2d410
callq 0x33e0
movzbl %al, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d69(%rip), %rdi      # 0x2d410
callq 0x34a0
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d51(%rip), %rdi      # 0x2d410
callq 0x32c0
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d39(%rip), %rdi      # 0x2d410
callq 0x3340
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d21(%rip), %rdi      # 0x2d410
callq 0x3100
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9d09(%rip), %rdi      # 0x2d410
callq 0x33b0
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9cf1(%rip), %rdi      # 0x2d410
callq 0x3030
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9cd9(%rip), %rdi      # 0x2d410
callq 0x3320
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9cc1(%rip), %rdi      # 0x2d410
callq 0x30a0
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9ca9(%rip), %rdi      # 0x2d410
callq 0x3550
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c91(%rip), %rdi      # 0x2d410
callq 0x30e0
movzbl %al, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c79(%rip), %rdi      # 0x2d410
callq 0x33f0
movzbl %al, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c61(%rip), %rdi      # 0x2d410
callq 0x3520
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c4c(%rip), %rdi      # 0x2d410
callq 0x3560
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c37(%rip), %rdi      # 0x2d410
callq 0x33a0
andb $0x1, %al
movzbl %al, %eax
shll %eax
movl %eax, -0x1c(%rbp)
leaq 0x9c21(%rip), %rdi      # 0x2d410
callq 0x3110
movb %al, %cl
movl -0x1c(%rbp), %eax
andb $0x1, %cl
movzbl %cl, %ecx
orl %ecx, %eax
cltq
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9c00(%rip), %rdi      # 0x2d410
callq 0x33c0
movzbl %al, %eax
movq %rax, -0x8(%rbp)
jmp 0x23831
leaq 0x9beb(%rip), %rdi      # 0x2d410
callq 0x3290
movzwl %ax, %eax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)