	.file	"extr_refs.c_update_wt_heads.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"could not read HEAD when renaming references"
	.align 8
.LC1:
	.string	"failed to update HEAD after renaming reference"
	.text
	.p2align 4
	.type	update_wt_heads, @function
update_wt_heads:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	mov	r8, rdi
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rsi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	rbx, rdx
	mov	rdx, rsi
	mov	rsi, r8
	sub	rsp, 16
	.cfi_def_cfa_offset 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	rdi, rsp
	mov	QWORD PTR [rsp], 0
	call	git_reference__read_head@PLT
	test	eax, eax
	js	.L10
	mov	rdi, rbp
	call	git_path_dirname@PLT
	mov	rbp, rax
	test	rax, rax
	je	.L5
	mov	rdi, QWORD PTR [rsp]
	xor	r12d, r12d
	call	git_reference_type@PLT
	cmp	rax, QWORD PTR GIT_REFERENCE_SYMBOLIC[rip]
	je	.L11
.L3:
	mov	rdi, QWORD PTR [rsp]
	call	git_reference_free@PLT
	mov	rdi, rbp
	call	git__free@PLT
	mov	rax, QWORD PTR 8[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L12
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	mov	rax, QWORD PTR [rsp]
	mov	esi, DWORD PTR 4[rbx]
	mov	edi, DWORD PTR [rax]
	call	git__strcmp@PLT
	test	rax, rax
	jne	.L3
	mov	esi, DWORD PTR [rbx]
	mov	rdi, rbp
	call	git_repository_create_head@PLT
	mov	r12d, eax
	test	eax, eax
	jns	.L3
	mov	edi, DWORD PTR GIT_ERROR_REFERENCE[rip]
	lea	rsi, .LC1[rip]
	call	git_error_set@PLT
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L10:
	mov	edi, DWORD PTR GIT_ERROR_REFERENCE[rip]
	lea	rsi, .LC0[rip]
	mov	r12d, eax
	xor	ebp, ebp
	call	git_error_set@PLT
	jmp	.L3
.L5:
	mov	r12d, -1
	jmp	.L3
.L12:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	update_wt_heads, .-update_wt_heads
	.comm	GIT_REFERENCE_SYMBOLIC,8,8
	.comm	GIT_ERROR_REFERENCE,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_refs.c_update_wt_heads.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"could not read HEAD when renaming references\000"
	.align	2
.LC1:
	.ascii	"failed to update HEAD after renaming reference\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	update_wt_heads, %function
update_wt_heads:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, lr}
	mov	r5, r1
	mov	r7, #0
	sub	sp, sp, #12
	ldr	r3, .L13
	mov	r1, r0
	mov	r6, r2
	mov	r0, sp
	mov	r2, r5
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	str	r7, [sp]
	bl	git_reference__read_head
	subs	r4, r0, #0
	blt	.L10
	mov	r0, r5
	bl	git_path_dirname
	subs	r5, r0, #0
	beq	.L5
	ldr	r0, [sp]
	bl	git_reference_type
	ldr	r3, .L13+4
	ldr	r3, [r3]
	cmp	r0, r3
	beq	.L11
.L7:
	mov	r4, r7
.L3:
	ldr	r0, [sp]
	bl	git_reference_free
	mov	r0, r5
	bl	git__free
	ldr	r3, .L13
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L12
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L11:
	ldr	r3, [sp]
	ldr	r1, [r6, #4]
	ldr	r0, [r3]
	bl	git__strcmp
	cmp	r0, #0
	bne	.L7
	mov	r0, r5
	ldr	r1, [r6]
	bl	git_repository_create_head
	subs	r4, r0, #0
	bge	.L3
	ldr	r3, .L13+8
	ldr	r1, .L13+12
	ldr	r0, [r3]
	bl	git_error_set
	b	.L3
.L10:
	ldr	r3, .L13+8
	ldr	r1, .L13+16
	ldr	r0, [r3]
	mov	r5, r7
	bl	git_error_set
	b	.L3
.L5:
	mvn	r4, #0
	b	.L3
.L12:
	bl	__stack_chk_fail
.L14:
	.align	2
.L13:
	.word	.LC2
	.word	GIT_REFERENCE_SYMBOLIC
	.word	GIT_ERROR_REFERENCE
	.word	.LC1
	.word	.LC0
	.size	update_wt_heads, .-update_wt_heads
	.comm	GIT_REFERENCE_SYMBOLIC,4,4
	.comm	GIT_ERROR_REFERENCE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
