	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function permute_args
_permute_args:                          ## @permute_args
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %rbx
	movl	%edx, %r13d
	movl	%esi, %r14d
	movl	%edi, -48(%rbp)                 ## 4-byte Spill
	movl	%esi, %r15d
	subl	%edi, %r15d
	movl	%edx, %r12d
	subl	%esi, %r12d
	movl	%r15d, %edi
	movl	%r12d, %esi
	callq	_gcd
	movl	%eax, %ecx
	subl	-48(%rbp), %r13d                ## 4-byte Folded Reload
	movl	%r13d, %eax
	cltd
	idivl	%ecx
	testl	%ecx, %ecx
	jle	LBB0_14
## %bb.1:
	negl	%r15d
	movslq	%r14d, %rdx
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movl	%ecx, %r10d
	movl	%eax, %ecx
	andl	$-2, %ecx
	movl	%ecx, -52(%rbp)                 ## 4-byte Spill
	xorl	%r11d, %r11d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_2 Depth=1
	incq	%r11
	cmpq	%r10, %r11
	je	LBB0_14
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	testl	%eax, %eax
	jle	LBB0_13
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%r11,%rcx), %r13
	movq	(%rbx,%r13,8), %rdx
	cmpl	$1, %eax
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r13d, %ecx
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	testb	$1, %al
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_2 Depth=1
	cmpl	%r14d, %ecx
	movl	%r15d, %esi
	cmovll	%r12d, %esi
	addl	%ecx, %esi
	movslq	%esi, %rcx
	movq	(%rbx,%rcx,8), %rsi
	movq	%rdx, (%rbx,%rcx,8)
	movq	%rsi, (%rbx,%r13,8)
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	-52(%rbp), %edi                 ## 4-byte Reload
	movl	%r13d, %ecx
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_6 Depth=2
	addl	%esi, %ecx
	movslq	%ecx, %rsi
	movq	(%rbx,%rsi,8), %rdx
	movq	%r8, (%rbx,%rsi,8)
	movq	%rdx, (%rbx,%r13,8)
	addl	$-2, %edi
	je	LBB0_11
LBB0_6:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%r12d, %esi
	cmpl	%r14d, %ecx
	jl	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=2
	movl	%r15d, %esi
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=2
	addl	%ecx, %esi
	movslq	%esi, %r9
	movq	(%rbx,%r9,8), %r8
	movq	%rdx, (%rbx,%r9,8)
	movq	%r8, (%rbx,%r13,8)
	movl	%r12d, %ecx
	cmpl	%r14d, %r9d
	jl	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=2
	movl	%r15d, %ecx
	jmp	LBB0_10
LBB0_14:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_permute_args
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function permute_args
_permute_args:                          ; @permute_args
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x3
	mov	x23, x2
	mov	x20, x1
	mov	x24, x0
	sub	w22, w1, w0
	sub	w21, w2, w1
	mov	x0, x22
	mov	x1, x21
	bl	_gcd
	cmp	w0, #1
	b.lt	LBB0_6
; %bb.1:
	mov	x8, #0
	sub	w12, w23, w24
	neg	w9, w22
	sxtw	x10, w20
	mov	w11, w0
	sdiv	w12, w12, w0
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x8, x8, #1
	cmp	x8, x11
	b.eq	LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	cmp	w12, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x13, x8, x10
	ldr	x16, [x19, x13, lsl #3]
	mov	x14, x12
	mov	x15, x13
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	cmp	w15, w20
	csel	w17, w21, w9, lt
	add	w15, w17, w15
	sbfiz	x17, x15, #3, #32
	ldr	x0, [x19, x17]
	str	x16, [x19, x17]
	str	x0, [x19, x13, lsl #3]
	mov	x16, x0
	subs	w14, w14, #1
	b.ne	LBB0_5
	b	LBB0_2
LBB0_6:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_permute_args
.subsections_via_symbols
