// File: /workspace/github_c_makefile_star2_O0/ksherlock[P]nroff_man/render.c
// Function: print
unsigned print(const unsigned char *cp, int fi) {
	unsigned i;
	uint_fast8_t prev = 0;
	unsigned length = 0;

	indent();
	for (i = 0; ;++i) {
		uint_fast8_t c = cp[i];
		if (c == 0) return length;
		switch(c) {
			case FONT_R: case FONT_B: case FONT_I: case FONT_P: case FONT_X:
				set_font(c);
				break;
			case HYPHEN: case ZWSPACE: break;
			case NBSPACE: case XSPACE: fputc(' ', stdout); length++; break;
			case ' ': case '\t':
				if (fi) {
					c = ' ';
					if (prev != ' ') { fputc(' ', stdout); length++; }
				} else {
					fputc(c, stdout); length++;
				}
				break;
			default: 
				if (flags.T == FMT_ASCII) {
					if (ft == FONT_B) {
						fputc(c, stdout);
						fputc(8, stdout);
					}
					if (ft == FONT_I) {
						fputs("_\x08", stdout);
					}
				}
				fputc(c, stdout); length++;
				break;
		}
		prev = c;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movb $0x0, -0x11(%rbp)
movl $0x0, -0x18(%rbp)
callq 0x8fa0
movl $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
movl -0x10(%rbp), %ecx
movb (%rax,%rcx), %al
movb %al, -0x19(%rbp)
movzbl -0x19(%rbp), %eax
cmpl $0x0, %eax
jne 0x8e25
movl -0x18(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
movzbl -0x19(%rbp), %eax
movl %eax, -0x20(%rbp)
subl $0x9, %eax
je 0x8ea9
jmp 0x8e33
movl -0x20(%rbp), %eax
subl $0x20, %eax
je 0x8ea9
jmp 0x8e3d
movl -0x20(%rbp), %eax
addl $-0x80, %eax
subl $0x2, %eax
jb 0x8e87
jmp 0x8e4a
movl -0x20(%rbp), %eax
subl $0x82, %eax
je 0x8e82
jmp 0x8e56
movl -0x20(%rbp), %eax
addl $0xffffff7d, %eax       # imm = 0xFFFFFF7D
subl $0x5, %eax
jb 0x8e74
jmp 0x8e65
movl -0x20(%rbp), %eax
subl $0x88, %eax
je 0x8e82
jmp 0x8efc
movzbl -0x19(%rbp), %edi
callq 0x8a00
jmp 0x8f82
jmp 0x8f82
movq 0x5132(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl $0x20, %edi
callq 0x40e0
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x8f82
cmpl $0x0, -0xc(%rbp)
je 0x8edb
movb $0x20, -0x19(%rbp)
movzbl -0x11(%rbp), %eax
cmpl $0x20, %eax
je 0x8ed9
movq 0x50fd(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl $0x20, %edi
callq 0x40e0
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x8ef7
movzbl -0x19(%rbp), %edi
movq 0x50da(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
callq 0x40e0
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x8f82
leaq 0x73d5(%rip), %rax      # 0x102d8
cmpl $0x1, 0x20(%rax)
jne 0x8f66
leaq 0x5410(%rip), %rax      # 0xe320
cmpl $0x84, (%rax)
jne 0x8f3f
movzbl -0x19(%rbp), %edi
movq 0x509d(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
callq 0x40e0
movq 0x508e(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl $0x8, %edi
callq 0x40e0
leaq 0x53da(%rip), %rax      # 0xe320
cmpl $0x85, (%rax)
jne 0x8f64
movq 0x506b(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
leaq 0x34b1(%rip), %rdi      # 0xc410
callq 0x40c0
jmp 0x8f66
movzbl -0x19(%rbp), %edi
movq 0x504f(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
callq 0x40e0
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
movb -0x19(%rbp), %al
movb %al, -0x11(%rbp)
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x8e06
nopw %cs:(%rax,%rax)