// File: vsklad[P]cgen/./bal/bal/binarytreeindex.hpp
// Function: bal::AvlTreesIndex<unsigned int, true, &int bal::compare_clauses<false>(unsigned int const*, unsigned int const*), &unsigned int bal::clause_index_variable_id<false>(unsigned int const*)>::insertion_point_is_valid(bal::avl_tree_insertion_point_t const&) const
bool insertion_point_is_valid(const insertion_point_t& insertion_point) const override {
            bool result = base_t::insertion_point_is_valid(insertion_point);
            if (!result && insertion_point.version_stamp != CONTAINER_END && insertion_point.kind == btipkCurrent) {
                _assert_level_0(insertion_point.offset < this->size_);
                const CONTAINER_DATA_T* const p_item = _bti_item(this->data_, insertion_point.offset);
                if (_bti_item_parent_offset(p_item) != CONTAINER_END) {
                    const CONTAINER_DATA_T* const p_parent = _bti_item(this->data_, _bti_item_parent_offset(p_item));
                    result = (_bti_item_left_offset(p_parent) == insertion_point.offset) ||
                                (_bti_item_right_offset(p_parent) == insertion_point.offset);
                } else if _bti_item_parent_offset(p_item) {
                    const container_offset_t instance_offset = instance_determiner(_bti_item_container_item(p_item));
                    _assert_level_0(instance_offset < this->instances_.size_);
                    result = this->instances_.data_[instance_offset] == insertion_point.offset;
                };
            };
            return result;
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x38(%rbp)
movq -0x10(%rbp), %rsi
callq 0x37660
andb $0x1, %al
movb %al, -0x11(%rbp)
testb $0x1, -0x11(%rbp)
jne 0x373a3
movq -0x10(%rbp), %rax
cmpl $-0x1, 0x4(%rax)
je 0x373a3
movq -0x10(%rbp), %rax
cmpl $0x3, 0x8(%rax)
jne 0x373a3
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
cmpl 0x10(%rcx), %eax
jae 0x372ae
jmp 0x372cd
leaq 0x26698(%rip), %rdi     # 0x5d94d
leaq 0x26492(%rip), %rsi     # 0x5d74e
movl $0x1d4, %edx            # imm = 0x1D4
leaq 0x2c22c(%rip), %rcx     # 0x634f4
callq 0xd1c0
movq -0x38(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movl 0xc(%rcx), %ecx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
cmpl $-0x1, (%rax)
je 0x3733c
movq -0x38(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x20(%rbp), %rcx
movl (%rcx), %ecx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movl 0x8(%rax), %ecx
movq -0x10(%rbp), %rdx
movb $0x1, %al
cmpl 0xc(%rdx), %ecx
movb %al, -0x39(%rbp)
je 0x37332
movq -0x28(%rbp), %rax
movl 0x4(%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0xc(%rcx), %eax
sete %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
andb $0x1, %al
movb %al, -0x11(%rbp)
jmp 0x373a1
movq -0x20(%rbp), %rax
cmpl $0x0, (%rax)
je 0x3739f
movq -0x20(%rbp), %rdi
addq $0xc, %rdi
callq 0x157a0
movq -0x38(%rbp), %rcx
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
cmpl 0x38(%rcx), %eax
jae 0x37363
jmp 0x37382
leaq 0x269d8(%rip), %rdi     # 0x5dd42
leaq 0x263dd(%rip), %rsi     # 0x5d74e
movl $0x1dc, %edx            # imm = 0x1DC
leaq 0x2c177(%rip), %rcx     # 0x634f4
callq 0xd1c0
movq -0x38(%rbp), %rax
movq 0x30(%rax), %rax
movl -0x2c(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movq -0x10(%rbp), %rcx
cmpl 0xc(%rcx), %eax
sete %al
andb $0x1, %al
movb %al, -0x11(%rbp)
jmp 0x373a1
jmp 0x373a3
movb -0x11(%rbp), %al
andb $0x1, %al
addq $0x40, %rsp
popq %rbp
retq
nop