	.file	"extr_path.c_git_path_dirname_r.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"/"
.LC1:
	.string	"."
.LC2:
	.string	"path too long"
	.text
	.p2align 4
	.globl	git_path_dirname_r
	.type	git_path_dirname_r, @function
git_path_dirname_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
	mov	r13, rdi
	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
	test	rsi, rsi
	je	.L2
	cmp	BYTE PTR [rsi], 0
	mov	rbp, rsi
	jne	.L40
.L2:
	mov	r12d, 1
	xor	r14d, r14d
	lea	rbp, .LC1[rip]
.L7:
	test	r13, r13
	je	.L1
	mov	edx, r12d
	mov	rsi, rbp
	mov	rdi, r13
	call	git_buf_set@PLT
	test	rax, rax
	js	.L18
	test	r14d, r14d
	jne	.L41
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	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
.L40:
	.cfi_restore_state
	mov	rdi, rsi
	call	strlen@PLT
	cdqe
	lea	rbx, -1[rbp+rax]
	cmp	rbp, rbx
	jb	.L3
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	sub	rbx, 1
	cmp	rbp, rbx
	je	.L4
.L3:
	cmp	BYTE PTR [rbx], 47
	je	.L5
.L4:
	mov	rsi, rbx
	movsx	rax, DWORD PTR INT_MAX[rip]
	sub	rsi, rbp
	cmp	rsi, rax
	jge	.L38
	add	esi, 1
	mov	rdi, rbp
	mov	r14d, 1
	call	win32_prefix_length@PLT
	mov	r12d, eax
	test	eax, eax
	jg	.L7
	cmp	rbp, rbx
	jb	.L8
	jmp	.L42
	.p2align 4,,10
	.p2align 3
.L11:
	sub	rbx, 1
	cmp	rbp, rbx
	je	.L10
.L8:
	cmp	BYTE PTR [rbx], 47
	jne	.L11
	cmp	rbp, rbx
	jne	.L15
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L43:
	cmp	BYTE PTR [rbx], 47
	jne	.L14
.L15:
	sub	rbx, 1
	cmp	rbp, rbx
	jb	.L43
.L14:
	movsx	rax, DWORD PTR INT_MAX[rip]
	sub	rbx, rbp
	cmp	rbx, rax
	jge	.L38
	lea	r12d, 1[rbx]
	mov	rdi, rbp
	mov	esi, r12d
	call	win32_prefix_length@PLT
	test	eax, eax
	setg	r14b
	cmovg	r12d, eax
	movzx	r14d, r14b
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L41:
	mov	esi, 47
	mov	rdi, r13
	call	git_buf_putc@PLT
	test	rax, rax
	jns	.L1
.L18:
	mov	r12d, -1
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L38:
	mov	edi, DWORD PTR GIT_ERROR_INVALID[rip]
	lea	rsi, .LC2[rip]
	mov	r12d, -1
	xor	r14d, r14d
	call	git_error_set@PLT
	jmp	.L7
.L42:
	jne	.L15
	.p2align 4,,10
	.p2align 3
.L10:
	cmp	BYTE PTR [rbx], 47
	jne	.L2
.L22:
	mov	r12d, 1
	xor	r14d, r14d
	lea	rbp, .LC0[rip]
	jmp	.L7
	.cfi_endproc
.LFE0:
	.size	git_path_dirname_r, .-git_path_dirname_r
	.comm	INT_MAX,4,4
	.comm	GIT_ERROR_INVALID,4,4
	.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_path.c_git_path_dirname_r.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"/\000"
	.align	2
.LC1:
	.ascii	".\000"
	.align	2
.LC2:
	.ascii	"path too long\000"
	.text
	.align	2
	.global	git_path_dirname_r
	.syntax unified
	.arm
	.fpu softvfp
	.type	git_path_dirname_r, %function
git_path_dirname_r:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	subs	r5, r1, #0
	mov	r7, r0
	beq	.L2
	ldrb	r3, [r5]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L2
	mov	r0, r5
	bl	strlen
	sub	r4, r0, #1
	add	r4, r5, r4
	cmp	r5, r4
	bcs	.L3
	mov	r3, r4
	b	.L4
.L5:
	cmp	r3, r5
	mov	r4, r3
	beq	.L3
.L4:
	ldrb	r2, [r3]	@ zero_extendqisi2
	mov	r4, r3
	cmp	r2, #47
	sub	r3, r3, #1
	beq	.L5
.L3:
	ldr	r8, .L45
	sub	r1, r4, r5
	ldr	r3, [r8]
	cmp	r1, r3
	bge	.L41
	mov	r0, r5
	add	r1, r1, #1
	bl	win32_prefix_length
	subs	r6, r0, #0
	movgt	r4, #1
	bgt	.L7
	cmp	r5, r4
	bcs	.L8
	mov	r3, r4
	b	.L9
.L10:
	cmp	r3, r5
	mov	r4, r3
	beq	.L8
.L9:
	ldrb	r2, [r3]	@ zero_extendqisi2
	mov	r4, r3
	cmp	r2, #47
	sub	r3, r3, #1
	bne	.L10
	cmp	r5, r4
	beq	.L21
.L12:
	sub	r4, r4, #1
	b	.L14
.L43:
	ldrb	r2, [r4]	@ zero_extendqisi2
	sub	r4, r4, #1
	cmp	r2, #47
	bne	.L13
.L14:
	cmp	r5, r4
	mov	r3, r4
	bcc	.L43
.L13:
	ldr	r2, [r8]
	sub	r3, r3, r5
	cmp	r3, r2
	bge	.L41
	add	r6, r3, #1
	mov	r1, r6
	mov	r0, r5
	bl	win32_prefix_length
	cmp	r0, #0
	movgt	r6, r0
	movgt	r4, #1
	movle	r4, #0
	b	.L7
.L41:
	ldr	r3, .L45+4
	ldr	r1, .L45+8
	ldr	r0, [r3]
	bl	git_error_set
	mvn	r6, #0
	mov	r4, #0
.L7:
	cmp	r7, #0
	beq	.L1
	mov	r1, r5
	mov	r2, r6
	mov	r0, r7
	bl	git_buf_set
	cmp	r0, #0
	blt	.L17
	cmp	r4, #0
	bne	.L44
.L1:
	mov	r0, r6
	pop	{r4, r5, r6, r7, r8, pc}
.L2:
	mov	r6, #1
	mov	r4, #0
	ldr	r5, .L45+12
	b	.L7
.L8:
	cmp	r5, r4
	bne	.L12
	ldrb	r3, [r5]	@ zero_extendqisi2
	cmp	r3, #47
	bne	.L2
.L21:
	mov	r6, #1
	mov	r4, #0
	ldr	r5, .L45+16
	b	.L7
.L44:
	mov	r0, r7
	mov	r1, #47
	bl	git_buf_putc
	cmp	r0, #0
	bge	.L1
.L17:
	mvn	r6, #0
	b	.L1
.L46:
	.align	2
.L45:
	.word	INT_MAX
	.word	GIT_ERROR_INVALID
	.word	.LC2
	.word	.LC1
	.word	.LC0
	.size	git_path_dirname_r, .-git_path_dirname_r
	.comm	INT_MAX,4,4
	.comm	GIT_ERROR_INVALID,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
