// File: /workspace/github_c_makefile_star2_O0/lucvoo[P]sparse-dev/c2xml.c
// Function: new_sym_node
static xmlNodePtr new_sym_node(struct symbol *sym, const char *name, xmlNodePtr parent)
{
	xmlNodePtr node;
	const char *ident = show_ident(sym->ident);

	assert(name != NULL);
	assert(sym != NULL);
	assert(parent != NULL);

	node = xmlNewChild(parent, NULL, BAD_CAST "symbol", NULL);

	newProp(node, "type", name);

	newIdProp(node, "id", idcount);

	if (sym->ident && ident)
		newProp(node, "ident", ident);
	newProp(node, "file", stream_name(sym->pos.stream));

	newNumProp(node, "start-line", sym->pos.line);
	newNumProp(node, "start-col", sym->pos.pos);

	if (sym->endpos.type) {
		newNumProp(node, "end-line", sym->endpos.line);
		newNumProp(node, "end-col", sym->endpos.pos);
		if (sym->pos.stream != sym->endpos.stream)
			newProp(node, "end-file", stream_name(sym->endpos.stream));
        }
	sym->aux = node;

	idcount++;

	return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x31f60
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x11bae
jmp 0x11bcd
leaq 0x5047e(%rip), %rdi     # 0x62033
leaq 0x50484(%rip), %rsi     # 0x62040
movl $0x46, %edx
leaq 0x50480(%rip), %rcx     # 0x62048
callq 0x11130
cmpq $0x0, -0x8(%rbp)
je 0x11bd6
jmp 0x11bf5
leaq 0x504ae(%rip), %rdi     # 0x6208b
leaq 0x5045c(%rip), %rsi     # 0x62040
movl $0x47, %edx
leaq 0x50458(%rip), %rcx     # 0x62048
callq 0x11130
cmpq $0x0, -0x18(%rbp)
je 0x11bfe
jmp 0x11c1d
leaq 0x50492(%rip), %rdi     # 0x62097
leaq 0x50434(%rip), %rsi     # 0x62040
movl $0x48, %edx
leaq 0x50430(%rip), %rcx     # 0x62048
callq 0x11130
movq -0x18(%rbp), %rdi
xorl %eax, %eax
movl %eax, %ecx
leaq 0x5047a(%rip), %rdx     # 0x620a6
movq %rcx, %rsi
callq 0x11070
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rdx
leaq 0x57ad2(%rip), %rsi     # 0x69719
callq 0x11df0
movq -0x20(%rbp), %rdi
movl 0x7ac82(%rip), %edx     # 0x8c8d8
leaq 0x539cd(%rip), %rsi     # 0x6562a
callq 0x11e20
movq -0x8(%rbp), %rax
cmpq $0x0, 0x18(%rax)
je 0x11c88
cmpq $0x0, -0x28(%rbp)
je 0x11c88
movq -0x20(%rbp), %rdi
movq -0x28(%rbp), %rdx
leaq 0x5042a(%rip), %rsi     # 0x620ad
callq 0x11df0
movq -0x20(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x4(%rax), %rax
shrq $0x6, %rax
andq $0x3fff, %rax           # imm = 0x3FFF
movl %eax, %edi
callq 0x31e40
movq -0x30(%rbp), %rdi
movq %rax, %rdx
leaq 0x56448(%rip), %rsi     # 0x680ff
callq 0x11df0
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x4(%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %edx
leaq 0x503d8(%rip), %rsi     # 0x620b3
callq 0x11e70
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x4(%rax), %rax
shrq $0x16, %rax
andq $0x3ff, %rax            # imm = 0x3FF
movl %eax, %edx
leaq 0x503bf(%rip), %rsi     # 0x620be
callq 0x11e70
movq -0x8(%rbp), %rax
movq 0xc(%rax), %rax
andq $0x3f, %rax
cmpl $0x0, %eax
je 0x11dc0
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0xc(%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %edx
leaq 0x50390(%rip), %rsi     # 0x620c8
callq 0x11e70
movq -0x20(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0xc(%rax), %rax
shrq $0x16, %rax
andq $0x3ff, %rax            # imm = 0x3FF
movl %eax, %edx
leaq 0x50375(%rip), %rsi     # 0x620d1
callq 0x11e70
movq -0x8(%rbp), %rax
movq 0x4(%rax), %rax
shrq $0x6, %rax
andq $0x3fff, %rax           # imm = 0x3FFF
movq -0x8(%rbp), %rcx
movq 0xc(%rcx), %rcx
shrq $0x6, %rcx
andq $0x3fff, %rcx           # imm = 0x3FFF
cmpl %ecx, %eax
je 0x11dbe
movq -0x20(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movq 0xc(%rax), %rax
shrq $0x6, %rax
andq $0x3fff, %rax           # imm = 0x3FFF
movl %eax, %edi
callq 0x31e40
movq -0x38(%rbp), %rdi
movq %rax, %rdx
leaq 0x50320(%rip), %rsi     # 0x620d9
callq 0x11df0
jmp 0x11dc0
movq -0x20(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xd0(%rax)
movl 0x7ab03(%rip), %eax     # 0x8c8d8
addl $0x1, %eax
movl %eax, 0x7aafa(%rip)     # 0x8c8d8
movq -0x20(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)