// File: /workspace/github_c_makefile_star2_O3/oridb[P]mc/parse/tok.c
// Function: decode
static int
decode(char **buf, size_t *len, size_t *sz)
{
	char c, c1, c2;
	int32_t v;

	c = next();
	/* we've already seen the '\' */
	switch (c) {
	case 'u':
		v = unichar();
		appendc(buf, len, sz, v);
		return v;
	case 'x': /* arbitrary hex */
		c1 = next();
		if (!isxdigit(c1))
			lfatal(curloc, "expected hex digit, got %c", c1);
		c2 = next();
		if (!isxdigit(c2))
			lfatal(curloc, "expected hex digit, got %c", c1);
		v = 16 * hexval(c1) + hexval(c2);
		break;
	case 'n': v = '\n'; break;
	case 'r': v = '\r'; break;
	case 't': v = '\t'; break;
	case 'b': v = '\b'; break;
	case '"': v = '\"'; break;
	case '\'': v = '\''; break;
	case 'v': v = '\v'; break;
	case '\\': v = '\\'; break;
	case '0': v = '\0'; break;
	default: lfatal(curloc, "unknown escape code \\%c", c);
	}
	append(buf, len, sz, v);
	return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movslq 0x4028d(%rip), %r13     # 0x621b8
movl 0x40276(%rip), %r12d    # 0x621a8
cmpl %r12d, %r13d
jge 0x221e2
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq 0x40255(%rip), %rbp     # 0x621a0
movzbl (%rbp,%r13), %ecx
movsbl %cl, %edx
leaq 0x1(%r13), %rax
movl %eax, 0x4025a(%rip)     # 0x621b8
cmpl $0x5b, %ecx
jle 0x21f85
leal -0x6e(%rcx), %esi
cmpl $0xa, %esi
ja 0x21fb3
leaq 0x1584e(%rip), %rcx     # 0x377c0
movslq (%rcx,%rsi,4), %rsi
addq %rcx, %rsi
jmpq *%rsi
movl $0xa, %ebp
jmp 0x22101
cmpl $0x22, %ecx
je 0x21f9f
cmpl $0x27, %ecx
je 0x21fa9
cmpl $0x30, %ecx
jne 0x221f1
xorl %ebp, %ebp
jmp 0x22101
movl $0x22, %ebp
jmp 0x22101
movl $0x27, %ebp
jmp 0x22101
cmpl $0x5c, %ecx
je 0x220fc
cmpl $0x62, %ecx
jne 0x221f1
movl $0x8, %ebp
jmp 0x22101
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmpl %r12d, %eax
jge 0x21fde
movsbl (%rbp,%rax), %ecx
movl %ecx, 0xc(%rsp)
leaq 0x2(%r13), %rax
movq %rax, 0x10(%rsp)
movl %eax, 0x401c7(%rip)     # 0x621b8
callq 0x4390
movl 0xc(%rsp), %edx
movq (%rax), %rax
movslq %edx, %rcx
testb $0x10, 0x1(%rax,%rcx,2)
je 0x22206
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
movq 0x10(%rsp), %rsi
cmpl %r12d, %esi
jge 0x2201f
movsbl (%rbp,%rsi), %ecx
addl $0x3, %r13d
movl %r13d, 0x4018e(%rip)    # 0x621b8
movl %ecx, %ebp
movslq %ecx, %rcx
testb $0x10, 0x1(%rax,%rcx,2)
je 0x22206
movsbl %dl, %edi
callq 0x222b3
movl %eax, %r13d
shll $0x4, %r13d
movl %ebp, %edi
callq 0x222b3
movl %eax, %ebp
orl %r13d, %ebp
jmp 0x22101
movl $0xb, %ebp
jmp 0x22101
cmpl %r12d, %eax
jge 0x22216
movb (%rbp,%rax), %al
leal 0x2(%r13), %ecx
movl %ecx, 0x4013d(%rip)     # 0x621b8
cmpb $0x7b, %al
jne 0x22221
xorl %ebp, %ebp
movslq 0x4012c(%rip), %rcx     # 0x621b8
cmpl 0x40116(%rip), %ecx     # 0x621a8
jge 0x221c5
movq 0x40101(%rip), %rax     # 0x621a0
movb (%rax,%rcx), %al
leal -0x3a(%rax), %edx
incl %ecx
movl %ecx, 0x4010b(%rip)     # 0x621b8
cmpb $-0xb, %dl
ja 0x220bf
movl %eax, %ecx
andb $-0x21, %cl
addb $-0x47, %cl
cmpb $-0x6, %cl
jb 0x22122
movl %ebp, %r12d
shll $0x4, %r12d
movsbl %al, %edi
callq 0x222b3
orl %r12d, %eax
cmpl $0x11000, %ebp          # imm = 0x11000
movl %eax, %ebp
jb 0x22085
movq 0x400ce(%rip), %rdi     # 0x621b0
leaq 0x15851(%rip), %rsi     # 0x3793a
jmp 0x221db
movl $0x9, %ebp
jmp 0x22101
movl $0xd, %ebp
jmp 0x22101
movl $0x5c, %ebp
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movl %ebp, %ecx
callq 0x22243
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpb $0x7d, %al
jne 0x221cd
movl $0x0, 0x8(%rsp)
cmpl $0x80, %ebp
jae 0x22146
xorl %edx, %edx
movl $0x1, %r12d
movl %ebp, %eax
jmp 0x2219b
movl $0x2, %r12d
cmpl $0x800, %ebp            # imm = 0x800
jb 0x22174
movl $0x3, %r12d
cmpl $0x10000, %ebp          # imm = 0x10000
jb 0x22174
movl $0x4, %r12d
cmpl $0x200000, %ebp         # imm = 0x200000
jae 0x22231
leaq -0x1(%r12), %rcx
movl %ebp, %eax
movl %eax, %edx
andb $0x3f, %dl
orb $-0x80, %dl
movb %dl, 0x7(%rsp,%rcx)
shrl $0x6, %eax
decq %rcx
jne 0x2217b
movb $0x8, %cl
subb %r12b, %cl
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
shll %cl, %edx
orl %edx, %eax
movb %al, 0x7(%rsp)
xorl %r13d, %r13d
movsbl 0x7(%rsp,%r13), %ecx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x22243
incq %r13
cmpq %r13, %r12
jne 0x221a4
jmp 0x22111
incl %ecx
movl %ecx, 0x3ffeb(%rip)     # 0x621b8
movq 0x3ffdc(%rip), %rdi     # 0x621b0
leaq 0x15788(%rip), %rsi     # 0x37963
xorl %eax, %eax
callq 0x139d2
incl %r13d
movl %r13d, 0x3ffcc(%rip)    # 0x621b8
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movq 0x3ffb8(%rip), %rdi     # 0x621b0
leaq 0x156fc(%rip), %rsi     # 0x378fb
xorl %eax, %eax
callq 0x139d2
movq 0x3ffa3(%rip), %rdi     # 0x621b0
leaq 0x156cc(%rip), %rsi     # 0x378e0
jmp 0x221ff
addl $0x2, %r13d
movl %r13d, 0x3ff97(%rip)    # 0x621b8
movq 0x3ff88(%rip), %rdi     # 0x621b0
leaq 0x156e4(%rip), %rsi     # 0x37913
jmp 0x221db
movq 0x3ff78(%rip), %rdi     # 0x621b0
leaq 0x1574a(%rip), %rsi     # 0x37989
movl %ebp, %edx
jmp 0x221ff