// File: /workspace/github_c_makefile_star2_O0/attractivechaos[P]rb-eval/./rb.hpp
// Function: rbtree_t<unsigned int, rbnode_map_t<unsigned int, int>, int_cmp>::erase(unsigned int const&)
inline node_t *erase(const key_t &item) {
		node_t *pa[RB_MAX_HEIGHT], *p;
		unsigned char da[RB_MAX_HEIGHT];
		int k, cmp;
		k = 0;
		p = (node_t*)&root;
		for (cmp = -1; cmp != 0; cmp = __cmp(item, p->key)) {
			int dir = cmp > 0;
			pa[k] = p;
			da[k++] = dir;
			p = p->rb_link[dir];
			if (p == 0) return 0;
		}
		if (p->rb_link[1] == 0) pa[k - 1]->rb_link[da[k - 1]] = p->rb_link[0];
		else {
			int t;
			node_t *r = p->rb_link[1];
			if (r->rb_link[0] == 0) {
				r->rb_link[0] = p->rb_link[0];
				t = r->color;
				r->color = p->color;
				p->color = t;
				pa[k - 1]->rb_link[da[k - 1]] = r;
				da[k] = 1;
				pa[k++] = r;
			} else {
				node_t *s;
				int j = k++;
				for (;;) {
					da[k] = 0;
					pa[k++] = r;
					s = r->rb_link[0];
					if (s->rb_link[0] == 0) break;
					r = s;
				}
				da[j] = 1;
				pa[j] = s;
				pa[j - 1]->rb_link[da[j - 1]] = s;
				s->rb_link[0] = p->rb_link[0];
				r->rb_link[0] = s->rb_link[1];
				s->rb_link[1] = p->rb_link[1];
				t = s->color;
				s->color = p->color;
				p->color = t;
			}
		}
		if (p->color == RB_BLACK) {
			for (;;) {
				node_t *x = pa[k - 1]->rb_link[da[k - 1]];
				if (x && x->color == RB_RED) {
					x->color = RB_BLACK;
					break;
				}
				if (k < 2) break;
				if (da[k - 1] == 0) {
					node_t *w = pa[k - 1]->rb_link[1];
					if (w->color == RB_RED) {
						w->color = RB_BLACK;
						pa[k - 1]->color = RB_RED;
						pa[k - 1]->rb_link[1] = w->rb_link[0];
						w->rb_link[0] = pa[k - 1];
						pa[k - 2]->rb_link[da[k - 2]] = w;
						pa[k] = pa[k - 1];
						da[k] = 0;
						pa[k - 1] = w;
						++k;
						w = pa[k - 1]->rb_link[1];
					}
					if ((w->rb_link[0] == 0 || w->rb_link[0]->color == RB_BLACK)
						&& (w->rb_link[1] == 0 || w->rb_link[1]->color == RB_BLACK))
					{
						w->color = RB_RED;
					} else {
						if (w->rb_link[1] == 0 || w->rb_link[1]->color == RB_BLACK) {
							node_t *y = w->rb_link[0];
							y->color = RB_BLACK;
							w->color = RB_RED;
							w->rb_link[0] = y->rb_link[1];
							y->rb_link[1] = w;
							w = pa[k - 1]->rb_link[1] = y;
						}
						w->color = pa[k - 1]->color;
						pa[k - 1]->color = RB_BLACK;
						w->rb_link[1]->color = RB_BLACK;
						pa[k - 1]->rb_link[1] = w->rb_link[0];
						w->rb_link[0] = pa[k - 1];
						pa[k - 2]->rb_link[da[k - 2]] = w;
						break;
					}
				} else {
					node_t *w = pa[k - 1]->rb_link[0];
					if (w->color == RB_RED) {
						w->color = RB_BLACK;
						pa[k - 1]->color = RB_RED;
						pa[k - 1]->rb_link[0] = w->rb_link[1];
						w->rb_link[1] = pa[k - 1];
						pa[k - 2]->rb_link[da[k - 2]] = w;
						pa[k] = pa[k - 1];
						da[k] = 1;
						pa[k - 1] = w;
						k++;
						w = pa[k - 1]->rb_link[0];
					}
					if ((w->rb_link[0] == 0 || w->rb_link[0]->color == RB_BLACK)
						&& (w->rb_link[1] == 0 || w->rb_link[1]->color == RB_BLACK))
					{
						w->color = RB_RED;
					} else {
						if (w->rb_link[0] == 0 || w->rb_link[0]->color == RB_BLACK) {
							node_t *y = w->rb_link[1];
							y->color = RB_BLACK;
							w->color = RB_RED;
							w->rb_link[1] = y->rb_link[0];
							y->rb_link[0] = w;
							w = pa[k - 1]->rb_link[0] = y;
						}
						w->color = pa[k - 1]->color;
						pa[k - 1]->color = RB_BLACK;
						w->rb_link[0]->color = RB_BLACK;
						pa[k - 1]->rb_link[0] = w->rb_link[1];
						w->rb_link[1] = pa[k - 1];
						pa[k - 2]->rb_link[da[k - 2]] = w;
						break;
					}
				}
				--k;
			}
		}
		//::free(p);
		++generation;
		return p;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x240, %rsp            # imm = 0x240
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x238(%rbp)
movl $0x0, -0x1e4(%rbp)
addq $0x8, %rax
movq %rax, -0x1a8(%rbp)
movl $0xffffffff, -0x1e8(%rbp) # imm = 0xFFFFFFFF
cmpl $0x0, -0x1e8(%rbp)
je 0x1b10
cmpl $0x0, -0x1e8(%rbp)
setg %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x1ec(%rbp)
movq -0x1a8(%rbp), %rcx
movslq -0x1e4(%rbp), %rax
movq %rcx, -0x1a0(%rbp,%rax,8)
movl -0x1ec(%rbp), %eax
movb %al, %cl
movl -0x1e4(%rbp), %eax
movl %eax, %edx
addl $0x1, %edx
movl %edx, -0x1e4(%rbp)
cltq
movb %cl, -0x1e0(%rbp,%rax)
movq -0x1a8(%rbp), %rax
movslq -0x1ec(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x1a8(%rbp)
cmpq $0x0, -0x1a8(%rbp)
jne 0x1ae7
movq $0x0, -0x8(%rbp)
jmp 0x2403
jmp 0x1ae9
movq -0x238(%rbp), %rdi
movq -0x18(%rbp), %rax
movl (%rax), %esi
movq -0x1a8(%rbp), %rax
movl 0x10(%rax), %edx
callq 0x24d0
movl %eax, -0x1e8(%rbp)
jmp 0x1a5d
movq -0x1a8(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x1b58
movq -0x1a8(%rbp), %rax
movq (%rax), %rdx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
jmp 0x1d75
movq -0x1a8(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x1f8(%rbp)
movq -0x1f8(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x1c2e
movq -0x1a8(%rbp), %rax
movq (%rax), %rcx
movq -0x1f8(%rbp), %rax
movq %rcx, (%rax)
movq -0x1f8(%rbp), %rax
movsbl 0x18(%rax), %eax
movl %eax, -0x1f0(%rbp)
movq -0x1a8(%rbp), %rax
movb 0x18(%rax), %cl
movq -0x1f8(%rbp), %rax
movb %cl, 0x18(%rax)
movl -0x1f0(%rbp), %eax
movb %al, %cl
movq -0x1a8(%rbp), %rax
movb %cl, 0x18(%rax)
movq -0x1f8(%rbp), %rdx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
movslq -0x1e4(%rbp), %rax
movb $0x1, -0x1e0(%rbp,%rax)
movq -0x1f8(%rbp), %rcx
movl -0x1e4(%rbp), %eax
movl %eax, %edx
addl $0x1, %edx
movl %edx, -0x1e4(%rbp)
cltq
movq %rcx, -0x1a0(%rbp,%rax,8)
jmp 0x1d73
movl -0x1e4(%rbp), %eax
movl %eax, %ecx
addl $0x1, %ecx
movl %ecx, -0x1e4(%rbp)
movl %eax, -0x204(%rbp)
movslq -0x1e4(%rbp), %rax
movb $0x0, -0x1e0(%rbp,%rax)
movq -0x1f8(%rbp), %rcx
movl -0x1e4(%rbp), %eax
movl %eax, %edx
addl $0x1, %edx
movl %edx, -0x1e4(%rbp)
cltq
movq %rcx, -0x1a0(%rbp,%rax,8)
movq -0x1f8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x200(%rbp)
movq -0x200(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x1c96
jmp 0x1ca6
movq -0x200(%rbp), %rax
movq %rax, -0x1f8(%rbp)
jmp 0x1c45
movslq -0x204(%rbp), %rax
movb $0x1, -0x1e0(%rbp,%rax)
movq -0x200(%rbp), %rcx
movslq -0x204(%rbp), %rax
movq %rcx, -0x1a0(%rbp,%rax,8)
movq -0x200(%rbp), %rdx
movl -0x204(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x204(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
movq -0x1a8(%rbp), %rax
movq (%rax), %rcx
movq -0x200(%rbp), %rax
movq %rcx, (%rax)
movq -0x200(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x1f8(%rbp), %rax
movq %rcx, (%rax)
movq -0x1a8(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x200(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x200(%rbp), %rax
movsbl 0x18(%rax), %eax
movl %eax, -0x1f0(%rbp)
movq -0x1a8(%rbp), %rax
movb 0x18(%rax), %cl
movq -0x200(%rbp), %rax
movb %cl, 0x18(%rax)
movl -0x1f0(%rbp), %eax
movb %al, %cl
movq -0x1a8(%rbp), %rax
movb %cl, 0x18(%rax)
jmp 0x1d75
movq -0x1a8(%rbp), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x23e5
jmp 0x1d8b
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x210(%rbp)
cmpq $0x0, -0x210(%rbp)
je 0x1de7
movq -0x210(%rbp), %rax
movsbl 0x18(%rax), %eax
cmpl $0x1, %eax
jne 0x1de7
movq -0x210(%rbp), %rax
movb $0x0, 0x18(%rax)
jmp 0x23e3
cmpl $0x2, -0x1e4(%rbp)
jge 0x1df5
jmp 0x23e3
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movzbl -0x1e0(%rbp,%rax), %eax
cmpl $0x0, %eax
jne 0x20f5
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq 0x8(%rax), %rax
movq %rax, -0x218(%rbp)
movq -0x218(%rbp), %rax
movsbl 0x18(%rax), %eax
cmpl $0x1, %eax
jne 0x1f4d
movq -0x218(%rbp), %rax
movb $0x0, 0x18(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb $0x1, 0x18(%rax)
movq -0x218(%rbp), %rax
movq (%rax), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq %rcx, 0x8(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movq -0x218(%rbp), %rax
movq %rcx, (%rax)
movq -0x218(%rbp), %rdx
movl -0x1e4(%rbp), %eax
subl $0x2, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x2, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movslq -0x1e4(%rbp), %rax
movq %rcx, -0x1a0(%rbp,%rax,8)
movslq -0x1e4(%rbp), %rax
movb $0x0, -0x1e0(%rbp,%rax)
movq -0x218(%rbp), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq %rcx, -0x1a0(%rbp,%rax,8)
movl -0x1e4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1e4(%rbp)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq 0x8(%rax), %rax
movq %rax, -0x218(%rbp)
movq -0x218(%rbp), %rax
cmpq $0x0, (%rax)
je 0x1f6d
movq -0x218(%rbp), %rax
movq (%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x1f9f
movq -0x218(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x1f8f
movq -0x218(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x1f9f
movq -0x218(%rbp), %rax
movb $0x1, 0x18(%rax)
jmp 0x20f0
movq -0x218(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x1fc1
movq -0x218(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x2035
movq -0x218(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x220(%rbp)
movq -0x220(%rbp), %rax
movb $0x0, 0x18(%rax)
movq -0x218(%rbp), %rax
movb $0x1, 0x18(%rax)
movq -0x220(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x218(%rbp), %rax
movq %rcx, (%rax)
movq -0x218(%rbp), %rcx
movq -0x220(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x220(%rbp), %rax
movl -0x1e4(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movq -0x1a0(%rbp,%rcx,8), %rcx
movq %rax, 0x8(%rcx)
movq %rax, -0x218(%rbp)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb 0x18(%rax), %cl
movq -0x218(%rbp), %rax
movb %cl, 0x18(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb $0x0, 0x18(%rax)
movq -0x218(%rbp), %rax
movq 0x8(%rax), %rax
movb $0x0, 0x18(%rax)
movq -0x218(%rbp), %rax
movq (%rax), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq %rcx, 0x8(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movq -0x218(%rbp), %rax
movq %rcx, (%rax)
movq -0x218(%rbp), %rdx
movl -0x1e4(%rbp), %eax
subl $0x2, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x2, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
jmp 0x23e3
jmp 0x23cf
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq (%rax), %rax
movq %rax, -0x228(%rbp)
movq -0x228(%rbp), %rax
movsbl 0x18(%rax), %eax
cmpl $0x1, %eax
jne 0x2230
movq -0x228(%rbp), %rax
movb $0x0, 0x18(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb $0x1, 0x18(%rax)
movq -0x228(%rbp), %rax
movq 0x8(%rax), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq %rcx, (%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movq -0x228(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x228(%rbp), %rdx
movl -0x1e4(%rbp), %eax
subl $0x2, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x2, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movslq -0x1e4(%rbp), %rax
movq %rcx, -0x1a0(%rbp,%rax,8)
movslq -0x1e4(%rbp), %rax
movb $0x1, -0x1e0(%rbp,%rax)
movq -0x228(%rbp), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq %rcx, -0x1a0(%rbp,%rax,8)
movl -0x1e4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1e4(%rbp)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq (%rax), %rax
movq %rax, -0x228(%rbp)
movq -0x228(%rbp), %rax
cmpq $0x0, (%rax)
je 0x2250
movq -0x228(%rbp), %rax
movq (%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x2282
movq -0x228(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x2272
movq -0x228(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x2282
movq -0x228(%rbp), %rax
movb $0x1, 0x18(%rax)
jmp 0x23cd
movq -0x228(%rbp), %rax
cmpq $0x0, (%rax)
je 0x22a2
movq -0x228(%rbp), %rax
movq (%rax), %rax
movsbl 0x18(%rax), %eax
cmpl $0x0, %eax
jne 0x2315
movq -0x228(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x230(%rbp)
movq -0x230(%rbp), %rax
movb $0x0, 0x18(%rax)
movq -0x228(%rbp), %rax
movb $0x1, 0x18(%rax)
movq -0x230(%rbp), %rax
movq (%rax), %rcx
movq -0x228(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x228(%rbp), %rcx
movq -0x230(%rbp), %rax
movq %rcx, (%rax)
movq -0x230(%rbp), %rax
movl -0x1e4(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movq -0x1a0(%rbp,%rcx,8), %rcx
movq %rax, (%rcx)
movq %rax, -0x228(%rbp)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb 0x18(%rax), %cl
movq -0x228(%rbp), %rax
movb %cl, 0x18(%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movb $0x0, 0x18(%rax)
movq -0x228(%rbp), %rax
movq (%rax), %rax
movb $0x0, 0x18(%rax)
movq -0x228(%rbp), %rax
movq 0x8(%rax), %rcx
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movq %rcx, (%rax)
movl -0x1e4(%rbp), %eax
subl $0x1, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rcx
movq -0x228(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x228(%rbp), %rdx
movl -0x1e4(%rbp), %eax
subl $0x2, %eax
cltq
movq -0x1a0(%rbp,%rax,8), %rax
movl -0x1e4(%rbp), %ecx
subl $0x2, %ecx
movslq %ecx, %rcx
movzbl -0x1e0(%rbp,%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
jmp 0x23e3
jmp 0x23cf
movl -0x1e4(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x1e4(%rbp)
jmp 0x1d8b
jmp 0x23e5
movq -0x238(%rbp), %rax
movq 0x10(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x10(%rax)
movq -0x1a8(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x240, %rsp            # imm = 0x240
popq %rbp
retq