// File: /workspace/github_c_makefile_star2_O1/aap[P]pdp11/kd11a.c
// Function: datix
static int
datix(KD11A *cpu, int pse)
{
trace("dati%s %o %06o ", pse ? "p" : "", cpu->flags, cpu->ba);
	if(remapBA(cpu, pse))
		return 1;
trace(" phys(%o) <- ", PBA);
	if(checkbus(cpu, 0, pse))
		return 1;

	if(dati_cpu(cpu))
		goto ok;

	if((pse ? datip_bus : dati_bus)(cpu->bus))
		return buserr(cpu);
ok:
	trace("%06o\n", UNIBUS_DATA);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
cmpl $0x0, 0x43c85(%rip)     # 0x4ad60
je 0x7107
testl %r14d, %r14d
leaq 0x2836(%rip), %rax      # 0x991d
leaq 0x2603(%rip), %rsi      # 0x96f1
cmoveq %rax, %rsi
movl 0x38(%rbx), %edx
movzwl 0x24(%rbx), %ecx
leaq 0x25e1(%rip), %rdi      # 0x96e1
xorl %eax, %eax
callq 0x20a0
movq %rbx, %rdi
movl %r14d, %esi
callq 0x72f7
movl $0x1, %ebp
testl %eax, %eax
jne 0x72c4
cmpl $0x0, 0x43c3a(%rip)     # 0x4ad60
je 0x713d
movq 0x28(%rbx), %rax
movl 0x8(%rax), %esi
leaq 0x25bd(%rip), %rdi      # 0x96f3
xorl %eax, %eax
callq 0x20a0
movq %rbx, %rdi
xorl %esi, %esi
movl %r14d, %edx
callq 0x7486
testl %eax, %eax
jne 0x72c4
movq 0x28(%rbx), %rdi
movl 0x8(%rdi), %eax
cmpq $0x3e001, %rax          # imm = 0x3E001
jb 0x7255
movl %eax, %ecx
andl $0x3fff0, %ecx          # imm = 0x3FFF0
cmpl $0x3ff7f, %ecx          # imm = 0x3FF7F
jg 0x7192
cmpl $0x3f4c0, %ecx          # imm = 0x3F4C0
je 0x71d5
cmpl $0x3f4e0, %ecx          # imm = 0x3F4E0
jne 0x71af
andl $0xe, %eax
movzwl 0x9c(%rbx,%rax), %ecx
jmp 0x720e
cmpl $0x3ff80, %ecx          # imm = 0x3FF80
je 0x71ed
cmpl $0x3ffa0, %ecx          # imm = 0x3FFA0
jne 0x71af
andl $0xe, %eax
movzwl 0x8c(%rbx,%rax), %ecx
jmp 0x720e
movl %eax, %ecx
andl $-0x2, %ecx
cmpl $0x3ff7e, %ecx          # imm = 0x3FF7E
je 0x7207
cmpl $0x3ff7c, %ecx          # imm = 0x3FF7C
je 0x7203
cmpl $0x3ff7a, %ecx          # imm = 0x3FF7A
jne 0x7217
movzwl 0x138(%rbx), %ecx
jmp 0x720e
addl %eax, %eax
andl $0x1c, %eax
movl 0x10c(%rbx,%rax), %ecx
shll $0x2, %ecx
orl 0xcc(%rbx,%rax), %ecx
jmp 0x720e
andl $0xe, %eax
movl 0xec(%rbx,%rax,2), %ecx
shll $0x2, %ecx
orl 0xac(%rbx,%rax,2), %ecx
jmp 0x720e
xorl %ecx, %ecx
jmp 0x720e
movzwl 0x13a(%rbx), %ecx
movw %cx, 0xc(%rdi)
jmp 0x729f
movl %eax, %ecx
notl %ecx
testl $0x3ff00, %ecx          # imm = 0x3FF00
jne 0x7255
movzbl %al, %eax
leal -0xfe(%rax), %ecx
cmpl $0x2, %ecx
jb 0x72cb
leal -0xfc(%rax), %ecx
cmpl $0x2, %ecx
jb 0x72eb
addl $-0x78, %eax
cmpl $0x1, %eax
ja 0x7255
movzwl 0x80(%rbx), %ecx
jmp 0x720e
testl %r14d, %r14d
jne 0x7263
leaq -0x4dcf(%rip), %rax     # 0x2492
jmp 0x726a
leaq -0x4da6(%rip), %rax     # 0x24c4
callq *%rax
testl %eax, %eax
je 0x729f
movl 0x38(%rbx), %eax
testb $0x1, %al
je 0x7292
orl $0x108, %eax            # imm = 0x108
movl %eax, 0x38(%rbx)
movw $0x0, 0x84(%rbx)
movl $0x0, 0x13c(%rbx)
movl 0x38(%rbx), %eax
andl $-0x8, %eax
incl %eax
movl %eax, 0x38(%rbx)
jmp 0x72c4
cmpl $0x0, 0x43aba(%rip)     # 0x4ad60
je 0x72c2
movq 0x28(%rbx), %rax
movzwl 0xc(%rax), %esi
leaq 0x23c9(%rip), %rdi      # 0x9680
xorl %ebp, %ebp
xorl %eax, %eax
callq 0x20a0
jmp 0x72c4
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
movzwl 0x86(%rbx), %eax
shll $0xe, %eax
movl 0x88(%rbx), %edx
shll $0xc, %edx
orl %eax, %edx
movzbl 0x30(%rbx), %ecx
orl %edx, %ecx
jmp 0x720e
movzwl 0x82(%rbx), %ecx
jmp 0x720e