// File: /workspace/github_c_makefile_star2_O0/aap[P]rx-0/pdp1/mach.c
// Function: shro
static void
shro(PDP1 *pdp)
{
	int ac = AC;
	int io = IO;
	switch((MB>>9) & 017) {
	case 001:	// RAL
		ac = (AC&~B0)<<1 | (AC&B0)>>17;
		break;
	case 002:	// RIL
		io = (IO&~B0)<<1 | (IO&B0)>>17;
		break;
	case 003:	// RCL
		ac = (AC&~B0)<<1 | (IO&B0)>>17;
		io = (IO&~B0)<<1 | (AC&B0)>>17;
		break;
	case 005:	// SAL
		ac = (AC&B0) | (AC&~(B0|B1))<<1 | (AC&B0)>>17;
		break;
	case 006:	// SIL
		io = (IO&B0) | (IO&~(B0|B1))<<1 | (IO&B0)>>17;
		break;
	case 007:	// SCL
		ac = (AC&B0) | (AC&~(B0|B1))<<1 | (IO&B0)>>17;
		io = (IO&~B0)<<1 | (AC&B0)>>17;
		break;
	case 011:	// RAR
		ac = (AC&B17)<<17 | AC>>1;
		break;
	case 012:	// RIR
		io = (IO&B17)<<17 | IO>>1;
		break;
	case 013:	// RCR
		ac = (IO&B17)<<17 | AC>>1;
		io = (AC&B17)<<17 | IO>>1;
		break;
	case 015:	// SAR
		ac = (AC&B0) | AC>>1;
		break;
	case 016:	// SIR
		io = (IO&B0) | IO>>1;
		break;
	case 017:	// SCR
		ac = (AC&B0) | AC>>1;
		io = (AC&B17)<<17 | IO>>1;
		break;
	}
	AC = ac;
	IO = io;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movl 0x8(%rax), %eax
shrl $0x9, %eax
andl $0xf, %eax
decl %eax
movl %eax, %ecx
movq %rcx, -0x18(%rbp)
subl $0xe, %eax
ja 0x6ea2
movq -0x18(%rbp), %rax
leaq 0x7f8(%rip), %rcx       # 0x745c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0xfffdffff, %eax       # imm = 0xFFFDFFFF
shll %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0xfffdffff, %eax       # imm = 0xFFFDFFFF
shll %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0xfffdffff, %eax       # imm = 0xFFFDFFFF
shll %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0xfffdffff, %eax       # imm = 0xFFFDFFFF
shll %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0xfffcffff, %ecx       # imm = 0xFFFCFFFF
shll %ecx
orl %ecx, %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
andl $0xfffcffff, %ecx       # imm = 0xFFFCFFFF
shll %ecx
orl %ecx, %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0xfffcffff, %ecx       # imm = 0xFFFCFFFF
shll %ecx
orl %ecx, %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0xfffdffff, %eax       # imm = 0xFFFDFFFF
shll %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
andl $0x20000, %ecx          # imm = 0x20000
shrl $0x11, %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x1, %eax
shll $0x11, %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0x1, %eax
shll $0x11, %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0x1, %eax
shll $0x11, %eax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x1, %eax
shll $0x11, %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl 0x4(%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
jmp 0x6ea2
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x20000, %eax          # imm = 0x20000
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x1, %eax
shll $0x11, %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrl %ecx
orl %ecx, %eax
movl %eax, -0x10(%rbp)
movl -0xc(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, (%rax)
movl -0x10(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x4(%rax)
popq %rbp
retq
nopw (%rax,%rax)