// File: /workspace/github_c_makefile_star2_O0/ccxvii[P]mujs/./jsproperty.c
// Function: unlinkproperty
static js_Property *unlinkproperty(js_Property *node, const char *name, js_Property **garbage)
{
	js_Property *temp, *a, *b;
	if (node != &sentinel) {
		int c = strcmp(name, node->name);
		if (c < 0) {
			node->left = unlinkproperty(node->left, name, garbage);
		} else if (c > 0) {
			node->right = unlinkproperty(node->right, name, garbage);
		} else {
			*garbage = node;
			if (node->left == &sentinel && node->right == &sentinel) {
				return &sentinel;
			}
			else if (node->left == &sentinel) {
				a = node->right;
				while (a->left != &sentinel)
					a = a->left;
				b = unlinkproperty(node->right, a->name, &temp);
				temp->level = node->level;
				temp->left = node->left;
				temp->right = b;
				node = temp;
			}
			else {
				a = node->left;
				while (a->right != &sentinel)
					a = a->right;
				b = unlinkproperty(node->left, a->name, &temp);
				temp->level = node->level;
				temp->left = b;
				temp->right = node->right;
				node = temp;
			}
		}

		if (node->left->level < node->level - 1 || node->right->level < node->level - 1)
		{
			if (node->right->level > --node->level)
				node->right->level = node->level;
			node = skew(node);
			node->right = skew(node->right);
			node->right->right = skew(node->right->right);
			node = split(node);
			node->right = split(node->right);
		}
	}
	return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
leaq 0x1afd5(%rip), %rax     # 0x47de0
cmpq %rax, -0x10(%rbp)
je 0x2d08d
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
addq $0x38, %rsi
callq 0x32d0
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
jge 0x2ce52
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x2cdf0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
jmp 0x2cfbe
cmpl $0x0, -0x3c(%rbp)
jle 0x2ce7d
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x2cdf0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
jmp 0x2cfbc
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
leaq 0x1af4d(%rip), %rcx     # 0x47de0
cmpq %rcx, (%rax)
jne 0x2ceb9
movq -0x10(%rbp), %rax
leaq 0x1af3d(%rip), %rcx     # 0x47de0
cmpq %rcx, 0x8(%rax)
jne 0x2ceb9
leaq 0x1af30(%rip), %rax     # 0x47de0
movq %rax, -0x8(%rbp)
jmp 0x2d095
movq -0x10(%rbp), %rax
leaq 0x1af1c(%rip), %rcx     # 0x47de0
cmpq %rcx, (%rax)
jne 0x2cf41
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
leaq 0x1af00(%rip), %rcx     # 0x47de0
cmpq %rcx, (%rax)
je 0x2cef2
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x2ced5
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x30(%rbp), %rsi
addq $0x38, %rsi
leaq -0x28(%rbp), %rdx
callq 0x2cdf0
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
movq -0x28(%rbp), %rax
movl %ecx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x2cfb8
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
leaq 0x1ae89(%rip), %rcx     # 0x47de0
cmpq %rcx, 0x8(%rax)
je 0x2cf6b
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x2cf4c
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x30(%rbp), %rsi
addq $0x38, %rsi
leaq -0x28(%rbp), %rdx
callq 0x2cdf0
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
movq -0x28(%rbp), %rax
movl %ecx, 0x10(%rax)
movq -0x38(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x2cfba
jmp 0x2cfbc
jmp 0x2cfbe
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl 0x10(%rax), %eax
movq -0x10(%rbp), %rcx
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jl 0x2cff3
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movl 0x10(%rax), %eax
movq -0x10(%rbp), %rcx
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x2d08b
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movl 0x10(%rax), %eax
movq -0x10(%rbp), %rdx
movl 0x10(%rdx), %ecx
addl $-0x1, %ecx
movl %ecx, 0x10(%rdx)
cmpl %ecx, %eax
jle 0x2d021
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movl %ecx, 0x10(%rax)
movq -0x10(%rbp), %rdi
callq 0x2cc50
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x2cc50
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rdi
callq 0x2cc50
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rdi
callq 0x2cca0
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x2cca0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
jmp 0x2d08d
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nop