// File: /workspace/github_cpp_makefile_star2_O3/auton1[P]viterbi/header.cpp
// Function: header::add_FILTER_descriptor(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int)
int header::add_FILTER_descriptor(const string &in, int index)
{
	size_t found_end=in.find_last_of(">");
	string details = in.substr(0, found_end);
	vector<string> tokens;
	tokenize(details, ',', tokens);
	if (tokens.size() < 2)
		LOG.error("Expected at least 2 parts in FILTER definition: " + in);

	string Description;
	Field_description I;
	I.Field = "FILTER";
	vector<string> entry;

	for (unsigned int ui=0; ui<tokens.size(); ui++)
	{
		tokenize(tokens[ui], '=', entry);
		if (entry[0] == "ID") I.ID = entry[1];
		else if (entry[0] == "Description")
		{
			I.Description = entry[1];
		}
		else if (entry[0] == "IDX")
		{
			has_idx = true;
			I.idx = str2int(entry[1]);
		}
		else
		{
			if (I.Other != "")
				I.Other += ",";
			I.Other += tokens[ui];
		}
	}

	if (I.ID == "") LOG.error("ID required in FILTER field description: " + in);
	if (I.Description == "") LOG.error("Description required in FILTER field description: " + in);
	if ((I.idx == -1) && (has_idx)) LOG.error("Missing index in FILTER field description: " + in);
	if (I.ID != "PASS") parsed_lines.push_back(I);

	if (I.idx != -1)
	{
		FILTER_map[I.idx] = I;
		FILTER_reverse_map[I.ID] = I.idx;
		return 0;
	}
	else
	{
		if ( INFO_reverse_map.find( I.ID ) != INFO_reverse_map.end() )
		{
			FILTER_map[ INFO_reverse_map[ I.ID ] ] = I;
			FILTER_reverse_map[I.ID] = INFO_reverse_map[ I.ID ];
			return 0;
		}
		else if ( FORMAT_reverse_map.find( I.ID ) != FORMAT_reverse_map.end() )
		{
			FILTER_map[ FORMAT_reverse_map[ I.ID ] ] = I;
			FILTER_reverse_map[I.ID] = FORMAT_reverse_map[ I.ID ];
			return 0;
		}
		else if ( FILTER_reverse_map.find( I.ID ) != FILTER_reverse_map.end() )
			return 0;
		else
		{
			FILTER_map[index] = I;
			FILTER_reverse_map[I.ID] = index;
			return 1;
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
movq %rsi, %r15
movq %rdi, %r14
movl %edx, 0xc(%rsp)
leaq 0x24190(%rip), %rsi     # 0x38bb8
movl $0x1, %ecx
movq %r15, %rdi
movq $-0x1, %rdx
callq 0x5890
leaq 0xf8(%rsp), %rbx
movq %rbx, %rdi
movq %r15, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x5480
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdx
movaps %xmm0, (%rdx)
movq $0x0, 0x10(%rdx)
movq %rbx, %rdi
movl $0x2c, %esi
callq 0x16a0a
movq 0x18(%rsp), %rax
subq 0x10(%rsp), %rax
cmpq $0x20, %rax
ja 0x14aca
leaq 0x24457(%rip), %rsi     # 0x38ee2
leaq 0xd8(%rsp), %rdi
movq %r15, %rdx
callq 0xb777
leaq 0x34a06(%rip), %rdi     # 0x494a8
leaq 0xd8(%rsp), %rsi
movl $0x1, %edx
callq 0x36ec8
leaq 0xe8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x14aca
callq 0x5410
leaq 0x68(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x118(%rsp), %rdi
callq 0x174bc
movq %r15, 0x50(%rsp)
movq %r14, 0x48(%rsp)
leaq 0x118(%rsp), %rdi
movq 0x8(%rdi), %rdx
leaq 0x2400f(%rip), %rcx     # 0x38b17
movl $0x6, %r8d
xorl %esi, %esi
callq 0x5690
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movq $0x0, 0x40(%rsp)
movq 0x10(%rsp), %rdi
cmpq %rdi, 0x18(%rsp)
je 0x14c46
leaq 0x248(%rsp), %r14
movl $0x1, %r12d
xorl %ebx, %ebx
leaq 0x30(%rsp), %r15
leaq 0x23f28(%rip), %r13     # 0x38a7a
leaq 0x24114(%rip), %rbp     # 0x38c6d
shlq $0x5, %rbx
addq %rbx, %rdi
movl $0x3d, %esi
movq %r15, %rdx
callq 0x16a0a
movq 0x30(%rsp), %rdi
movq %r13, %rsi
callq 0x50e0
movq 0x30(%rsp), %rsi
testl %eax, %eax
je 0x14be4
movq %rsi, %rdi
movq %rbp, %rsi
callq 0x50e0
movq 0x30(%rsp), %rsi
testl %eax, %eax
je 0x14bee
movq %rsi, %rdi
leaq 0x240e7(%rip), %rsi     # 0x38c88
callq 0x50e0
testl %eax, %eax
je 0x14c21
movq %r14, %rdi
leaq 0x25323(%rip), %rsi     # 0x39ed7
callq 0x50e0
testl %eax, %eax
je 0x14bcc
movq %r14, %rdi
leaq 0x240c5(%rip), %rsi     # 0x38c8c
callq 0x5870
movq 0x10(%rsp), %rax
movq (%rax,%rbx), %rsi
movq 0x8(%rax,%rbx), %rdx
movq %r14, %rdi
callq 0x50f0
jmp 0x14bff
leaq 0x138(%rsp), %rdi
jmp 0x14bf6
leaq 0x1a8(%rsp), %rdi
addq $0x20, %rsi
callq 0x51f0
movl %r12d, %ebx
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rax
subq %rdi, %rax
sarq $0x5, %rax
incl %r12d
cmpq %rbx, %rax
ja 0x14b59
jmp 0x14c46
movq 0x48(%rsp), %rax
movb $0x1, 0x8(%rax)
movq 0x30(%rsp), %rdi
addq $0x20, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x16afa
movl %eax, 0x158(%rsp)
jmp 0x14bff
leaq 0x138(%rsp), %r14
leaq 0x25282(%rip), %rsi     # 0x39ed7
movq %r14, %rdi
callq 0x50e0
testl %eax, %eax
movq 0x48(%rsp), %rbp
movq 0x50(%rsp), %rbx
jne 0x14cb1
leaq 0x242a1(%rip), %rsi     # 0x38f13
leaq 0xb8(%rsp), %rdi
movq %rbx, %rdx
callq 0xb777
leaq 0x3481f(%rip), %rdi     # 0x494a8
leaq 0xb8(%rsp), %rsi
movl $0x1, %edx
callq 0x36ec8
leaq 0xc8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x14cb1
callq 0x5410
leaq 0x1a8(%rsp), %r15
leaq 0x25217(%rip), %rsi     # 0x39ed7
movq %r15, %rdi
callq 0x50e0
testl %eax, %eax
jne 0x14d12
leaq 0x2426a(%rip), %rsi     # 0x38f3d
leaq 0x98(%rsp), %rdi
movq %rbx, %rdx
callq 0xb777
leaq 0x347be(%rip), %rdi     # 0x494a8
leaq 0x98(%rsp), %rsi
movl $0x1, %edx
callq 0x36ec8
leaq 0xa8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x14d12
callq 0x5410
cmpl $-0x1, 0x158(%rsp)
jne 0x14d62
cmpb $0x1, 0x8(%rbp)
jne 0x14d62
leaq 0x24247(%rip), %rsi     # 0x38f70
leaq 0x78(%rsp), %rdi
movq %rbx, %rdx
callq 0xb777
leaq 0x3476b(%rip), %rdi     # 0x494a8
leaq 0x78(%rsp), %rsi
movl $0x1, %edx
callq 0x36ec8
leaq 0x88(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x14d62
callq 0x5410
leaq 0x23850(%rip), %rsi     # 0x385b9
movq %r14, %rdi
callq 0x50e0
testl %eax, %eax
je 0x14d86
leaq 0x40(%rbp), %rdi
leaq 0x118(%rsp), %rsi
callq 0x17752
cmpl $-0x1, 0x158(%rsp)
je 0x14e88
leaq 0x158(%rsp), %rsi
leaq 0x90(%rbp), %rdi
callq 0x17782
movq %rax, %rbx
leaq 0x118(%rsp), %r12
movq %rax, %rdi
movq %r12, %rsi
callq 0x51f0
leaq 0x20(%rbx), %rdi
movq %r14, %rsi
callq 0x51f0
leaq 0x160(%rsp), %rsi
movq -0x8(%rsi), %rax
movq %rax, 0x40(%rbx)
leaq 0x48(%rbx), %rdi
callq 0x51f0
leaq 0x68(%rbx), %rdi
leaq 0x180(%rsp), %rsi
callq 0x51f0
movl 0x1a0(%rsp), %eax
movl %eax, 0x88(%rbx)
leaq 0x90(%rbx), %rdi
movq %r15, %rsi
callq 0x51f0
movl $0xb0, %esi
leaq (%rbx,%rsi), %rdi
addq %r12, %rsi
callq 0x51f0
movl $0xd0, %esi
leaq (%rbx,%rsi), %rdi
addq %r12, %rsi
callq 0x51f0
movl $0xf0, %esi
leaq (%rbx,%rsi), %rdi
addq %r12, %rsi
callq 0x51f0
movl $0x110, %esi            # imm = 0x110
leaq (%rbx,%rsi), %rdi
addq %r12, %rsi
callq 0x51f0
movl $0x130, %eax            # imm = 0x130
addq %rax, %rbx
addq %rax, %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x51f0
movl 0x158(%rsp), %ebx
addq $0x150, %rbp            # imm = 0x150
movq %rbp, %rdi
movq %r14, %rsi
callq 0x177e8
jmp 0x150c7
leaq 0x180(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x18140
leaq 0x188(%rbp), %rcx
cmpq %rcx, %rax
je 0x14faa
movq %r12, %rdi
movq %r14, %rsi
callq 0x177e8
leaq 0x90(%rbp), %rdi
movq %rax, %rsi
callq 0x17782
movq %rax, %rbx
leaq 0x118(%rsp), %r13
movq %rax, %rdi
movq %r13, %rsi
callq 0x51f0
leaq 0x20(%rbx), %rdi
movq %r14, %rsi
callq 0x51f0
leaq 0x160(%rsp), %rsi
movq -0x8(%rsi), %rax
movq %rax, 0x40(%rbx)
leaq 0x48(%rbx), %rdi
callq 0x51f0
leaq 0x68(%rbx), %rdi
leaq 0x180(%rsp), %rsi
callq 0x51f0
movl 0x1a0(%rsp), %eax
movl %eax, 0x88(%rbx)
leaq 0x90(%rbx), %rdi
movq %r15, %rsi
callq 0x51f0
movl $0xb0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xd0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xf0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x110, %esi            # imm = 0x110
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x130, %eax            # imm = 0x130
addq %rax, %rbx
addq %rax, %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x51f0
movq %r12, %rdi
movq %r14, %rsi
callq 0x177e8
movl (%rax), %ebx
addq $0x150, %rbp            # imm = 0x150
movq %rbp, %rdi
movq %r14, %rsi
callq 0x177e8
jmp 0x150c7
leaq 0x1b0(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x18140
leaq 0x1b8(%rbp), %rcx
cmpq %rcx, %rax
je 0x1512a
movq %r12, %rdi
movq %r14, %rsi
callq 0x177e8
leaq 0x90(%rbp), %rdi
movq %rax, %rsi
callq 0x17782
movq %rax, %rbx
leaq 0x118(%rsp), %r13
movq %rax, %rdi
movq %r13, %rsi
callq 0x51f0
leaq 0x20(%rbx), %rdi
movq %r14, %rsi
callq 0x51f0
leaq 0x160(%rsp), %rsi
movq -0x8(%rsi), %rax
movq %rax, 0x40(%rbx)
leaq 0x48(%rbx), %rdi
callq 0x51f0
leaq 0x68(%rbx), %rdi
leaq 0x180(%rsp), %rsi
callq 0x51f0
movl 0x1a0(%rsp), %eax
movl %eax, 0x88(%rbx)
leaq 0x90(%rbx), %rdi
movq %r15, %rsi
callq 0x51f0
movl $0xb0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xd0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xf0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x110, %esi            # imm = 0x110
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x130, %eax            # imm = 0x130
addq %rax, %rbx
addq %rax, %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x51f0
movq %r12, %rdi
movq %r14, %rsi
callq 0x177e8
movl (%rax), %ebx
addq $0x150, %rbp            # imm = 0x150
movq %rbp, %rdi
movq %r14, %rsi
callq 0x177e8
movl %ebx, (%rax)
xorl %ebx, %ebx
leaq 0x30(%rsp), %rdi
callq 0xc4da
leaq 0x118(%rsp), %rdi
callq 0xfb7c
movq 0x58(%rsp), %rdi
leaq 0x68(%rsp), %rax
cmpq %rax, %rdi
je 0x150f6
callq 0x5410
leaq 0x10(%rsp), %rdi
callq 0xc4da
leaq 0x108(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x15116
callq 0x5410
movl %ebx, %eax
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x150(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x18140
leaq 0x158(%rbp), %rcx
xorl %ebx, %ebx
cmpq %rcx, %rax
jne 0x150cb
addq $0x90, %rbp
leaq 0xc(%rsp), %rsi
movq %rbp, %rdi
callq 0x17782
movq %rax, %rbx
leaq 0x118(%rsp), %r13
movq %rax, %rdi
movq %r13, %rsi
callq 0x51f0
leaq 0x20(%rbx), %rdi
movq %r14, %rsi
callq 0x51f0
leaq 0x160(%rsp), %rsi
movq -0x8(%rsi), %rax
movq %rax, 0x40(%rbx)
leaq 0x48(%rbx), %rdi
callq 0x51f0
leaq 0x68(%rbx), %rdi
leaq 0x180(%rsp), %rsi
callq 0x51f0
movl 0x1a0(%rsp), %eax
movl %eax, 0x88(%rbx)
leaq 0x90(%rbx), %rdi
movq %r15, %rsi
callq 0x51f0
movl $0xb0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xd0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0xf0, %esi
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x110, %esi            # imm = 0x110
leaq (%rbx,%rsi), %rdi
addq %r13, %rsi
callq 0x51f0
movl $0x130, %eax            # imm = 0x130
addq %rax, %rbx
addq %rax, %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x51f0
movl 0xc(%rsp), %ebx
movq %r12, %rdi
movq %r14, %rsi
callq 0x177e8
movl %ebx, (%rax)
movl $0x1, %ebx
jmp 0x150cb
jmp 0x15298
jmp 0x15298
movq %rax, %rbx
leaq 0x88(%rsp), %rax
jmp 0x15266
jmp 0x15298
movq %rax, %rbx
leaq 0xa8(%rsp), %rax
jmp 0x15266
movq %rax, %rbx
leaq 0xc8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1529b
callq 0x5410
jmp 0x1529b
movq %rax, %rbx
leaq 0xe8(%rsp), %rax
movq -0x10(%rax), %rdi
jmp 0x152bc
movq %rax, %rbx
jmp 0x152a5
movq %rax, %rbx
jmp 0x152b2
movq %rax, %rbx
jmp 0x152c6
jmp 0x15298
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xc4da
leaq 0x118(%rsp), %rdi
callq 0xfb7c
movq 0x58(%rsp), %rdi
leaq 0x68(%rsp), %rax
cmpq %rax, %rdi
je 0x152c6
callq 0x5410
leaq 0x10(%rsp), %rdi
callq 0xc4da
leaq 0x108(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x152e6
callq 0x5410
movq %rbx, %rdi
callq 0x57d0