// File: CMU-SAFARI[P]MQSim/src/ssd/TSU_OutofOrder.cpp
// Function: SSD_Components::TSU_OutOfOrder::~TSU_OutOfOrder()
TSU_OutOfOrder::~TSU_OutOfOrder()
{
	for (unsigned int channelID = 0; channelID < channel_count; channelID++)
	{
		delete[] UserReadTRQueue[channelID];
		delete[] UserWriteTRQueue[channelID];
		delete[] GCReadTRQueue[channelID];
		delete[] GCWriteTRQueue[channelID];
		delete[] GCEraseTRQueue[channelID];
		delete[] MappingReadTRQueue[channelID];
		delete[] MappingWriteTRQueue[channelID];
	}
	delete[] UserReadTRQueue;
	delete[] UserWriteTRQueue;
	delete[] GCReadTRQueue;
	delete[] GCWriteTRQueue;
	delete[] GCEraseTRQueue;
	delete[] MappingReadTRQueue;
	delete[] MappingWriteTRQueue;
}

// Assembly:
subq $0x138, %rsp            # imm = 0x138
movq %rdi, 0x130(%rsp)
movq 0x130(%rsp), %rax
movq %rax, 0x120(%rsp)
leaq 0x3ca2a(%rip), %rcx     # 0xd9c30
addq $0x10, %rcx
movq %rcx, (%rax)
movl $0x0, 0x12c(%rsp)
movq 0x120(%rsp), %rcx
movl 0x12c(%rsp), %eax
cmpl 0x44(%rcx), %eax
jae 0x9d66c
movq 0x120(%rsp), %rax
movq 0xb0(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x118(%rsp)
cmpq $0x0, %rax
je 0x9d2d0
movq 0x118(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0x108(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0x110(%rsp)
je 0x9d2c3
movq 0x110(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0x100(%rsp)
callq 0x90f30
movq 0x118(%rsp), %rcx
movq 0x100(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x110(%rsp)
jne 0x9d28a
movq 0x108(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xb8(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0xf8(%rsp)
cmpq $0x0, %rax
je 0x9d370
movq 0xf8(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0xe8(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0xf0(%rsp)
je 0x9d363
movq 0xf0(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0xe0(%rsp)
callq 0x90f30
movq 0xf8(%rsp), %rcx
movq 0xe0(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0xf0(%rsp)
jne 0x9d32a
movq 0xe8(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xc0(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0xd8(%rsp)
cmpq $0x0, %rax
je 0x9d410
movq 0xd8(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0xc8(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0xd0(%rsp)
je 0x9d403
movq 0xd0(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0xc0(%rsp)
callq 0x90f30
movq 0xd8(%rsp), %rcx
movq 0xc0(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0xd0(%rsp)
jne 0x9d3ca
movq 0xc8(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xc8(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0xb8(%rsp)
cmpq $0x0, %rax
je 0x9d4b0
movq 0xb8(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0xa8(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0xb0(%rsp)
je 0x9d4a3
movq 0xb0(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0xa0(%rsp)
callq 0x90f30
movq 0xb8(%rsp), %rcx
movq 0xa0(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0xb0(%rsp)
jne 0x9d46a
movq 0xa8(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xd0(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x98(%rsp)
cmpq $0x0, %rax
je 0x9d550
movq 0x98(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0x88(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0x90(%rsp)
je 0x9d543
movq 0x90(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0x80(%rsp)
callq 0x90f30
movq 0x98(%rsp), %rcx
movq 0x80(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x90(%rsp)
jne 0x9d50a
movq 0x88(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xd8(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x78(%rsp)
cmpq $0x0, %rax
je 0x9d5d2
movq 0x78(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0x68(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0x70(%rsp)
je 0x9d5c8
movq 0x70(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0x60(%rsp)
callq 0x90f30
movq 0x78(%rsp), %rcx
movq 0x60(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x70(%rsp)
jne 0x9d59e
movq 0x68(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xe0(%rax), %rax
movl 0x12c(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x58(%rsp)
cmpq $0x0, %rax
je 0x9d654
movq 0x58(%rsp), %rcx
movq %rcx, %rax
addq $-0x8, %rax
movq %rax, 0x48(%rsp)
imulq $0x108, -0x8(%rcx), %rdx # imm = 0x108
movq %rcx, %rax
addq %rdx, %rax
cmpq %rax, %rcx
movq %rax, 0x50(%rsp)
je 0x9d64a
movq 0x50(%rsp), %rdi
addq $-0x108, %rdi           # imm = 0xFEF8
movq %rdi, 0x40(%rsp)
callq 0x90f30
movq 0x58(%rsp), %rcx
movq 0x40(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x50(%rsp)
jne 0x9d620
movq 0x48(%rsp), %rdi
callq 0x8570
jmp 0x9d656
movl 0x12c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x12c(%rsp)
jmp 0x9d218
movq 0x120(%rsp), %rax
movq 0xb0(%rax), %rax
movq %rax, 0x38(%rsp)
cmpq $0x0, %rax
je 0x9d690
movq 0x38(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xb8(%rax), %rax
movq %rax, 0x30(%rsp)
cmpq $0x0, %rax
je 0x9d6b4
movq 0x30(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xc0(%rax), %rax
movq %rax, 0x28(%rsp)
cmpq $0x0, %rax
je 0x9d6d8
movq 0x28(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xc8(%rax), %rax
movq %rax, 0x20(%rsp)
cmpq $0x0, %rax
je 0x9d6fc
movq 0x20(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xd0(%rax), %rax
movq %rax, 0x18(%rsp)
cmpq $0x0, %rax
je 0x9d720
movq 0x18(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xd8(%rax), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
je 0x9d744
movq 0x10(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rax
movq 0xe0(%rax), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x9d768
movq 0x8(%rsp), %rdi
callq 0x8570
movq 0x120(%rsp), %rdi
callq 0x9b090
addq $0x138, %rsp            # imm = 0x138
retq
nopl (%rax)