	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_towide_gb18030                 ## -- Begin function towide_gb18030
	.p2align	4, 0x90
_towide_gb18030:                        ## @towide_gb18030
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	(%rsi), %r10d
	testb	$-128, %r10b
	jne	LBB0_2
## %bb.1:
	movl	%r10d, (%rdi)
	movl	$1, %eax
	popq	%rbp
	retq
LBB0_2:
	cmpl	$1, %edx
	ja	LBB0_5
## %bb.3:
	movq	%rsi, %rdi
	callq	_show_mb
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_4
LBB0_5:
	movl	%r10d, %r9d
	shll	$8, %r9d
	movl	%r10d, %eax
	shll	$16, %eax
	movl	%r10d, %ecx
	shrl	$8, %ecx
	movsbl	%cl, %r8d
	orl	%r9d, %r8d
	shrl	$24, %eax
	addl	$-48, %eax
	cmpl	$9, %eax
	ja	LBB0_9
## %bb.6:
	cmpl	$3, %edx
	ja	LBB0_8
## %bb.7:
	movq	%rsi, %rdi
	callq	_show_mb
	leaq	L_.str.1(%rip), %rdi
LBB0_4:
	movl	%eax, %esi
	callq	_werr
	movl	$-1, %eax
	popq	%rbp
	retq
LBB0_9:
	movl	%r8d, (%rdi)
	movl	$2, %eax
	popq	%rbp
	retq
LBB0_8:
	shll	$16, %r8d
	sarl	$16, %r9d
	andl	$-256, %r9d
	sarl	$24, %r10d
	orl	%r9d, %r10d
	orl	%r8d, %r10d
	movl	%r10d, (%rdi)
	movl	$4, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"incomplete character sequence (%s)"

L_.str.1:                               ## @.str.1
	.asciz	"incomplete 4-byte character sequence (%s)"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_towide_gb18030                 ; -- Begin function towide_gb18030
	.p2align	2
_towide_gb18030:                        ; @towide_gb18030
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	ldr	w8, [x1]
	tbnz	w8, #7, LBB0_2
; %bb.1:
	str	w8, [x0]
	mov	w0, #1
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_2:
	cmp	w2, #1
	b.hi	LBB0_4
; %bb.3:
	mov	x0, x1
	bl	_show_mb
	mov	x1, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_7
LBB0_4:
	lsl	w10, w8, #8
	lsl	w9, w8, #16
	orr	w9, w10, w9, asr #24
	ubfx	w11, w8, #8, #8
	sub	w11, w11, #48
	cmp	w11, #9
	b.hi	LBB0_8
; %bb.5:
	cmp	w2, #3
	b.hi	LBB0_9
; %bb.6:
	mov	x0, x1
	bl	_show_mb
	mov	x1, x0
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_7:
	bl	_werr
	mov	w0, #-1
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_8:
	str	w9, [x0]
	mov	w0, #2
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_9:
	asr	w10, w10, #16
	and	w10, w10, #0xffffff00
	orr	w9, w10, w9, lsl #16
	orr	w8, w9, w8, asr #24
	str	w8, [x0]
	mov	w0, #4
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"incomplete character sequence (%s)"

l_.str.1:                               ; @.str.1
	.asciz	"incomplete 4-byte character sequence (%s)"

.subsections_via_symbols
