	.file	"extr_lsapilib.c_LSAPI_ForeachOrgHeader_r.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	LSAPI_ForeachOrgHeader_r
	.type	LSAPI_ForeachOrgHeader_r, @function
LSAPI_ForeachOrgHeader_r:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	lea	r11, -16384[rsp]
	.cfi_def_cfa 11, 16432
.LPSRL0:
	sub	rsp, 4096
	or	DWORD PTR [rsp], 0
	cmp	rsp, r11
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	sub	rsp, 16
	.cfi_def_cfa_offset 16448
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 16392[rsp], rax
	xor	eax, eax
	test	rdi, rdi
	je	.L17
	mov	rbp, rsi
	test	rsi, rsi
	je	.L17
	mov	rcx, QWORD PTR 24[rdi]
	test	rcx, rcx
	je	.L32
	mov	r12, rdx
	mov	edx, DWORD PTR H_TRANSFER_ENCODING[rip]
	test	edx, edx
	jle	.L3
	xor	r13d, r13d
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L34:
	mov	rcx, QWORD PTR 24[rdi]
.L6:
	mov	rdx, QWORD PTR [rcx]
	movsx	rdx, DWORD PTR [rdx+rax*4]
	test	edx, edx
	je	.L4
	mov	rcx, QWORD PTR 8[rcx]
	add	rdx, QWORD PTR [rdi]
	movsx	rcx, DWORD PTR [rcx+rax*4]
	mov	BYTE PTR [rdx+rcx], 0
	mov	rsi, rcx
	mov	rcx, QWORD PTR HTTP_HEADERS[rip]
	mov	r8, QWORD PTR [rcx+rax*8]
	movsx	rcx, r13d
	add	r13d, 1
	sal	rcx, 5
	mov	QWORD PTR [rsp+rcx], r8
	mov	r8, QWORD PTR HTTP_HEADER_LEN[rip]
	mov	r8d, DWORD PTR [r8+rax*4]
	mov	QWORD PTR 16[rsp+rcx], rdx
	mov	DWORD PTR 24[rsp+rcx], esi
	mov	DWORD PTR 8[rsp+rcx], r8d
.L4:
	add	rax, 1
	cmp	DWORD PTR H_TRANSFER_ENCODING[rip], eax
	jg	.L34
	mov	rax, QWORD PTR 8[rdi]
	mov	r10, QWORD PTR [rax]
	test	r10, r10
	jle	.L7
	mov	rax, QWORD PTR 16[rdi]
	sal	r10, 4
	add	r10, rax
	cmp	rax, r10
	jnb	.L7
.L14:
	movsx	rdx, r13d
	mov	rbx, rsp
	sal	rdx, 5
	add	rdx, rbx
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L35:
	add	rax, 16
	add	rdx, 32
	cmp	rax, r10
	jnb	.L8
.L9:
	movsx	rcx, DWORD PTR 4[rax]
	movsx	rsi, DWORD PTR [rax]
	add	r13d, 1
	add	rsi, QWORD PTR [rdi]
	mov	BYTE PTR [rsi+rcx], 0
	movsx	r9, DWORD PTR 12[rax]
	mov	r8, rcx
	movsx	rcx, DWORD PTR 8[rax]
	add	rcx, QWORD PTR [rdi]
	mov	BYTE PTR [rcx+r9], 0
	mov	DWORD PTR 8[rdx], r8d
	mov	QWORD PTR 16[rdx], rcx
	mov	ecx, DWORD PTR 12[rax]
	mov	QWORD PTR [rdx], rsi
	mov	DWORD PTR 24[rdx], ecx
	cmp	r13d, 512
	jne	.L35
.L8:
	mov	ecx, DWORD PTR compareValueLocation[rip]
	mov	edx, 32
	mov	esi, r13d
	mov	rdi, rbx
	call	qsort@PLT
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L7:
	mov	rbx, rsp
	mov	ecx, DWORD PTR compareValueLocation[rip]
	mov	edx, 32
	mov	esi, r13d
	mov	rdi, rbx
	call	qsort@PLT
	test	r13d, r13d
	je	.L32
.L11:
	xor	r14d, r14d
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L37:
	add	r14d, 1
	add	rbx, 32
	cmp	r14d, r13d
	jge	.L36
.L10:
	mov	ecx, DWORD PTR 24[rbx]
	mov	rdx, QWORD PTR 16[rbx]
	mov	r8, r12
	mov	esi, DWORD PTR 8[rbx]
	mov	rdi, QWORD PTR [rbx]
	call	rbp
	test	eax, eax
	jg	.L37
.L1:
	mov	rdi, QWORD PTR 16392[rsp]
	xor	rdi, QWORD PTR fs:40
	jne	.L38
	add	rsp, 16400
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L36:
	.cfi_restore_state
	mov	eax, r13d
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rax, QWORD PTR 8[rdi]
	mov	r10, QWORD PTR [rax]
	test	r10, r10
	jle	.L29
	mov	rax, QWORD PTR 16[rdi]
	sal	r10, 4
	xor	r13d, r13d
	add	r10, rax
	cmp	rax, r10
	jb	.L14
.L29:
	mov	ecx, DWORD PTR compareValueLocation[rip]
	mov	rdi, rsp
	mov	edx, 32
	xor	esi, esi
	call	qsort@PLT
	.p2align 4,,10
	.p2align 3
.L32:
	xor	eax, eax
	jmp	.L1
.L17:
	mov	eax, -1
	jmp	.L1
.L38:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	LSAPI_ForeachOrgHeader_r, .-LSAPI_ForeachOrgHeader_r
	.comm	compareValueLocation,4,4
	.comm	H_TRANSFER_ENCODING,4,4
	.comm	HTTP_HEADER_LEN,8,8
	.comm	HTTP_HEADERS,8,8
	.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_lsapilib.c_LSAPI_ForeachOrgHeader_r.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	LSAPI_ForeachOrgHeader_r
	.syntax unified
	.arm
	.fpu softvfp
	.type	LSAPI_ForeachOrgHeader_r, %function
LSAPI_ForeachOrgHeader_r:
	@ args = 0, pretend = 0, frame = 8200
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	clz	r4, r1
	cmp	r0, #0
	lsr	r4, r4, #5
	moveq	r4, #1
	sub	sp, sp, #8192
	sub	sp, sp, #20
	add	r3, sp, #8192
	mov	r7, r2
	ldr	r2, .L37
	cmp	r4, #0
	add	r3, r3, #12
	ldr	r2, [r2]
	str	r2, [r3]
	mov	r2,#0
	bne	.L15
	ldr	r2, [r0, #12]
	cmp	r2, #0
	moveq	r0, r2
	beq	.L1
	ldr	r8, .L37+4
	mov	r6, r1
	ldr	r3, [r8]
	cmp	r3, #0
	ble	.L3
	mov	ip, r4
	mov	fp, r4
	ldr	r10, .L37+8
	ldr	r9, .L37+12
	add	r3, sp, #16
	b	.L6
.L33:
	ldr	r2, [r0, #12]
.L6:
	ldr	r1, [r2]
	ldr	r1, [r1, ip, lsl #2]
	cmp	r1, #0
	beq	.L4
	ldr	lr, [r2, #4]
	ldr	r2, [r0]
	ldr	lr, [lr, ip, lsl #2]
	add	r2, r2, r1
	strb	fp, [r2, lr]
	ldr	r1, [r9]
	ldr	r5, [r10]
	ldr	r1, [r1, ip, lsl #2]
	ldr	r5, [r5, ip, lsl #2]
	str	r1, [r3, r4, lsl #4]
	add	r1, r3, r4, lsl #4
	str	r2, [r1, #4]
	str	r5, [r1, #-4]
	str	lr, [r1, #8]
	add	r4, r4, #1
.L4:
	ldr	r2, [r8]
	add	ip, ip, #1
	cmp	r2, ip
	bgt	.L33
	ldr	r2, [r0, #4]
	ldr	r2, [r2]
	cmp	r2, #0
	ble	.L7
.L12:
	ldr	ip, [r0, #8]
	add	r2, ip, r2, lsl #4
	cmp	ip, r2
	bcs	.L7
	mvn	r9, ip
	sub	r5, r3, #4
	add	r2, r2, r9
	add	r1, r4, #1
	add	r9, r1, r2, lsr #4
	mov	r8, #0
	add	r3, ip, #16
	add	r2, r5, r4, lsl #4
	b	.L9
.L34:
	cmp	r1, r9
	add	r3, r3, #16
	add	r2, r2, #16
	beq	.L8
	add	r1, r1, #1
.L9:
	ldr	ip, [r3, #-16]
	ldr	lr, [r0]
	ldr	r4, [r3, #-12]
	add	ip, lr, ip
	strb	r8, [ip, r4]
	ldr	fp, [r3, #-8]
	ldr	lr, [r0]
	ldr	r10, [r3, #-4]
	add	lr, lr, fp
	strb	r8, [lr, r10]
	str	r4, [r2, #4]
	ldr	r4, [r3, #-4]
	cmp	r1, #512
	str	r4, [r2, #12]
	str	lr, [r2, #8]
	mov	r4, r1
	str	ip, [r2]
	bne	.L34
.L8:
	ldr	r3, .L37+16
	mov	r2, #16
	mov	r0, r5
	ldr	r3, [r3]
	bl	qsort
	b	.L11
.L3:
	ldr	r3, [r0, #4]
	ldr	r2, [r3]
	cmp	r2, #0
	addgt	r3, sp, #16
	bgt	.L12
	ldr	r3, .L37+16
	mov	r2, #16
	mov	r1, r4
	ldr	r3, [r3]
	add	r0, sp, #12
	bl	qsort
.L31:
	mov	r0, r4
.L1:
	add	r3, sp, #8192
	ldr	r2, .L37
	add	r3, r3, #12
	ldr	r1, [r2]
	ldr	r2, [r3]
	eors	r1, r2, r1
	mov	r2, #0
	bne	.L35
	add	sp, sp, #8192
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L7:
	ldr	r2, .L37+16
	sub	r5, r3, #4
	mov	r0, r5
	ldr	r3, [r2]
	mov	r1, r4
	mov	r2, #16
	bl	qsort
	cmp	r4, #0
	beq	.L31
.L11:
	mov	r8, #0
	b	.L10
.L36:
	add	r8, r8, #1
	cmp	r8, r4
	add	r5, r5, #16
	bge	.L31
.L10:
	str	r7, [sp]
	ldm	r5, {r0, r1, r2, r3}
	blx	r6
	cmp	r0, #0
	bgt	.L36
	b	.L1
.L15:
	mvn	r0, #0
	b	.L1
.L35:
	bl	__stack_chk_fail
.L38:
	.align	2
.L37:
	.word	.LC0
	.word	H_TRANSFER_ENCODING
	.word	HTTP_HEADERS
	.word	HTTP_HEADER_LEN
	.word	compareValueLocation
	.size	LSAPI_ForeachOrgHeader_r, .-LSAPI_ForeachOrgHeader_r
	.comm	compareValueLocation,4,4
	.comm	H_TRANSFER_ENCODING,4,4
	.comm	HTTP_HEADER_LEN,4,4
	.comm	HTTP_HEADERS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
