	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_handle_winch                   ## -- Begin function handle_winch
	.p2align	4, 0x90
_handle_winch:                          ## @handle_winch
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
                                        ## kill: def $edi killed $edi def $rdi
	leal	-1(%rdi), %ecx
	movl	$-2, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	roll	%cl, %eax
	movq	_sigflags@GOTPCREL(%rip), %rcx
	andl	%eax, (%rcx)
	movq	_errno@GOTPCREL(%rip), %r14
	movl	(%r14), %ebx
	movq	_TIOCGWINSZ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-24(%rbp), %rdx
	xorl	%edi, %edi
	callq	_ioctl
	testq	%rax, %rax
	js	LBB0_5
## %bb.1:
	movl	-24(%rbp), %eax
	cmpl	$3, %eax
	jl	LBB0_3
## %bb.2:
	addl	$-2, %eax
	movq	_rows@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_3:
	movl	-20(%rbp), %eax
	cmpl	$9, %eax
	jl	LBB0_5
## %bb.4:
	addl	$-8, %eax
	movq	_cols@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_5:
	movl	%ebx, (%r14)
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_errno,4,2                      ## @errno
	.comm	_sigflags,4,2                   ## @sigflags
	.comm	_TIOCGWINSZ,4,2                 ## @TIOCGWINSZ
	.comm	_rows,4,2                       ## @rows
	.comm	_cols,4,2                       ## @cols
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_handle_winch                   ; -- Begin function handle_winch
	.p2align	2
_handle_winch:                          ; @handle_winch
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x19, _errno@GOTPAGE
Lloh1:
	ldr	x19, [x19, _errno@GOTPAGEOFF]
	ldr	w20, [x19]
	sub	w8, w0, #1
	mov	w9, #1
	lsl	w8, w9, w8
Lloh2:
	adrp	x9, _sigflags@GOTPAGE
Lloh3:
	ldr	x9, [x9, _sigflags@GOTPAGEOFF]
	ldr	w10, [x9]
	bic	w8, w10, w8
	str	w8, [x9]
Lloh4:
	adrp	x8, _TIOCGWINSZ@GOTPAGE
Lloh5:
	ldr	x8, [x8, _TIOCGWINSZ@GOTPAGEOFF]
Lloh6:
	ldr	w1, [x8]
	add	x2, sp, #8
	mov	w0, #0
	bl	_ioctl
	tbnz	x0, #63, LBB0_5
; %bb.1:
	ldr	w8, [sp, #8]
	cmp	w8, #3
	b.lt	LBB0_3
; %bb.2:
	sub	w8, w8, #2
Lloh7:
	adrp	x9, _rows@GOTPAGE
Lloh8:
	ldr	x9, [x9, _rows@GOTPAGEOFF]
Lloh9:
	str	w8, [x9]
LBB0_3:
	ldr	w8, [sp, #12]
	cmp	w8, #9
	b.lt	LBB0_5
; %bb.4:
	sub	w8, w8, #8
Lloh10:
	adrp	x9, _cols@GOTPAGE
Lloh11:
	ldr	x9, [x9, _cols@GOTPAGEOFF]
Lloh12:
	str	w8, [x9]
LBB0_5:
	str	w20, [x19]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotStr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotStr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_errno,4,2                      ; @errno
	.comm	_sigflags,4,2                   ; @sigflags
	.comm	_TIOCGWINSZ,4,2                 ; @TIOCGWINSZ
	.comm	_rows,4,2                       ; @rows
	.comm	_cols,4,2                       ; @cols
.subsections_via_symbols
