	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gsc_hw_set_rotation            ## -- Begin function gsc_hw_set_rotation
	.p2align	4, 0x90
_gsc_hw_set_rotation:                   ## @gsc_hw_set_rotation
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	24(%rdi), %r14
	movq	_GSC_IN_CON@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	(%r14), %rdi
	callq	_readl
	movq	_GSC_IN_ROT_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	notl	%edi
	andl	%eax, %edi
	movq	16(%rbx), %rax
	movl	(%rax), %eax
	cmpl	$179, %eax
	jg	LBB0_5
## %bb.1:
	testl	%eax, %eax
	je	LBB0_12
## %bb.2:
	cmpl	$90, %eax
	jne	LBB0_17
## %bb.3:
	movq	8(%rbx), %rax
	cmpl	$0, (%rax)
	je	LBB0_9
## %bb.4:
	movq	_GSC_IN_ROT_90_XFLIP@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_5:
	cmpl	$180, %eax
	je	LBB0_8
## %bb.6:
	cmpl	$270, %eax                      ## imm = 0x10E
	jne	LBB0_17
## %bb.7:
	movq	_GSC_IN_ROT_270@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_12:
	movq	8(%rbx), %rax
	cmpl	$0, (%rax)
	je	LBB0_14
## %bb.13:
	movq	_GSC_IN_ROT_XFLIP@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_8:
	movq	_GSC_IN_ROT_180@GOTPCREL(%rip), %rax
LBB0_16:
	orl	(%rax), %edi
LBB0_17:
	movq	(%r15), %rsi
	addq	(%r14), %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writel                         ## TAILCALL
LBB0_9:
	movq	(%rbx), %rax
	cmpl	$0, (%rax)
	je	LBB0_11
## %bb.10:
	movq	_GSC_IN_ROT_90_YFLIP@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_14:
	movq	(%rbx), %rax
	cmpl	$0, (%rax)
	je	LBB0_17
## %bb.15:
	movq	_GSC_IN_ROT_YFLIP@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_11:
	movq	_GSC_IN_ROT_90@GOTPCREL(%rip), %rax
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_GSC_IN_CON,8,3                 ## @GSC_IN_CON
	.comm	_GSC_IN_ROT_MASK,4,2            ## @GSC_IN_ROT_MASK
	.comm	_GSC_IN_ROT_270,4,2             ## @GSC_IN_ROT_270
	.comm	_GSC_IN_ROT_180,4,2             ## @GSC_IN_ROT_180
	.comm	_GSC_IN_ROT_90_XFLIP,4,2        ## @GSC_IN_ROT_90_XFLIP
	.comm	_GSC_IN_ROT_90_YFLIP,4,2        ## @GSC_IN_ROT_90_YFLIP
	.comm	_GSC_IN_ROT_90,4,2              ## @GSC_IN_ROT_90
	.comm	_GSC_IN_ROT_XFLIP,4,2           ## @GSC_IN_ROT_XFLIP
	.comm	_GSC_IN_ROT_YFLIP,4,2           ## @GSC_IN_ROT_YFLIP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gsc_hw_set_rotation            ; -- Begin function gsc_hw_set_rotation
	.p2align	2
_gsc_hw_set_rotation:                   ; @gsc_hw_set_rotation
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
	ldr	x20, [x0, #24]
	ldr	x8, [x20]
Lloh0:
	adrp	x21, _GSC_IN_CON@GOTPAGE
Lloh1:
	ldr	x21, [x21, _GSC_IN_CON@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl
Lloh2:
	adrp	x8, _GSC_IN_ROT_MASK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GSC_IN_ROT_MASK@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	bic	w0, w0, w8
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	cmp	w8, #179
	b.gt	LBB0_5
; %bb.1:
	cbz	w8, LBB0_8
; %bb.2:
	cmp	w8, #90
	b.ne	LBB0_12
; %bb.3:
	ldr	x8, [x19, #8]
	ldr	w8, [x8]
	cbz	w8, LBB0_13
; %bb.4:
Lloh5:
	adrp	x8, _GSC_IN_ROT_90_XFLIP@GOTPAGE
Lloh6:
	ldr	x8, [x8, _GSC_IN_ROT_90_XFLIP@GOTPAGEOFF]
	b	LBB0_11
LBB0_5:
	cmp	w8, #180
	b.eq	LBB0_10
; %bb.6:
	cmp	w8, #270
	b.ne	LBB0_12
; %bb.7:
Lloh7:
	adrp	x8, _GSC_IN_ROT_270@GOTPAGE
Lloh8:
	ldr	x8, [x8, _GSC_IN_ROT_270@GOTPAGEOFF]
	b	LBB0_11
LBB0_8:
	ldr	x8, [x19, #8]
	ldr	w8, [x8]
	cbz	w8, LBB0_15
; %bb.9:
Lloh9:
	adrp	x8, _GSC_IN_ROT_XFLIP@GOTPAGE
Lloh10:
	ldr	x8, [x8, _GSC_IN_ROT_XFLIP@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:
Lloh11:
	adrp	x8, _GSC_IN_ROT_180@GOTPAGE
Lloh12:
	ldr	x8, [x8, _GSC_IN_ROT_180@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	orr	w0, w8, w0
LBB0_12:
	ldr	x8, [x20]
	ldr	x9, [x21]
	add	x1, x9, x8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_writel
LBB0_13:
	ldr	x8, [x19]
	ldr	w8, [x8]
	cbz	w8, LBB0_17
; %bb.14:
Lloh13:
	adrp	x8, _GSC_IN_ROT_90_YFLIP@GOTPAGE
Lloh14:
	ldr	x8, [x8, _GSC_IN_ROT_90_YFLIP@GOTPAGEOFF]
	b	LBB0_11
LBB0_15:
	ldr	x8, [x19]
	ldr	w8, [x8]
	cbz	w8, LBB0_12
; %bb.16:
Lloh15:
	adrp	x8, _GSC_IN_ROT_YFLIP@GOTPAGE
Lloh16:
	ldr	x8, [x8, _GSC_IN_ROT_YFLIP@GOTPAGEOFF]
	b	LBB0_11
LBB0_17:
Lloh17:
	adrp	x8, _GSC_IN_ROT_90@GOTPAGE
Lloh18:
	ldr	x8, [x8, _GSC_IN_ROT_90@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_GSC_IN_CON,8,3                 ; @GSC_IN_CON
	.comm	_GSC_IN_ROT_MASK,4,2            ; @GSC_IN_ROT_MASK
	.comm	_GSC_IN_ROT_270,4,2             ; @GSC_IN_ROT_270
	.comm	_GSC_IN_ROT_180,4,2             ; @GSC_IN_ROT_180
	.comm	_GSC_IN_ROT_90_XFLIP,4,2        ; @GSC_IN_ROT_90_XFLIP
	.comm	_GSC_IN_ROT_90_YFLIP,4,2        ; @GSC_IN_ROT_90_YFLIP
	.comm	_GSC_IN_ROT_90,4,2              ; @GSC_IN_ROT_90
	.comm	_GSC_IN_ROT_XFLIP,4,2           ; @GSC_IN_ROT_XFLIP
	.comm	_GSC_IN_ROT_YFLIP,4,2           ; @GSC_IN_ROT_YFLIP
.subsections_via_symbols
