/* Automatically generated file, do not edit! */
#include "../../config.h"

	b	O_kroc_error_process
	nop
	mr	6, 1
	addi	1, 1, -24
	stw	6, 0(1)
	stw	31, 20(1)
	mr	31, 1
	stw	3, 16(1)
	stw	4, 12(1)
	stw	5, 8(1)
	addi	3, 3, 4
	bl	_write_error
	nop
	lwz	11, 0(1)
	lwz	31, -4(11)
	lwz	3, 16(1)
	lwz	4, 12(1)
	lwz	5, 8(1)
	mr	1, 11
	addi	3, 3, 16
	mr	6, 1
	addi	1, 1, -24
	stw	6, 0(1)
	stw	31, 20(1)
	mr	31, 1
	stw	3, 16(1)
	stw	4, 12(1)
	stw	5, 8(1)
	addi	3, 3, 4
	bl	_write_screen
	nop
	lwz	11, 0(1)
	lwz	31, -4(11)
	lwz	3, 16(1)
	lwz	4, 12(1)
	lwz	5, 8(1)
	mr	1, 11
	addi	3, 3, 16

.align 4
.globl O_kroc_screen_process
O_kroc_screen_process:
	;# sourcefile "interface_out.occ"
	addi	3, 3, -76
	li	6, 0
	stw	6, 0(3)
L3:
	li	6, 0
	stw	6, 4(3)
	lwz	6, 0(3)
	li	7, 64
	cmpw	7, 6
	bgt	L29
	nop
	bl	_X_BasicRangeError
L29:
	addi	7, 3, 12
	add	7, 7, 6
	lwz	6, 80(3)
	bl	_Y_in8
	li	6, 0
	stw	6, 4(3)
	lwz	6, 0(3)
	li	7, 64
	cmpw	7, 6
	bgt	L30
	nop
	bl	_X_BasicRangeError
L30:
	addi	7, 3, 12
	add	7, 7, 6
	lbz	7, 0(7)
	li	6, 255
	and	7, 7, 6
	stw	7, 8(3)
	li	6, 10
	lwz	7, 8(3)
	subf	6, 7, 6
	or.	6, 6, 6
	beq	L6
	nop
	li	6, 13
	lwz	7, 8(3)
	subf	6, 7, 6
	or.	6, 6, 6
	beq	L6
	nop
	lwz	6, 8(3)
	li	7, 255
	cmpw	6, 7
	bne	L7
	nop
	b	L5
	nop
L7:
	lwz	6, 0(3)
	li	7, 1
	addo.	6, 6, 7
	bns	7f
	nop
	b	_X_BNSeterr
	nop
7:
	stw	6, 0(3)
	b	L4
	nop
L6:
	li	6, 1
	stw	6, 4(3)
	lwz	6, 0(3)
	li	7, 1
	addo.	6, 6, 7
	bns	7f
	nop
	b	_X_BNSeterr
	nop
7:
	stw	6, 0(3)
	b	L4
	nop
L5:
	li	6, 1
	stw	6, 4(3)
	b	L4
	nop
L4:
	lwz	6, 0(3)
	li	7, 62
	cmpw	6, 7
	bne	L9
	nop
	li	6, 1
	stw	6, 4(3)
	b	L9
	nop
L9:
	lwz	6, 4(3)
	or.	6, 6, 6
	beq	L11
	nop
	li	6, 0
	lwz	7, 0(3)
	li	8, 64
	cmpw	8, 7
	bgt	L31
	nop
	bl	_X_BasicRangeError
L31:
	addi	8, 3, 12
	add	8, 8, 7
	stb	6, 0(8)
	li	6, 64
	addi	7, 3, 12
	stw	6, -8(3)
	stw	7, -12(3)
	addi	3, 3, -16
	mr	6, 1
	addi	1, 1, -24
	stw	6, 0(1)
	stw	31, 20(1)
	mr	31, 1
	stw	3, 16(1)
	stw	4, 12(1)
	stw	5, 8(1)
	addi	3, 3, 4
	bl	_write_screen
	nop
	lwz	11, 0(1)
	lwz	31, -4(11)
	lwz	3, 16(1)
	lwz	4, 12(1)
	lwz	5, 8(1)
	mr	1, 11
	addi	3, 3, 16
	li	6, 0
	stw	6, 0(3)
	b	L11
	nop
L11:
	b	L3
	nop
	addi	3, 3, 76
	addi	3, 3, 16
	lwz	11, -16(3)
	mtlr	11
	blr
	nop
.globl O_kroc_error_process
O_kroc_error_process:
L14:
	li	6, 0
	stw	6, 12(3)
	addi	7, 3, 12
	addi	7, 7, 3
	lwz	6, 4(3)
	bl	_Y_in8
	lwz	6, 12(3)
	stw	6, -12(3)
	addi	3, 3, -16
	mr	6, 1
	addi	1, 1, -24
	stw	6, 0(1)
	stw	31, 20(1)
	mr	31, 1
	stw	3, 16(1)
	stw	4, 12(1)
	stw	5, 8(1)
	addi	3, 3, 4
	bl	_write_error
	nop
	lwz	11, 0(1)
	lwz	31, -4(11)
	lwz	3, 16(1)
	lwz	4, 12(1)
	lwz	5, 8(1)
	mr	1, 11
	addi	3, 3, 16
	b	L14
	nop
	addi	3, 3, 16
	lwz	11, -16(3)
	mtlr	11
	blr
	nop

.align 4

.align 8

.align 8

.align 8

.align 4

.align 16
.data
L25:
	.byte	0xc1, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
L26:
	.byte	0x41, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
L27:
	.byte	0xc3, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
L28:
	.byte	0x43, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
L23:
	.byte	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
L24:
	.byte	0x43, 0x30, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00 
#if defined(BLOCKING_SYSCALLS) && !defined(OOS_BUILD)
.text
	b	O_kroc_keyboard_process
	nop
	addi	7, 3, 4
	lis	6, _read_keyboard@ha
	ori	6, 6, _read_keyboard@l
	bl	_X_bx_dispatch
	addi	3, 3, 16

.align 4
.globl O_kroc_keyboard_process
O_kroc_keyboard_process:
	;# sourcefile "interface_in.occ"
	addi	3, 3, -12
	li	6, 0
	stw	6, 24(3)
	li	6, 0
	stw	6, 24(3)
LX2:
	li	6, 0
	stw	6, 8(3)
	lwz	6, 24(3)
	or.	6, 6, 6
	bne	LX4
	nop
	lis	6, 32768

	stw	6, 4(3)
LX5:
	lwz	6, 4(3)
	lis	7, 32768

	cmpw	6, 7
	bne	LX6
	nop
	addi	6, 3, 4
	lwz	7, 20(3)
	stw	6, -8(3)
	stw	7, -12(3)
	addi	3, 3, -16
	addi	7, 3, 4
	lis	6, _read_keyboard@ha
	ori	6, 6, _read_keyboard@l
	bl	_X_bx_dispatch
	addi	3, 3, 16
	b	LX5
	nop
LX6:
	lwz	6, 4(3)
	li	7, -1
	cmpw	6, 7
	bne	LX8
	nop
	li	6, 1
	stw	6, 24(3)
	li	6, 255
	stw	6, 8(3)
	b	LX7
	nop
LX8:
	lwz	6, 4(3)
	li	7, 256
	cmpw	7, 6
	bgt	LX23
	nop
	bl	_X_BasicRangeError
LX23:
	stw	6, 8(3)
	b	LX7
	nop
LX7:
	addi	7, 3, 8
	addi	7, 7, 3
	lwz	6, 16(3)
	bl	_Y_out8
	b	LX3
	nop
LX4:
	lwz	7, 16(3)
	li	6, 255
	bl	_Y_outbyte
	b	LX3
	nop
LX3:
	b	LX2
	nop
	addi	3, 3, 12
	addi	3, 3, 16
	lwz	11, -16(3)
	mtlr	11
	blr
	nop

.align 4

.align 8

.align 8

.align 8

.align 4

.align 16
.data
LX19:
	.byte	0xc1, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
LX20:
	.byte	0x41, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
LX21:
	.byte	0xc3, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
LX22:
	.byte	0x43, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
LX17:
	.byte	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 
LX18:
	.byte	0x43, 0x30, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00 
#endif

.text
.globl kroc_screen_jumpcode
.align 4
kroc_screen_jumpcode:
	bl	O_kroc_screen_process
	nop

.globl kroc_error_jumpcode
.align 4
kroc_error_jumpcode:
	bl	O_kroc_error_process
	nop

#if defined(BLOCKING_SYSCALLS) && !defined(OOS_BUILD)
.globl kroc_keyboard_jumpcode
.align 4
kroc_keyboard_jumpcode:
	bl	O_kroc_keyboard_process
	nop
#endif
#ifdef USER_DEFINED_CHANNELS
.globl udc_alter_fallout_jumpcode
.align 4
udc_alter_fallout_jumpcode:
	lis	9, _X_udc_fallout@ha
	ori	0, 9, _X_udc_fallout@l
	mtlr	0
	blr
	nop
.align 4
#endif

