// File: haught[P]cws_plugin/cws_plugin.cpp
// Function: readGcode(char*, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&)
void readGcode(char *fileName, map<string, string> &valueMap)
{
	ifstream infile;
	infile.open(fileName);   //���ļ����������ļ��������� 
	assert(infile.is_open());   //��ʧ��,�����������Ϣ,����ֹ�������� 
	
	string s;
	std::vector<std::string> ss;
	bool headInit = false;
	while (getline(infile, s))
	{
		//cout << s << endl;
		if (s.at(0) == ';') {
			if (startsWith(s, ";START_GCODE_BEGIN")) {
				headInit = true;
				break;
			}else{
				ss = split(s.data() + 1, ":");
				if (ss.size() == 2) {
					valueMap.insert(pair<string, string>(ss.at(0), ss.at(1)));
				}
			}
		}
	}
	infile.close();             //�ر��ļ������� 
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x380, %rsp            # imm = 0x380
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
leaq -0x218(%rbp), %rdi
movq %rdi, -0x320(%rbp)
callq 0x32d0
movq -0x320(%rbp), %rdi
movq -0x8(%rbp), %rsi
movl $0x8, %edx
callq 0x3180
jmp 0x847d
leaq -0x218(%rbp), %rdi
callq 0x33e0
movb %al, -0x321(%rbp)
jmp 0x8491
movb -0x321(%rbp), %al
testb $0x1, %al
jne 0x849d
jmp 0x849f
jmp 0x84d5
leaq 0x3b75(%rip), %rdi      # 0xc01b
leaq 0x3b7f(%rip), %rsi      # 0xc02c
movl $0x139, %edx            # imm = 0x139
leaq 0x3b82(%rip), %rcx      # 0xc03b
callq 0x3190
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x220(%rbp)
movl %eax, -0x224(%rbp)
jmp 0x87c3
leaq -0x248(%rbp), %rdi
callq 0x3330
leaq -0x260(%rbp), %rdi
callq 0x8ac0
movb $0x0, -0x261(%rbp)
leaq -0x218(%rbp), %rdi
leaq -0x248(%rbp), %rsi
callq 0x3090
movq %rax, -0x330(%rbp)
jmp 0x8510
movq -0x330(%rbp), %rdi
movq (%rdi), %rax
movq -0x18(%rax), %rax
addq %rax, %rdi
callq 0x3300
movb %al, -0x331(%rbp)
jmp 0x852e
movb -0x331(%rbp), %al
testb $0x1, %al
jne 0x853d
jmp 0x8770
xorl %eax, %eax
movl %eax, %esi
leaq -0x248(%rbp), %rdi
callq 0x3450
movq %rax, -0x340(%rbp)
jmp 0x8556
movq -0x340(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x3b, %eax
jne 0x876b
leaq -0x288(%rbp), %rdi
leaq -0x248(%rbp), %rsi
callq 0x3110
jmp 0x857e
leaq -0x2a9(%rbp), %rdi
movq %rdi, -0x348(%rbp)
callq 0x3430
movq -0x348(%rbp), %rdx
leaq 0x3aca(%rip), %rsi      # 0xc069
leaq -0x2a8(%rbp), %rdi
callq 0x8ae0
jmp 0x85ad
leaq -0x288(%rbp), %rdi
leaq -0x2a8(%rbp), %rsi
callq 0x35c0
movl %eax, -0x34c(%rbp)
leaq -0x2a8(%rbp), %rdi
callq 0x3170
leaq -0x2a9(%rbp), %rdi
callq 0x32a0
leaq -0x288(%rbp), %rdi
callq 0x3170
movl -0x34c(%rbp), %eax
cmpl $0x0, %eax
je 0x8647
movb $0x1, -0x261(%rbp)
jmp 0x8770
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x220(%rbp)
movl %eax, -0x224(%rbp)
jmp 0x87ab
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x220(%rbp)
movl %eax, -0x224(%rbp)
leaq -0x2a9(%rbp), %rdi
callq 0x32a0
leaq -0x288(%rbp), %rdi
callq 0x3170
jmp 0x87ab
leaq -0x248(%rbp), %rdi
callq 0x3140
movq %rax, %rsi
incq %rsi
leaq 0x36b9(%rip), %rdx      # 0xbd19
leaq -0x2c8(%rbp), %rdi
callq 0x3650
jmp 0x866e
leaq -0x260(%rbp), %rdi
leaq -0x2c8(%rbp), %rsi
callq 0x8d40
leaq -0x2c8(%rbp), %rdi
callq 0x8c10
leaq -0x260(%rbp), %rdi
callq 0x8d70
cmpq $0x2, %rax
jne 0x8767
movq -0x10(%rbp), %rax
movq %rax, -0x360(%rbp)
xorl %eax, %eax
movl %eax, %esi
leaq -0x260(%rbp), %rdi
callq 0x8dd0
movq %rax, -0x358(%rbp)
jmp 0x86c7
leaq -0x260(%rbp), %rdi
movl $0x1, %esi
callq 0x8dd0
movq %rax, -0x368(%rbp)
jmp 0x86e1
movq -0x368(%rbp), %rdx
movq -0x358(%rbp), %rsi
leaq -0x308(%rbp), %rdi
callq 0x8e10
jmp 0x86fd
movq -0x360(%rbp), %rdi
leaq -0x308(%rbp), %rsi
callq 0x8d90
movb %dl, -0x371(%rbp)
movq %rax, -0x370(%rbp)
jmp 0x871f
movb -0x371(%rbp), %al
movq -0x370(%rbp), %rcx
movq %rcx, -0x318(%rbp)
movb %al, -0x310(%rbp)
leaq -0x308(%rbp), %rdi
callq 0x8e70
jmp 0x8767
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x220(%rbp)
movl %eax, -0x224(%rbp)
leaq -0x308(%rbp), %rdi
callq 0x8e70
jmp 0x87ab
jmp 0x8769
jmp 0x876b
jmp 0x84f4
leaq -0x218(%rbp), %rdi
callq 0x30a0
jmp 0x877e
leaq -0x260(%rbp), %rdi
callq 0x8c10
leaq -0x248(%rbp), %rdi
callq 0x3170
leaq -0x218(%rbp), %rdi
callq 0x30b0
addq $0x380, %rsp            # imm = 0x380
popq %rbp
retq
leaq -0x260(%rbp), %rdi
callq 0x8c10
leaq -0x248(%rbp), %rdi
callq 0x3170
leaq -0x218(%rbp), %rdi
callq 0x30b0
movq -0x220(%rbp), %rdi
callq 0x3420
nopl (%rax,%rax)