// File: ys1998[P]spsim/src/lists.cpp
// Function: FreeList::remove(int)
void FreeList::remove(int reg){
	if(reg < 0 || reg >= NUM_PHY_REGS)
		error_msg("free_list", std::string("Index ") + std::to_string(reg) + " greater than maximum size (" + std::to_string(NUM_PHY_REGS) + ")");
	if(!free[reg]){
		if(LOG_LEVEL >= 1)
			warning_msg("free_list", std::string("Register ") + std::to_string(reg) + " is not free; can't remove from free list");
	}else{
		free[reg] = false;	
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x210, %rsp            # imm = 0x210
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x1e8(%rbp)
cmpl $0x0, -0xc(%rbp)
jl 0x1308d
cmpl $0x40, -0xc(%rbp)
jl 0x132f2
leaq -0x31(%rbp), %rdi
movq %rdi, -0x1f0(%rbp)
callq 0x3490
movq -0x1f0(%rbp), %rdx
leaq 0xf1a5(%rip), %rsi      # 0x22250
leaq -0x30(%rbp), %rdi
callq 0x6020
jmp 0x130b6
leaq -0xe9(%rbp), %rdi
movq %rdi, -0x1f8(%rbp)
callq 0x3490
movq -0x1f8(%rbp), %rdx
leaq 0xf183(%rip), %rsi      # 0x2225a
leaq -0xe8(%rbp), %rdi
callq 0x6020
jmp 0x130e5
movl -0xc(%rbp), %esi
leaq -0x110(%rbp), %rdi
callq 0x10880
jmp 0x130f6
leaq -0xc8(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
leaq -0x110(%rbp), %rdx
callq 0x10650
jmp 0x13112
leaq 0xf148(%rip), %rdx      # 0x22261
leaq -0xa8(%rbp), %rdi
leaq -0xc8(%rbp), %rsi
callq 0x10720
jmp 0x1312e
leaq -0x130(%rbp), %rdi
movl $0x40, %esi
callq 0x10880
jmp 0x13141
leaq -0x88(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
leaq -0x130(%rbp), %rdx
callq 0x10650
jmp 0x1315d
leaq 0xef3a(%rip), %rdx      # 0x2209e
leaq -0x68(%rbp), %rdi
leaq -0x88(%rbp), %rsi
callq 0x10720
jmp 0x13176
leaq -0x30(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x163d0
jmp 0x13185
leaq -0x68(%rbp), %rdi
callq 0x31e0
leaq -0x88(%rbp), %rdi
callq 0x31e0
leaq -0x130(%rbp), %rdi
callq 0x31e0
leaq -0xa8(%rbp), %rdi
callq 0x31e0
leaq -0xc8(%rbp), %rdi
callq 0x31e0
leaq -0x110(%rbp), %rdi
callq 0x31e0
leaq -0xe8(%rbp), %rdi
callq 0x31e0
leaq -0xe9(%rbp), %rdi
callq 0x3300
leaq -0x30(%rbp), %rdi
callq 0x31e0
leaq -0x31(%rbp), %rdi
callq 0x3300
jmp 0x132f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x132e4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x132cf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x132c3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x132b7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x132ab
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x1329f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13293
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13287
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x31e0
leaq -0x88(%rbp), %rdi
callq 0x31e0
leaq -0x130(%rbp), %rdi
callq 0x31e0
leaq -0xa8(%rbp), %rdi
callq 0x31e0
leaq -0xc8(%rbp), %rdi
callq 0x31e0
leaq -0x110(%rbp), %rdi
callq 0x31e0
leaq -0xe8(%rbp), %rdi
callq 0x31e0
leaq -0xe9(%rbp), %rdi
callq 0x3300
leaq -0x30(%rbp), %rdi
callq 0x31e0
leaq -0x31(%rbp), %rdi
callq 0x3300
jmp 0x134f1
movq -0x1e8(%rbp), %rax
movslq -0xc(%rbp), %rcx
testb $0x1, (%rax,%rcx)
jne 0x134d9
leaq 0x1bf8a(%rip), %rax     # 0x2f298
cmpl $0x1, (%rax)
jl 0x134d7
leaq -0x151(%rbp), %rdi
movq %rdi, -0x200(%rbp)
callq 0x3490
movq -0x200(%rbp), %rdx
leaq 0xef18(%rip), %rsi      # 0x22250
leaq -0x150(%rbp), %rdi
callq 0x6020
jmp 0x13346
leaq -0x1b9(%rbp), %rdi
movq %rdi, -0x208(%rbp)
callq 0x3490
movq -0x208(%rbp), %rdx
leaq 0xef17(%rip), %rsi      # 0x2227e
leaq -0x1b8(%rbp), %rdi
callq 0x6020
jmp 0x13375
movl -0xc(%rbp), %esi
leaq -0x1e0(%rbp), %rdi
callq 0x10880
jmp 0x13386
leaq -0x198(%rbp), %rdi
leaq -0x1b8(%rbp), %rsi
leaq -0x1e0(%rbp), %rdx
callq 0x10650
jmp 0x133a2
leaq 0xef08(%rip), %rdx      # 0x222b1
leaq -0x178(%rbp), %rdi
leaq -0x198(%rbp), %rsi
callq 0x10720
jmp 0x133be
leaq -0x150(%rbp), %rdi
leaq -0x178(%rbp), %rsi
callq 0x16960
jmp 0x133d3
leaq -0x178(%rbp), %rdi
callq 0x31e0
leaq -0x198(%rbp), %rdi
callq 0x31e0
leaq -0x1e0(%rbp), %rdi
callq 0x31e0
leaq -0x1b8(%rbp), %rdi
callq 0x31e0
leaq -0x1b9(%rbp), %rdi
callq 0x3300
leaq -0x150(%rbp), %rdi
callq 0x31e0
leaq -0x151(%rbp), %rdi
callq 0x3300
jmp 0x134d7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x134c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x134b1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x134a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13499
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x1348d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x178(%rbp), %rdi
callq 0x31e0
leaq -0x198(%rbp), %rdi
callq 0x31e0
leaq -0x1e0(%rbp), %rdi
callq 0x31e0
leaq -0x1b8(%rbp), %rdi
callq 0x31e0
leaq -0x1b9(%rbp), %rdi
callq 0x3300
leaq -0x150(%rbp), %rdi
callq 0x31e0
leaq -0x151(%rbp), %rdi
callq 0x3300
jmp 0x134f1
jmp 0x134e8
movq -0x1e8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movb $0x0, (%rax,%rcx)
addq $0x210, %rsp            # imm = 0x210
popq %rbp
retq
movq -0x40(%rbp), %rdi
callq 0x3480
nopw (%rax,%rax)