// File: /workspace/github_c_makefile_star2_O1/ccxvii[P]mujs/./json.c
// Function: fmtstr
static void fmtstr(js_State *J, js_Buffer **sb, const char *s)
{
	static const char *HEX = "0123456789abcdef";
	int i, n;
	Rune c;
	js_putc(J, sb, '"');
	while (*s) {
		n = chartorune(&c, s);
		switch (c) {
		case '"': js_puts(J, sb, "\\\""); break;
		case '\\': js_puts(J, sb, "\\\\"); break;
		case '\b': js_puts(J, sb, "\\b"); break;
		case '\f': js_puts(J, sb, "\\f"); break;
		case '\n': js_puts(J, sb, "\\n"); break;
		case '\r': js_puts(J, sb, "\\r"); break;
		case '\t': js_puts(J, sb, "\\t"); break;
		default:
			if (c < ' ' || (c >= 0xd800 && c <= 0xdfff)) {
				js_putc(J, sb, '\\');
				js_putc(J, sb, 'u');
				js_putc(J, sb, HEX[(c>>12)&15]);
				js_putc(J, sb, HEX[(c>>8)&15]);
				js_putc(J, sb, HEX[(c>>4)&15]);
				js_putc(J, sb, HEX[c&15]);
			} else if (c < 128) {
				js_putc(J, sb, c);
			} else {
				for (i = 0; i < n; ++i)
					js_putc(J, sb, s[i]);
			}
			break;
		}
		s += n;
	}
	js_putc(J, sb, '"');
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movl $0x22, %edx
callq 0xe0bc
cmpb $0x0, (%r15)
je 0x236c6
leaq 0x4(%rsp), %rdi
movq %r15, %rsi
callq 0x18750
movl 0x4(%rsp), %r13d
leal -0x8(%r13), %ecx
movl %eax, %r12d
cmpl $0x5, %ecx
ja 0x234b4
leaq 0x86ca(%rip), %rdx      # 0x2bb44
movslq (%rdx,%rcx,4), %rax
addq %rdx, %rax
jmpq *%rax
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x1179b(%rip), %rax     # 0x34c3c
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x23488
jmp 0x236b7
cmpl $0x22, %r13d
je 0x23655
cmpl $0x5c, %r13d
jne 0x234f5
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x11757(%rip), %rax     # 0x34c39
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x234c9
jmp 0x236b7
cmpl $0x20, %r13d
setge %al
movl %r13d, %ecx
andl $0x7ffff800, %ecx       # imm = 0x7FFFF800
cmpl $0xd800, %ecx           # imm = 0xD800
setne %cl
testb %cl, %al
jne 0x23683
movq %r14, %rdi
movq %rbx, %rsi
movl $0x5c, %edx
callq 0xe0bc
movq %r14, %rdi
movq %rbx, %rsi
movl $0x75, %edx
callq 0xe0bc
movl %r13d, %eax
shrl $0xc, %eax
andl $0xf, %eax
leaq 0x116df(%rip), %rbp     # 0x34c25
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
movl %r13d, %eax
shrl $0x8, %eax
andl $0xf, %eax
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
movl %r13d, %eax
shrl $0x4, %eax
andl $0xf, %eax
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
andl $0xf, %r13d
movsbl (%r13,%rbp), %r13d
jmp 0x2368c
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x11696(%rip), %rax     # 0x34c48
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x23599
jmp 0x236b7
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x1165f(%rip), %rax     # 0x34c42
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x235ca
jmp 0x236b7
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x1162b(%rip), %rax     # 0x34c3f
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x235fb
jmp 0x236b7
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x11600(%rip), %rax     # 0x34c45
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2362c
jmp 0x236b7
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
leaq 0x115c3(%rip), %rax     # 0x34c36
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2365a
jmp 0x236b7
cmpl $0x80, %r13d
jge 0x2369c
movq %r14, %rdi
movq %rbx, %rsi
movl %r13d, %edx
callq 0xe0bc
jmp 0x236b7
xorl %r13d, %r13d
movsbl (%r15,%r13), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xe0bc
incq %r13
cmpq %r13, %r12
jne 0x2369f
cmpb $0x0, (%r15,%r12)
leaq (%r15,%r12), %r15
jne 0x23455
movq %r14, %rdi
movq %rbx, %rsi
movl $0x22, %edx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xe0bc