// File: melop[P]admixem/config.cpp
// Function: RecombProbConfigurations::fnEraseNonMonotonic(std::vector<double, std::allocator<double>>*, std::vector<double, std::allocator<double>>*, std::vector<double, std::allocator<double>>*)
void RecombProbConfigurations::fnEraseNonMonotonic(vector<double> * vMale, vector<double> * vFemale, vector<double> * vPos) {
	
	double nCurrMale , nCurrFemale , nCurrPos;
	nCurrMale = nCurrFemale = nCurrPos = -1;
	vector< size_t > vToDelete;
	for(size_t i=0;i<vPos->size();i++) {

		if (nCurrMale >= vMale->at(i) || nCurrFemale >= vFemale->at(i) || nCurrPos >= vPos->at(i)) {
			vToDelete.push_back(i);
		}
		nCurrMale = vMale->at(i);
		nCurrFemale = vFemale->at(i);
		nCurrPos = vPos->at(i);
	}

	//start deleting from the back;

	for(vector< size_t >::reverse_iterator it=vToDelete.rbegin(); it!=vToDelete.rend();++it) { //iterate from the end
		vMale->erase(vMale->begin() + *it);
		vFemale->erase(vFemale->begin() + *it);
		vPos->erase(vPos->begin() + *it);

	}

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x180, %rsp            # imm = 0x180
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movsd 0x59685(%rip), %xmm0    # 0x76698
movsd %xmm0, -0x38(%rbp)
movsd 0x59678(%rip), %xmm0    # 0x76698
movsd %xmm0, -0x30(%rbp)
movsd 0x5966b(%rip), %xmm0    # 0x76698
movsd %xmm0, -0x28(%rbp)
leaq -0x50(%rbp), %rdi
callq 0x2aa70
movq $0x0, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0xe0(%rbp)
movq -0x20(%rbp), %rdi
callq 0x2a780
movq %rax, %rcx
movq -0xe0(%rbp), %rax
cmpq %rcx, %rax
jae 0x1d1c0
movsd -0x28(%rbp), %xmm0
movsd %xmm0, -0xf0(%rbp)
movq -0x10(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0xe8(%rbp)
jmp 0x1d08d
movsd -0xf0(%rbp), %xmm0
movq -0xe8(%rbp), %rax
ucomisd (%rax), %xmm0
jae 0x1d112
movsd -0x30(%rbp), %xmm0
movsd %xmm0, -0x100(%rbp)
movq -0x18(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0xf8(%rbp)
jmp 0x1d0c5
movsd -0x100(%rbp), %xmm0
movq -0xf8(%rbp), %rax
ucomisd (%rax), %xmm0
jae 0x1d112
movsd -0x38(%rbp), %xmm0
movsd %xmm0, -0x110(%rbp)
movq -0x20(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0x108(%rbp)
jmp 0x1d0fd
movsd -0x110(%rbp), %xmm0
movq -0x108(%rbp), %rax
ucomisd (%rax), %xmm0
jb 0x1d13d
leaq -0x50(%rbp), %rdi
leaq -0x58(%rbp), %rsi
callq 0x2aa90
jmp 0x1d121
jmp 0x1d13d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x50(%rbp), %rdi
callq 0x2ad20
jmp 0x1d3ad
movq -0x10(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0x118(%rbp)
jmp 0x1d153
movq -0x118(%rbp), %rax
movsd (%rax), %xmm0
movsd %xmm0, -0x28(%rbp)
movq -0x18(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0x120(%rbp)
jmp 0x1d179
movq -0x120(%rbp), %rax
movsd (%rax), %xmm0
movsd %xmm0, -0x30(%rbp)
movq -0x20(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x2a7a0
movq %rax, -0x128(%rbp)
jmp 0x1d19f
movq -0x128(%rbp), %rax
movsd (%rax), %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0x1d043
leaq -0x70(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x2ab00
leaq -0x78(%rbp), %rdi
movq %rdi, -0x138(%rbp)
leaq -0x50(%rbp), %rsi
callq 0x2ab80
movq -0x138(%rbp), %rsi
leaq -0x70(%rbp), %rdi
callq 0x2ab50
movb %al, -0x129(%rbp)
jmp 0x1d1f9
movb -0x129(%rbp), %al
testb $0x1, %al
jne 0x1d208
jmp 0x1d39b
movq -0x10(%rbp), %rdi
movq %rdi, -0x148(%rbp)
callq 0x2a6e0
movq %rax, -0x90(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x2ac80
movq %rax, -0x140(%rbp)
jmp 0x1d231
movq -0x140(%rbp), %rax
movq (%rax), %rsi
leaq -0x90(%rbp), %rdi
callq 0x2ac40
movq %rax, -0x88(%rbp)
leaq -0x80(%rbp), %rdi
leaq -0x88(%rbp), %rsi
callq 0x2acb0
movq -0x148(%rbp), %rdi
movq -0x80(%rbp), %rsi
callq 0x2abd0
movq %rax, -0x150(%rbp)
jmp 0x1d277
movq -0x150(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x18(%rbp), %rdi
movq %rdi, -0x160(%rbp)
callq 0x2a6e0
movq %rax, -0xb0(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x2ac80
movq %rax, -0x158(%rbp)
jmp 0x1d2ae
movq -0x158(%rbp), %rax
movq (%rax), %rsi
leaq -0xb0(%rbp), %rdi
callq 0x2ac40
movq %rax, -0xa8(%rbp)
leaq -0xa0(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
callq 0x2acb0
movq -0x160(%rbp), %rdi
movq -0xa0(%rbp), %rsi
callq 0x2abd0
movq %rax, -0x168(%rbp)
jmp 0x1d2fa
movq -0x168(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x20(%rbp), %rdi
movq %rdi, -0x178(%rbp)
callq 0x2a6e0
movq %rax, -0xd0(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x2ac80
movq %rax, -0x170(%rbp)
jmp 0x1d331
movq -0x170(%rbp), %rax
movq (%rax), %rsi
leaq -0xd0(%rbp), %rdi
callq 0x2ac40
movq %rax, -0xc8(%rbp)
leaq -0xc0(%rbp), %rdi
leaq -0xc8(%rbp), %rsi
callq 0x2acb0
movq -0x178(%rbp), %rdi
movq -0xc0(%rbp), %rsi
callq 0x2abd0
movq %rax, -0x180(%rbp)
jmp 0x1d37d
movq -0x180(%rbp), %rax
movq %rax, -0xd8(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x2acf0
jmp 0x1d396
jmp 0x1d1cd
leaq -0x50(%rbp), %rdi
callq 0x2ad20
addq $0x180, %rsp            # imm = 0x180
popq %rbp
retq
movq -0x60(%rbp), %rdi
callq 0x8860
nopw %cs:(%rax,%rax)