	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wdc_append_serial_name
_wdc_append_serial_name:                ## @wdc_append_serial_name
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r15
	movq	%rsi, %r12
	movl	%edi, %r14d
	movq	%rsp, -64(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_NVME_SERIAL_NUMBER_LENGTH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	incl	%eax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rbx
	movq	%r12, %rdi
	callq	_strlen
	movq	%rax, %r13
	leaq	-56(%rbp), %rsi
	movl	%r14d, %edi
	callq	_read_controller_data
	movl	-56(%rbp), %esi
	movq	_NVME_SERIAL_NUMBER_LENGTH@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_memcpy
	movq	_NVME_SERIAL_NUMBER_LENGTH@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	leaq	(%rax,%rbx), %rcx
	decq	%rcx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rcx, %rax
	cmpq	%rbx, %rcx
	jbe	LBB0_3
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	leaq	-1(%rax), %rcx
	cmpb	$32, (%rax)
	je	LBB0_1
LBB0_3:
	addq	%r13, %r12
	subq	%r13, %r15
	movb	$0, 1(%rax)
	leaq	L_.str(%rip), %rdx
	movq	%r12, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rcx
	movq	-72(%rbp), %r8                  ## 8-byte Reload
	callq	_snprintf
	movq	-64(%rbp), %rsp                 ## 8-byte Reload
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NVME_SERIAL_NUMBER_LENGTH,4,2  ## @NVME_SERIAL_NUMBER_LENGTH
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s%s.bin"

	.no_dead_strip	_wdc_append_serial_name
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wdc_append_serial_name
_wdc_append_serial_name:                ; @wdc_append_serial_name
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	sub	sp, sp, #16
	mov	x19, x3
	mov	x20, x2
	mov	x21, x1
	mov	x24, x0
	mov	x25, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
Lloh3:
	adrp	x26, _NVME_SERIAL_NUMBER_LENGTH@GOTPAGE
Lloh4:
	ldr	x26, [x26, _NVME_SERIAL_NUMBER_LENGTH@GOTPAGEOFF]
	ldr	w8, [x26]
	add	w8, w8, #1
	mov	x9, x8
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x1fffffff0
	sub	x22, x9, x8
	mov	sp, x22
	mov	x0, x1
	bl	_strlen
	mov	x23, x0
	sub	x1, x29, #80
	mov	x0, x24
	bl	_read_controller_data
	ldur	w1, [x29, #-80]
	ldr	w2, [x26]
	mov	x0, x22
	bl	_memcpy
	ldrsw	x8, [x26]
	add	x8, x8, x22
	sub	x9, x8, #1
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	mov	x8, x9
	cmp	x9, x22
	b.ls	LBB0_3
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x9, x8
	ldrb	w10, [x9], #-1
	cmp	w10, #32
	b.eq	LBB0_1
LBB0_3:
	add	x0, x21, x23
	sub	x1, x20, x23
	strb	wzr, [x8, #1]
Lloh7:
	adrp	x2, l_.str@PAGE
Lloh8:
	add	x2, x2, l_.str@PAGEOFF
	mov	x3, x22
	mov	x4, x19
	bl	_snprintf
	mov	sp, x25
	ldur	x8, [x29, #-72]
Lloh9:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh10:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	sub	sp, x29, #64
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_NVME_SERIAL_NUMBER_LENGTH,4,2  ; @NVME_SERIAL_NUMBER_LENGTH
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s%s.bin"

	.no_dead_strip	_wdc_append_serial_name
.subsections_via_symbols
