	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dbm_map                        ## -- Begin function dbm_map
	.p2align	4, 0x90
_dbm_map:                               ## @dbm_map
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_O_RDONLY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_open
	movl	%eax, %edi
	movq	_ifd@GOTPCREL(%rip), %r12
	movl	%eax, (%r12)
	movl	$-1, %eax
	cmpl	$-1, %edi
	je	LBB0_22
## %bb.1:
	movq	_st@GOTPCREL(%rip), %r14
	movq	%r14, %rsi
	callq	_fstat
	cmpl	$-1, %eax
	je	LBB0_21
## %bb.2:
	movl	(%r14), %esi
	cmpl	$4, %esi
	jg	LBB0_5
## %bb.3:
	leaq	L_.str(%rip), %rdi
LBB0_4:
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_warnx
LBB0_19:
	movq	_EFTYPE@GOTPCREL(%rip), %r15
	jmp	LBB0_20
LBB0_5:
	movq	_INT32_MAX@GOTPCREL(%rip), %rax
	cmpl	(%rax), %esi
	jle	LBB0_7
## %bb.6:
	movq	_EFBIG@GOTPCREL(%rip), %r15
LBB0_20:
	movl	(%r15), %eax
	movq	_errno@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_21:
	movq	_errno@GOTPCREL(%rip), %r14
	movl	(%r14), %ebx
	movl	(%r12), %edi
	callq	_close
	movl	%ebx, (%r14)
	movl	$-1, %eax
LBB0_22:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_PROT_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_MAP_SHARED@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	(%r12), %r8d
	xorl	%edi, %edi
	xorl	%r9d, %r9d
	callq	_mmap
	movq	_dbm_base@GOTPCREL(%rip), %r13
	movl	%eax, (%r13)
	movq	_MAP_FAILED@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_21
## %bb.8:
	xorl	%edi, %edi
	callq	_dbm_getint
	movq	%rax, %r15
	movl	(%rax), %edi
	callq	_be32toh
	movq	_MANDOCDB_MAGIC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_14
## %bb.9:
	movl	$1, %edi
	callq	_dbm_getint
	movq	%rax, %r15
	movl	(%rax), %edi
	callq	_be32toh
	movq	_MANDOCDB_VERSION@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jne	LBB0_16
## %bb.10:
	movl	$3, %edi
	callq	_dbm_getint
	movl	(%rax), %edi
	callq	_be32toh
	addq	$4, %rax
	movq	_max_offset@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movslq	(%r14), %rdx
	cmpq	%rdx, %rax
	jne	LBB0_24
## %bb.11:
	movl	$3, %edi
	callq	_dbm_getint
	movl	(%rax), %edi
	callq	_dbm_get
	movq	_EFTYPE@GOTPCREL(%rip), %r15
	testq	%rax, %rax
	je	LBB0_20
## %bb.12:
	movq	%rax, %r14
	movl	(%rax), %edi
	callq	_be32toh
	movq	%rax, %rcx
	xorl	%eax, %eax
	movq	_MANDOCDB_MAGIC@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rcx
	je	LBB0_22
## %bb.13:
	movl	(%r14), %edi
	callq	_be32toh
	movq	(%r13), %rcx
	leaq	L_.str.6(%rip), %rdi
	movq	%rbx, %rsi
	movq	%rax, %rdx
	xorl	%eax, %eax
	callq	_warnx
	jmp	LBB0_20
LBB0_14:
	movl	(%r13), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	$15, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_23
## %bb.15:
	movl	(%r15), %edi
	callq	_be32toh
	movq	_MANDOCDB_MAGIC@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_17
LBB0_16:
	movl	(%r15), %edi
	callq	_be32toh
	movq	(%r13), %rcx
	leaq	L_.str.4(%rip), %rdi
LBB0_17:
	movq	%rbx, %rsi
	movq	%rax, %rdx
LBB0_18:
	xorl	%eax, %eax
	callq	_warnx
	jmp	LBB0_19
LBB0_23:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_4
LBB0_24:
	leaq	L_.str.5(%rip), %rdi
	movq	%rbx, %rsi
	movq	%rax, %rcx
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.comm	_O_RDONLY,4,2                   ## @O_RDONLY
	.comm	_ifd,4,2                        ## @ifd
	.comm	_st,4,2                         ## @st
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"dbm_map(%s): File too short"

	.comm	_EFTYPE,4,2                     ## @EFTYPE
	.comm	_errno,4,2                      ## @errno
	.comm	_INT32_MAX,4,2                  ## @INT32_MAX
	.comm	_EFBIG,4,2                      ## @EFBIG
	.comm	_PROT_READ,4,2                  ## @PROT_READ
	.comm	_MAP_SHARED,4,2                 ## @MAP_SHARED
	.comm	_dbm_base,4,2                   ## @dbm_base
	.comm	_MAP_FAILED,4,2                 ## @MAP_FAILED
	.comm	_MANDOCDB_MAGIC,8,3             ## @MANDOCDB_MAGIC
L_.str.1:                               ## @.str.1
	.asciz	"SQLite format 3"

L_.str.2:                               ## @.str.2
	.asciz	"dbm_map(%s): Bad initial magic %x (expected %x)"

L_.str.3:                               ## @.str.3
	.asciz	"dbm_map(%s): Obsolete format based on SQLite 3"

	.comm	_MANDOCDB_VERSION,8,3           ## @MANDOCDB_VERSION
L_.str.4:                               ## @.str.4
	.asciz	"dbm_map(%s): Bad version number %d (expected %d)"

	.comm	_max_offset,8,3                 ## @max_offset
L_.str.5:                               ## @.str.5
	.asciz	"dbm_map(%s): Inconsistent file size %lld (expected %d)"

L_.str.6:                               ## @.str.6
	.asciz	"dbm_map(%s): Bad final magic %x (expected %x)"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dbm_map                        ; -- Begin function dbm_map
	.p2align	2
_dbm_map:                               ; @dbm_map
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
Lloh0:
	adrp	x8, _O_RDONLY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _O_RDONLY@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_open
Lloh3:
	adrp	x22, _ifd@GOTPAGE
Lloh4:
	ldr	x22, [x22, _ifd@GOTPAGEOFF]
	str	w0, [x22]
	cmn	w0, #1
	b.eq	LBB0_10
; %bb.1:
Lloh5:
	adrp	x20, _st@GOTPAGE
Lloh6:
	ldr	x20, [x20, _st@GOTPAGEOFF]
	mov	x1, x20
	bl	_fstat
Lloh7:
	adrp	x23, _errno@GOTPAGE
Lloh8:
	ldr	x23, [x23, _errno@GOTPAGEOFF]
	cmn	w0, #1
	b.eq	LBB0_9
; %bb.2:
	ldr	w1, [x20]
	cmp	w1, #4
	b.gt	LBB0_6
; %bb.3:
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
LBB0_4:
	mov	x1, x19
	bl	_warnx
LBB0_5:
Lloh11:
	adrp	x8, _EFTYPE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EFTYPE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
Lloh13:
	adrp	x8, _INT32_MAX@GOTPAGE
Lloh14:
	ldr	x8, [x8, _INT32_MAX@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	cmp	w1, w8
	b.le	LBB0_11
; %bb.7:
Lloh16:
	adrp	x8, _EFBIG@GOTPAGE
Lloh17:
	ldr	x8, [x8, _EFBIG@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	str	w8, [x23]
LBB0_9:
	ldr	w19, [x23]
	ldr	w0, [x22]
	bl	_close
	str	w19, [x23]
	mov	w0, #-1
LBB0_10:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_11:
Lloh18:
	adrp	x8, _PROT_READ@GOTPAGE
Lloh19:
	ldr	x8, [x8, _PROT_READ@GOTPAGEOFF]
Lloh20:
	ldr	w2, [x8]
Lloh21:
	adrp	x8, _MAP_SHARED@GOTPAGE
Lloh22:
	ldr	x8, [x8, _MAP_SHARED@GOTPAGEOFF]
Lloh23:
	ldr	w3, [x8]
	ldr	w4, [x22]
	mov	x0, #0
	mov	w5, #0
	bl	_mmap
Lloh24:
	adrp	x25, _dbm_base@GOTPAGE
Lloh25:
	ldr	x25, [x25, _dbm_base@GOTPAGEOFF]
	str	w0, [x25]
Lloh26:
	adrp	x8, _MAP_FAILED@GOTPAGE
Lloh27:
	ldr	x8, [x8, _MAP_FAILED@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	cmp	w0, w8
	b.eq	LBB0_9
; %bb.12:
	mov	w0, #0
	bl	_dbm_getint
	mov	x21, x0
	ldr	w0, [x0]
	bl	_be32toh
Lloh29:
	adrp	x24, _MANDOCDB_MAGIC@GOTPAGE
Lloh30:
	ldr	x24, [x24, _MANDOCDB_MAGIC@GOTPAGEOFF]
	ldr	x8, [x24]
	cmp	x0, x8
	b.ne	LBB0_18
; %bb.13:
	mov	w0, #1
	bl	_dbm_getint
	mov	x21, x0
	ldr	w0, [x0]
	bl	_be32toh
Lloh31:
	adrp	x25, _MANDOCDB_VERSION@GOTPAGE
Lloh32:
	ldr	x25, [x25, _MANDOCDB_VERSION@GOTPAGEOFF]
	ldr	x8, [x25]
	cmp	x0, x8
	b.ne	LBB0_20
; %bb.14:
	mov	w0, #3
	bl	_dbm_getint
	ldr	w0, [x0]
	bl	_be32toh
	add	x8, x0, #4
Lloh33:
	adrp	x9, _max_offset@GOTPAGE
Lloh34:
	ldr	x9, [x9, _max_offset@GOTPAGEOFF]
Lloh35:
	str	x8, [x9]
	ldrsw	x9, [x20]
	cmp	x8, x9
	b.ne	LBB0_22
; %bb.15:
	mov	w0, #3
	bl	_dbm_getint
	ldr	w0, [x0]
	bl	_dbm_get
	cbz	x0, LBB0_5
; %bb.16:
	mov	x20, x0
	ldr	w0, [x0]
	bl	_be32toh
	ldr	x8, [x24]
	cmp	x0, x8
	b.ne	LBB0_23
; %bb.17:
	mov	w0, #0
	b	LBB0_10
LBB0_18:
	ldr	w0, [x25]
Lloh36:
	adrp	x1, l_.str.1@PAGE
Lloh37:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w2, #15
	bl	_strncmp
	cbz	x0, LBB0_21
; %bb.19:
	ldr	w0, [x21]
	bl	_be32toh
	ldr	x8, [x24]
	stp	x0, x8, [sp]
Lloh38:
	adrp	x0, l_.str.2@PAGE
Lloh39:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_4
LBB0_20:
	ldr	w0, [x21]
	bl	_be32toh
	ldr	x8, [x25]
	stp	x0, x8, [sp]
Lloh40:
	adrp	x0, l_.str.4@PAGE
Lloh41:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_4
LBB0_21:
Lloh42:
	adrp	x0, l_.str.3@PAGE
Lloh43:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_4
LBB0_22:
	stp	x9, x8, [sp]
Lloh44:
	adrp	x0, l_.str.5@PAGE
Lloh45:
	add	x0, x0, l_.str.5@PAGEOFF
	b	LBB0_4
LBB0_23:
	ldr	w0, [x20]
	bl	_be32toh
	ldr	x8, [x24]
	stp	x0, x8, [sp]
Lloh46:
	adrp	x0, l_.str.6@PAGE
Lloh47:
	add	x0, x0, l_.str.6@PAGEOFF
	b	LBB0_4
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGotStr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpAdd	Lloh46, Lloh47
	.cfi_endproc
                                        ; -- End function
	.comm	_O_RDONLY,4,2                   ; @O_RDONLY
	.comm	_ifd,4,2                        ; @ifd
	.comm	_st,4,2                         ; @st
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"dbm_map(%s): File too short"

	.comm	_EFTYPE,4,2                     ; @EFTYPE
	.comm	_errno,4,2                      ; @errno
	.comm	_INT32_MAX,4,2                  ; @INT32_MAX
	.comm	_EFBIG,4,2                      ; @EFBIG
	.comm	_PROT_READ,4,2                  ; @PROT_READ
	.comm	_MAP_SHARED,4,2                 ; @MAP_SHARED
	.comm	_dbm_base,4,2                   ; @dbm_base
	.comm	_MAP_FAILED,4,2                 ; @MAP_FAILED
	.comm	_MANDOCDB_MAGIC,8,3             ; @MANDOCDB_MAGIC
l_.str.1:                               ; @.str.1
	.asciz	"SQLite format 3"

l_.str.2:                               ; @.str.2
	.asciz	"dbm_map(%s): Bad initial magic %x (expected %x)"

l_.str.3:                               ; @.str.3
	.asciz	"dbm_map(%s): Obsolete format based on SQLite 3"

	.comm	_MANDOCDB_VERSION,8,3           ; @MANDOCDB_VERSION
l_.str.4:                               ; @.str.4
	.asciz	"dbm_map(%s): Bad version number %d (expected %d)"

	.comm	_max_offset,8,3                 ; @max_offset
l_.str.5:                               ; @.str.5
	.asciz	"dbm_map(%s): Inconsistent file size %lld (expected %d)"

l_.str.6:                               ; @.str.6
	.asciz	"dbm_map(%s): Bad final magic %x (expected %x)"

.subsections_via_symbols
