	.file	"extr_pex-win32.c_argv_to_cmdline.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	argv_to_cmdline, @function
argv_to_cmdline:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	rbx, rdi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	rsi, QWORD PTR [rdi]
	test	rsi, rsi
	je	.L25
	lea	r10, 8[rdi]
	xor	edi, edi
	.p2align 4,,10
	.p2align 3
.L3:
	movzx	edx, BYTE PTR [rsi]
	xor	r8d, r8d
	lea	rbp, -1[rsi]
	lea	r11, -2[rsi]
	test	dl, dl
	jne	.L9
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L4:
	add	r8, 1
	movzx	edx, BYTE PTR [rsi+r8]
	test	dl, dl
	je	.L47
.L9:
	movsx	r9, r8d
	cmp	dl, 34
	jne	.L4
	lea	edx, -1[r8]
	test	r8d, r8d
	je	.L44
	lea	rcx, [r11+r8]
	lea	rax, 0[rbp+r8]
	sub	rcx, rdx
	lea	rdx, [rsi+rdi]
	add	rdx, r8
	.p2align 4,,10
	.p2align 3
.L7:
	mov	rdi, rdx
	sub	rdi, rax
	cmp	BYTE PTR [rax], 92
	jne	.L4
	sub	rax, 1
	cmp	rax, rcx
	jne	.L7
.L44:
	add	r8, 1
	add	rdi, 1
	movzx	edx, BYTE PTR [rsi+r8]
	test	dl, dl
	jne	.L9
	.p2align 4,,10
	.p2align 3
.L47:
	lea	rax, [rsi+r9]
	lea	rdx, 1[rdi+r9]
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L13:
	add	rdi, 1
	sub	rax, 1
	cmp	rdi, rdx
	je	.L45
.L11:
	cmp	BYTE PTR [rax], 92
	je	.L13
.L45:
	add	rdi, r8
.L12:
	mov	rsi, QWORD PTR [r10]
	add	r10, 8
	add	rdi, 3
	test	rsi, rsi
	jne	.L3
.L2:
	call	xmalloc@PLT
	cmp	QWORD PTR [rbx], 0
	mov	rsi, rax
	je	.L14
	.p2align 4,,10
	.p2align 3
.L24:
	mov	BYTE PTR [rsi], 34
	mov	r11, QWORD PTR [rbx]
	lea	rcx, 1[rsi]
	movzx	edi, BYTE PTR [r11]
	test	dil, dil
	je	.L28
	xor	r10d, r10d
	jmp	.L21
	.p2align 4,,10
	.p2align 3
.L29:
	mov	rsi, rdx
	mov	rdx, rcx
	mov	rcx, rsi
.L16:
	movzx	esi, BYTE PTR [r11+r10]
	add	r10, 1
	mov	BYTE PTR [rdx], sil
	mov	rsi, QWORD PTR [rbx]
	movzx	edi, BYTE PTR [rsi+r10]
	mov	r11, rsi
	test	dil, dil
	je	.L48
.L21:
	mov	ebp, r10d
	lea	rdx, 1[rcx]
	cmp	dil, 34
	jne	.L29
	lea	esi, -1[r10]
	test	r10d, r10d
	je	.L49
	lea	rdi, 1[rcx+rsi]
	mov	rdx, rcx
	lea	rsi, 1[rcx]
	lea	r9, -1[rcx+r10]
	jmp	.L19
	.p2align 4,,10
	.p2align 3
.L20:
	mov	BYTE PTR -1[rdx], 92
	cmp	rdi, rdx
	je	.L42
	mov	r11, QWORD PTR [rbx]
.L19:
	mov	rcx, r9
	mov	r8, rdx
	sub	rcx, rdx
	mov	rdx, rsi
	lea	rsi, 1[rsi]
	cmp	BYTE PTR [r11+rcx], 92
	je	.L20
	mov	rcx, rsi
.L18:
	mov	BYTE PTR [r8], 92
	mov	r11, QWORD PTR [rbx]
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L48:
	movsx	rdi, ebp
	mov	rdx, rcx
	lea	r8, 1[rcx+rdi]
	lea	rcx, [rcx+rdi]
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L23:
	add	rdx, 1
	mov	BYTE PTR -1[rdx], 92
	cmp	rdx, r8
	je	.L15
	mov	rsi, QWORD PTR [rbx]
.L22:
	mov	rdi, rcx
	sub	rdi, rdx
	cmp	BYTE PTR [rsi+rdi], 92
	je	.L23
.L15:
	mov	ecx, 8226
	add	rbx, 8
	lea	rsi, 2[rdx]
	mov	WORD PTR [rdx], cx
	cmp	QWORD PTR [rbx], 0
	jne	.L24
.L14:
	mov	BYTE PTR -1[rsi], 0
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L42:
	.cfi_restore_state
	lea	rcx, 2[rdx]
	mov	r8, rdi
	mov	rdx, rsi
	jmp	.L18
.L28:
	mov	rdx, rcx
	jmp	.L15
.L49:
	mov	r8, rcx
	add	rcx, 2
	jmp	.L18
.L25:
	xor	edi, edi
	jmp	.L2
	.cfi_endproc
.LFE0:
	.size	argv_to_cmdline, .-argv_to_cmdline
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_pex-win32.c_argv_to_cmdline.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	argv_to_cmdline, %function
argv_to_cmdline:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r1, [r0]
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	cmp	r1, #0
	mov	r4, r0
	beq	.L25
	mov	r6, r0
	mov	r0, #0
.L3:
	ldrb	r3, [r1]	@ zero_extendqisi2
	cmp	r3, #0
	movne	r7, r1
	movne	r5, #0
	bne	.L9
	b	.L12
.L4:
	ldrb	r3, [r7, #1]!	@ zero_extendqisi2
	add	r2, r5, #1
	cmp	r3, #0
	beq	.L46
.L26:
	mov	r5, r2
.L9:
	cmp	r3, #34
	bne	.L4
	cmp	r5, #0
	addeq	r0, r0, #1
	beq	.L4
	add	r2, r1, r5
	b	.L7
.L8:
	cmp	ip, r1
	beq	.L47
.L7:
	sub	r2, r2, #1
	ldrb	lr, [r2]	@ zero_extendqisi2
	sub	r3, r1, r2
	add	r3, r3, r0
	cmp	lr, #92
	mov	ip, r2
	add	r3, r3, r5
	beq	.L8
	mov	r0, r3
	ldrb	r3, [r7, #1]!	@ zero_extendqisi2
	add	r2, r5, #1
	cmp	r3, #0
	bne	.L26
.L46:
	add	r3, r0, #1
	add	r1, r1, r2
	add	r5, r3, r5
	b	.L11
.L13:
	add	r0, r0, #1
	cmp	r5, r0
	beq	.L44
.L11:
	ldrb	r3, [r1, #-1]!	@ zero_extendqisi2
	cmp	r3, #92
	beq	.L13
.L44:
	add	r0, r0, r2
.L12:
	ldr	r1, [r6, #4]!
	add	r0, r0, #3
	cmp	r1, #0
	bne	.L3
.L2:
	bl	xmalloc
	ldr	r3, [r4]
	cmp	r3, #0
	mov	r3, r0
	beq	.L15
	mov	r6, #34
	mov	r7, #92
	mov	r8, #32
.L24:
	strb	r6, [r3], #1
	ldr	r5, [r4]
	ldrb	r1, [r5]	@ zero_extendqisi2
	cmp	r1, #0
	beq	.L28
	mov	ip, #0
	b	.L21
.L17:
	ldrb	r2, [r5, ip]	@ zero_extendqisi2
	add	ip, ip, #1
	strb	r2, [lr]
	ldr	r2, [r4]
	ldrb	r1, [r2, ip]	@ zero_extendqisi2
	mov	r5, r2
	cmp	r1, #0
	beq	.L48
.L21:
	add	lr, r3, #1
	mov	r2, lr
	cmp	r1, #34
	movne	lr, r3
	mov	r9, ip
	movne	r3, r2
	bne	.L17
	cmp	ip, #0
	moveq	r10, r3
	sub	r1, ip, #1
	addeq	r3, r3, #2
	bne	.L18
	b	.L19
.L20:
	cmn	r1, #1
	strb	r5, [r3, #-1]
	beq	.L42
	ldr	r5, [r4]
.L18:
	ldrb	r5, [r5, r1]	@ zero_extendqisi2
	mov	r10, r3
	cmp	r5, #92
	mov	r3, r2
	add	r2, r2, #1
	mov	lr, r2
	sub	r1, r1, #1
	beq	.L20
	mov	lr, r3
	mov	r3, r2
.L19:
	strb	r7, [r10]
	ldr	r5, [r4]
	b	.L17
.L48:
	add	ip, r9, #1
	mov	r1, r3
	add	r9, r3, r9
	add	r3, r3, ip
	b	.L22
.L23:
	strb	r2, [r1], #1
	cmp	r1, r3
	beq	.L16
	ldr	r2, [r4]
.L22:
	sub	ip, r9, r1
	ldrb	r2, [r2, ip]	@ zero_extendqisi2
	cmp	r2, #92
	beq	.L23
.L16:
	mov	r3, r1
	strb	r6, [r3], #2
	strb	r8, [r1, #1]
	ldr	r2, [r4, #4]!
	cmp	r2, #0
	bne	.L24
.L15:
	mov	r2, #0
	strb	r2, [r3, #-1]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L47:
	add	r0, r3, #1
	b	.L4
.L42:
	mov	r10, r3
	add	r3, lr, #1
	b	.L19
.L28:
	mov	r1, r3
	b	.L16
.L25:
	mov	r0, r1
	b	.L2
	.size	argv_to_cmdline, .-argv_to_cmdline
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
