	.file	"extr_hypertable.c_ts_hypertable_select_tablespace.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	ts_hypertable_select_tablespace
	.type	ts_hypertable_select_tablespace, @function
ts_hypertable_select_tablespace:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13, rsi
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	edi, DWORD PTR 4[rdi]
	call	ts_tablespace_scan@PLT
	mov	r12, rax
	test	rax, rax
	je	.L1
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	je	.L6
	mov	edi, DWORD PTR 0[rbp]
	xor	esi, esi
	call	hyperspace_get_closed_dimension@PLT
	mov	rbx, rax
	test	rax, rax
	je	.L17
.L3:
	mov	rdi, rbx
	call	IS_OPEN_DIMENSION@PLT
	mov	edi, 1
	test	rax, rax
	je	.L18
.L4:
	call	Assert@PLT
	mov	rdi, rbx
	call	ts_dimension_get_slices@PLT
	xor	edi, edi
	mov	rbp, rax
	test	rax, rax
	je	.L5
	mov	rdi, rbx
	call	IS_OPEN_DIMENSION@PLT
	mov	edi, 1
	test	rax, rax
	je	.L19
.L5:
	call	Assert@PLT
	mov	esi, DWORD PTR 8[rbx]
	mov	edi, DWORD PTR 0[r13]
	call	ts_hypercube_get_slice_by_dimension_id@PLT
	xor	edi, edi
	test	rax, rax
	mov	rbx, rax
	setne	dil
	call	Assert@PLT
	mov	esi, DWORD PTR [rbx]
	mov	rdi, rbp
	call	ts_dimension_vec_find_slice_index@PLT
	mov	edi, eax
	mov	ebx, eax
	not	edi
	shr	edi, 31
	call	Assert@PLT
	mov	eax, ebx
	cdq
	idiv	DWORD PTR [r12]
	mov	rax, QWORD PTR 8[r12]
	movsx	rdx, edx
	lea	r12, [rax+rdx*4]
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rax, r12
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L17:
	.cfi_restore_state
	mov	edi, DWORD PTR 0[rbp]
	xor	esi, esi
	call	hyperspace_get_open_dimension@PLT
	mov	rbx, rax
	test	rax, rax
	jne	.L3
	xor	edi, edi
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L6:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xor	r12d, r12d
	pop	rbx
	.cfi_def_cfa_offset 32
	mov	rax, r12
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	.cfi_restore_state
	xor	edi, edi
	cmp	QWORD PTR 0[rbp], 0
	setg	dil
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L18:
	xor	edi, edi
	cmp	QWORD PTR [rbx], 0
	setg	dil
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	ts_hypertable_select_tablespace, .-ts_hypertable_select_tablespace
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_hypertable.c_ts_hypertable_select_tablespace.c"
	.text
	.global	__aeabi_idivmod
	.align	2
	.global	ts_hypertable_select_tablespace
	.syntax unified
	.arm
	.fpu softvfp
	.type	ts_hypertable_select_tablespace, %function
ts_hypertable_select_tablespace:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r6, r0
	ldr	r0, [r0, #4]
	mov	r7, r1
	bl	ts_tablespace_scan
	subs	r4, r0, #0
	beq	.L1
	ldr	r3, [r4]
	cmp	r3, #0
	moveq	r4, r3
	beq	.L1
	mov	r1, #0
	ldr	r0, [r6]
	bl	hyperspace_get_closed_dimension
	subs	r5, r0, #0
	beq	.L16
.L3:
	mov	r0, r5
	bl	IS_OPEN_DIMENSION
	cmp	r0, #0
	movne	r0, #1
	beq	.L17
.L4:
	bl	Assert
	mov	r0, r5
	bl	ts_dimension_get_slices
	subs	r6, r0, #0
	moveq	r0, r6
	beq	.L5
	mov	r0, r5
	bl	IS_OPEN_DIMENSION
	cmp	r0, #0
	movne	r0, #1
	beq	.L18
.L5:
	bl	Assert
	ldr	r1, [r5, #4]
	ldr	r0, [r7]
	bl	ts_hypercube_get_slice_by_dimension_id
	mov	r5, r0
	subs	r0, r0, #0
	movne	r0, #1
	bl	Assert
	ldr	r1, [r5]
	mov	r0, r6
	bl	ts_dimension_vec_find_slice_index
	mov	r5, r0
	mvn	r0, r0
	lsr	r0, r0, #31
	bl	Assert
	ldr	r1, [r4]
	mov	r0, r5
	bl	__aeabi_idivmod
	ldr	r4, [r4, #4]
	add	r4, r4, r1, lsl #2
.L1:
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, pc}
.L16:
	mov	r1, r5
	ldr	r0, [r6]
	bl	hyperspace_get_open_dimension
	subs	r5, r0, #0
	moveq	r0, r5
	beq	.L4
	b	.L3
.L18:
	ldr	r0, [r6]
	cmp	r0, #0
	movle	r0, #0
	movgt	r0, #1
	b	.L5
.L17:
	ldr	r0, [r5]
	cmp	r0, #0
	movle	r0, #0
	movgt	r0, #1
	b	.L4
	.size	ts_hypertable_select_tablespace, .-ts_hypertable_select_tablespace
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
