// File: /workspace/github_c_makefile_star2_O0/crcx[P]retroforth/vm/nga-c/retro.c
// Function: i_di
V i_di(NgaState *vm) {
  guard(vm, 2, 2, 0);
  CELL a, b;
  a = TOS;
  b = NOS;
  if (b == 0) {
#ifdef ENABLE_ERROR
    if (vm->ErrorHandlers[6] != 0) {
    }
#endif
  }
  if (ACTIVE.u != 0) {
    TOS = (unsigned)b / (unsigned)a;
    NOS = (unsigned)b % (unsigned)a;
    ACTIVE.u = 0;
  } else {
    TOS = b / a;
    NOS = b % a;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movl $0x2, %edx
xorl %ecx, %ecx
movl %edx, %esi
callq 0x3740
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rdx
movslq 0x2043a4(%rdx), %rdx
imulq $0x874, %rdx, %rdx      # imm = 0x874
addq %rdx, %rcx
movslq (%rcx), %rcx
movl 0x14(%rax,%rcx,4), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rdx
movslq 0x2043a4(%rdx), %rdx
imulq $0x874, %rdx, %rdx      # imm = 0x874
addq %rdx, %rcx
movl (%rcx), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movl 0x14(%rax,%rcx,4), %eax
movl %eax, -0x10(%rbp)
cmpl $0x0, -0x10(%rbp)
jne 0xba1c
movq -0x8(%rbp), %rax
cmpl $0x0, 0x2079dc(%rax)
je 0xba1a
jmp 0xba1a
jmp 0xba1c
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
cmpl $0x0, 0x10(%rax)
je 0xbb13
movl -0x10(%rbp), %eax
xorl %edx, %edx
divl -0xc(%rbp)
movl %eax, %edx
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rsi
movslq 0x2043a4(%rsi), %rsi
imulq $0x874, %rsi, %rsi      # imm = 0x874
addq %rsi, %rcx
movslq (%rcx), %rcx
movl %edx, 0x14(%rax,%rcx,4)
movl -0x10(%rbp), %eax
xorl %edx, %edx
divl -0xc(%rbp)
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rsi
movslq 0x2043a4(%rsi), %rsi
imulq $0x874, %rsi, %rsi      # imm = 0x874
addq %rsi, %rcx
movl (%rcx), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movl %edx, 0x14(%rax,%rcx,4)
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movl $0x0, 0x10(%rax)
jmp 0xbbb4
movl -0x10(%rbp), %eax
cltd
idivl -0xc(%rbp)
movl %eax, %edx
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rsi
movslq 0x2043a4(%rsi), %rsi
imulq $0x874, %rsi, %rsi      # imm = 0x874
addq %rsi, %rcx
movslq (%rcx), %rcx
movl %edx, 0x14(%rax,%rcx,4)
movl -0x10(%rbp), %eax
cltd
idivl -0xc(%rbp)
movq -0x8(%rbp), %rax
addq $0x200004, %rax         # imm = 0x200004
movq -0x8(%rbp), %rcx
movslq 0x2043a4(%rcx), %rcx
imulq $0x874, %rcx, %rcx      # imm = 0x874
addq %rcx, %rax
movq -0x8(%rbp), %rcx
addq $0x200004, %rcx         # imm = 0x200004
movq -0x8(%rbp), %rsi
movslq 0x2043a4(%rsi), %rsi
imulq $0x874, %rsi, %rsi      # imm = 0x874
addq %rsi, %rcx
movl (%rcx), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movl %edx, 0x14(%rax,%rcx,4)
addq $0x10, %rsp
popq %rbp
retq
nopw (%rax,%rax)