// File: /workspace/github_cpp_makefile_star2_O1/enbock[P]Warp10Server/ulib/src/Thread.cpp
// Function: u::ThreadSystem::destroy(u::Thread*)
void ThreadSystem::destroy(Thread *thread)
{
	int64 i,l;
	_access.lock();
	l = _run.size();
	for(i=0; i<l; i++)
	{
		if(_run.at(i) == thread)
		{
			_run.erase(i);
#ifndef NDEBUG
			finish++;
			if(ThreadSystem::isTerminating)
				trace("Run queue="+Object::int2string(_build.size())
				+ "\trun="+Object::int2string(_run.size())
				+ "(peak:"+Object::int2string(peakRun)+")"
				+ "\tfinished="+Object::int2string(finish)
				);
#endif
			_access.unlock();
			delete thread;
			return;
		}
	}
	_access.unlock();
#ifndef NDEBUG
	error("A deleting thread was not found in the run queue.");
	assert(false==true);
#endif
	//delete thread;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
movq %rdi, %rbx
leaq 0x2036c1(%rip), %rdi    # 0x60e6b0
callq 0x4098c2
movq 0x20377d(%rip), %rax    # 0x60e778
movq 0x20376e(%rip), %rsi    # 0x60e770
movq %rax, %rdx
subq %rsi, %rdx
movq %rdx, %rcx
sarq $0x3, %rcx
testq %rcx, %rcx
jle 0x40b02f
addq $0x8, %rsi
addq $-0x8, %rdx
cmpq %rbx, -0x8(%rsi)
je 0x40b093
addq $0x8, %rsi
addq $-0x8, %rdx
decq %rcx
jne 0x40b01c
leaq 0x20367a(%rip), %rdi    # 0x60e6b0
callq 0x40987a
movq $0x60f580, %rdi         # imm = 0x60F580
leaq 0x18e110(%rip), %rsi    # 0x599159
callq 0x477e60
leaq 0x18e4be(%rip), %rsi    # 0x599513
movq %rax, %rdi
callq 0x477e60
leaq 0x18e021(%rip), %rsi    # 0x599085
movq %rax, %rdi
callq 0x477e60
movq %rax, %rdi
callq 0x477740
leaq 0x18e4ca(%rip), %rdi    # 0x599545
leaq 0x18e4cf(%rip), %rsi    # 0x599551
leaq 0x18e4d7(%rip), %rcx    # 0x599560
movl $0x64, %edx
callq 0x4ccba0
cmpq %rax, %rsi
je 0x40b0a1
leaq -0x8(%rsi), %rdi
callq 0x401020
addq $-0x8, 0x2036cf(%rip)   # 0x60e778
incq 0x2036d8(%rip)          # 0x60e788
cmpb $0x1, 0x2035f2(%rip)    # 0x60e6a9
jne 0x40b76a
movq $0x60f6a0, %rdi         # imm = 0x60F6A0
leaq 0x18dfae(%rip), %rsi    # 0x599079
movl $0x4, %edx
callq 0x477930
movq 0x20364c(%rip), %rsi    # 0x60e728
subq 0x20363d(%rip), %rsi    # 0x60e720
shrq $0x3, %rsi
leaq 0x210(%rsp), %rdi
callq 0x409b9e
leaq 0x248(%rsp), %rdi
leaq 0x18e4ef(%rip), %rcx    # 0x5995f2
movl $0xa, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x488d50
leaq 0xd8(%rsp), %rsi
movq %rsi, -0x10(%rsi)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x40b142
movq %rdx, 0xc8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0xd8(%rsp)
jmp 0x40b148
movups (%rcx), %xmm0
movups %xmm0, (%rsi)
movq 0x8(%rax), %rdx
leaq 0xc8(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x18e38d(%rip), %rsi    # 0x5994fb
callq 0x489510
leaq 0x78(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x40b19a
movq %rdx, 0x68(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x78(%rsp)
jmp 0x40b1a1
movups (%rcx), %xmm0
movups %xmm0, (%rbp)
movq 0x8(%rax), %rdx
movq %rdx, 0x70(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x2035b8(%rip), %rsi    # 0x60e778
subq 0x2035a9(%rip), %rsi    # 0x60e770
shrq $0x3, %rsi
leaq 0x160(%rsp), %rdi
callq 0x409b9e
movq 0x68(%rsp), %rcx
movq 0x70(%rsp), %r8
movq 0x1a0(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %esi
cmpq %rbp, %rcx
je 0x40b1fd
movq 0x78(%rsp), %rsi
leaq 0x1a8(%rsp), %rdi
cmpq %rsi, %rax
jbe 0x40b226
movl $0xf, %esi
cmpq %rdi, 0x198(%rsp)
je 0x40b221
movq 0x1a8(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x40b23a
movq 0x198(%rsp), %rsi
leaq 0x68(%rsp), %rdi
callq 0x4893d0
jmp 0x40b24b
leaq 0x198(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x488d50
leaq 0x38(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x40b26f
movq %rsi, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x40b275
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x30(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x18e268(%rip), %rsi    # 0x599501
leaq 0x28(%rsp), %rdi
callq 0x489510
leaq 0x98(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x40b2d3
movq %rdx, 0x88(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x98(%rsp)
jmp 0x40b2db
movups (%rcx), %xmm0
movups %xmm0, (%r13)
movq 0x8(%rax), %rdx
movq %rdx, 0x90(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movl 0x203494(%rip), %esi    # 0x60e790
leaq 0x108(%rsp), %rdi
callq 0x409b9e
movq 0x88(%rsp), %rcx
movq 0x90(%rsp), %r8
movq 0x148(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %esi
cmpq %r13, %rcx
je 0x40b337
movq 0x98(%rsp), %rsi
leaq 0x150(%rsp), %rdi
cmpq %rsi, %rax
jbe 0x40b360
movl $0xf, %esi
cmpq %rdi, 0x140(%rsp)
je 0x40b35b
movq 0x150(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x40b377
movq 0x140(%rsp), %rsi
leaq 0x88(%rsp), %rdi
callq 0x4893d0
jmp 0x40b388
leaq 0x140(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x488d50
leaq 0x58(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x40b3ac
movq %rsi, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0x40b3b2
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x50(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x18e032(%rip), %rsi    # 0x599408
leaq 0x48(%rsp), %rdi
callq 0x489510
leaq 0xf8(%rsp), %rsi
movq %rsi, -0x10(%rsi)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x40b410
movq %rdx, 0xe8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0xf8(%rsp)
jmp 0x40b416
movups (%rcx), %xmm0
movups %xmm0, (%rsi)
movq 0x8(%rax), %rdx
leaq 0xe8(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x18e0cc(%rip), %rsi    # 0x599508
callq 0x489510
leaq 0xb8(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x40b472
movq %rdx, 0xa8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0xb8(%rsp)
jmp 0x40b47a
movups (%rcx), %xmm0
movups %xmm0, (%r12)
movq 0x8(%rax), %rdx
movq %rdx, 0xb0(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movl 0x2032ed(%rip), %esi    # 0x60e788
leaq 0x1b8(%rsp), %rdi
callq 0x409b9e
movq 0xa8(%rsp), %rcx
movq 0xb0(%rsp), %r8
movq 0x1f8(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %esi
cmpq %r12, %rcx
je 0x40b4d6
movq 0xb8(%rsp), %rsi
leaq 0x200(%rsp), %r15
cmpq %rsi, %rax
jbe 0x40b4ff
movl $0xf, %esi
cmpq %r15, 0x1f0(%rsp)
je 0x40b4fa
movq 0x200(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x40b516
movq 0x1f0(%rsp), %rsi
leaq 0xa8(%rsp), %rdi
callq 0x4893d0
jmp 0x40b527
leaq 0x1f0(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x488d50
leaq 0x18(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x40b54b
movq %rsi, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0x40b551
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x10(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq $0x60f6a0, %rdi         # imm = 0x60F6A0
callq 0x477930
movq %rax, %r14
leaq 0x18daf7(%rip), %rsi    # 0x599085
movl $0x4, %edx
movq %rax, %rdi
callq 0x477930
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x458a80
movsbl %al, %esi
movq %r14, %rdi
callq 0x477430
movq %rax, %rdi
callq 0x476a00
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b5dd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0x1f0(%rsp), %rdi
cmpq %r15, %rdi
je 0x40b5fa
movq 0x200(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x1b8(%rsp), %rdi
callq 0x4099d0
movq 0xa8(%rsp), %rdi
cmpq %r12, %rdi
leaq 0x1a8(%rsp), %r14
leaq 0x150(%rsp), %r15
je 0x40b634
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x40b659
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b674
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0x140(%rsp), %rdi
cmpq %r15, %rdi
je 0x40b691
movq 0x150(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x108(%rsp), %rdi
callq 0x4099d0
movq 0x88(%rsp), %rdi
cmpq %r13, %rdi
je 0x40b6bb
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b6d6
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0x198(%rsp), %rdi
cmpq %r14, %rdi
je 0x40b6f3
movq 0x1a8(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x160(%rsp), %rdi
callq 0x4099d0
movq 0x68(%rsp), %rdi
cmpq %rbp, %rdi
je 0x40b717
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0xc8(%rsp), %rdi
leaq 0xd8(%rsp), %rax
cmpq %rax, %rdi
je 0x40b73c
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x258(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b75d
movq 0x258(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x210(%rsp), %rdi
callq 0x4099d0
leaq 0x202f3f(%rip), %rdi    # 0x60e6b0
callq 0x40987a
testq %rbx, %rbx
je 0x40b799
leaq 0x60(%rbx), %rdi
callq 0x4ea7e0
movq %rbx, %rdi
callq 0x4099d0
movl $0x98, %esi
movq %rbx, %rdi
callq 0x40dd10
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x40b81b
movq %rax, %rbx
jmp 0x40b828
movq %rax, %rbx
jmp 0x40b845
movq %rax, %rbx
jmp 0x40b86a
movq %rax, %rbx
jmp 0x40b885
movq %rax, %rbx
jmp 0x40b892
movq %rax, %rbx
jmp 0x40b8af
movq %rax, %rbx
jmp 0x40b8ca
movq %rax, %rbx
jmp 0x40b8d7
movq %rax, %rbx
jmp 0x40b8ee
movq %rax, %rbx
jmp 0x40b913
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b81b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x1b8(%rsp), %rdi
callq 0x404a8a
movq 0xa8(%rsp), %rdi
cmpq %r12, %rdi
je 0x40b845
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x40b86a
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b885
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x108(%rsp), %rdi
callq 0x404a8a
movq 0x88(%rsp), %rdi
cmpq %r13, %rdi
je 0x40b8af
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x40b8ca
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x160(%rsp), %rdi
callq 0x404a8a
movq 0x68(%rsp), %rdi
cmpq %rbp, %rdi
je 0x40b8ee
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x40dd10
movq 0xc8(%rsp), %rdi
leaq 0xd8(%rsp), %rax
cmpq %rax, %rdi
je 0x40b913
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x40dd10
leaq 0x210(%rsp), %rdi
callq 0x404a8a
movq %rbx, %rdi
callq 0x4b7f40