	.file	"extr_listcomp.c_bwrite_gamma_code.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	bwrite_gamma_code
	.type	bwrite_gamma_code, @function
bwrite_gamma_code:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12d, esi
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	xor	edi, edi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	test	esi, esi
	setne	dil
	call	assert@PLT
	mov	edi, r12d
	call	bsr@PLT
	btc	r12d, eax
	test	eax, eax
	mov	r13d, eax
	mov	eax, DWORD PTR 0[rbp]
	jle	.L5
	xor	ebx, ebx
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rcx, QWORD PTR 8[rbp]
	add	ebx, 1
	add	DWORD PTR [rcx], eax
	mov	eax, DWORD PTR 0[rbp]
	sar	eax
	mov	DWORD PTR 0[rbp], eax
	cmp	r13d, ebx
	je	.L5
.L4:
	test	eax, eax
	jne	.L3
	xor	esi, esi
	mov	rdi, rbp
	call	bwrite_append@PLT
	mov	DWORD PTR 0[rbp], 128
	mov	eax, 128
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L5:
	test	eax, eax
	je	.L6
	sar	eax
.L7:
	mov	DWORD PTR 0[rbp], eax
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	edx, r13d
	mov	esi, r12d
	pop	rbx
	.cfi_def_cfa_offset 32
	mov	rdi, rbp
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	bwrite_nbits@PLT
	.p2align 4,,10
	.p2align 3
.L6:
	.cfi_restore_state
	xor	esi, esi
	mov	rdi, rbp
	call	bwrite_append@PLT
	mov	eax, 64
	jmp	.L7
	.cfi_endproc
.LFE0:
	.size	bwrite_gamma_code, .-bwrite_gamma_code
	.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_listcomp.c_bwrite_gamma_code.c"
	.text
	.align	2
	.global	bwrite_gamma_code
	.syntax unified
	.arm
	.fpu softvfp
	.type	bwrite_gamma_code, %function
bwrite_gamma_code:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r6, r1
	mov	r4, r0
	subs	r0, r1, #0
	movne	r0, #1
	bl	assert
	mov	r0, r6
	bl	bsr
	mov	r1, #1
	cmp	r0, #0
	mov	r8, r0
	eor	r6, r6, r1, lsl r0
	ble	.L2
	mov	r5, #0
	mov	r7, #128
	ldr	r1, [r4]
	b	.L4
.L3:
	ldr	r2, [r4, #4]
	cmp	r8, r5
	ldr	r3, [r2]
	add	r1, r3, r1
	str	r1, [r2]
	ldr	r1, [r4]
	asr	r1, r1, #1
	str	r1, [r4]
	beq	.L5
.L4:
	cmp	r1, #0
	add	r5, r5, #1
	bne	.L3
	mov	r0, r4
	bl	bwrite_append
	mov	r1, #128
	str	r7, [r4]
	b	.L3
.L2:
	ldr	r1, [r4]
.L5:
	cmp	r1, #0
	asrne	r1, r1, #1
	beq	.L11
.L7:
	str	r1, [r4]
	mov	r2, r8
	mov	r1, r6
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, lr}
	b	bwrite_nbits
.L11:
	mov	r0, r4
	bl	bwrite_append
	mov	r1, #64
	b	.L7
	.size	bwrite_gamma_code, .-bwrite_gamma_code
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
