// File: /workspace/github_c_makefile_star2_O1/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 %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
callq 0x223d5
testq %r12, %r12
je 0xf20b
testq %rbx, %rbx
je 0xf22a
testq %r14, %r14
je 0xf249
movq %rax, %r15
leaq 0x3207f(%rip), %rdx     # 0x410ca
movq %r14, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
callq 0xe080
movq %rax, %r14
leaq 0x39e10(%rip), %rsi     # 0x48e71
movq %rax, %rdi
movq %r12, %rdx
callq 0xe200
movl 0x58466(%rip), %ecx     # 0x674d8
leaq 0x3208d(%rip), %rdx     # 0x41106
movq %rsp, %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
xorl %eax, %eax
callq 0xe2f0
leaq 0x35c36(%rip), %rsi     # 0x44cc8
movq %r14, %rdi
movq %r12, %rdx
callq 0xe200
cmpq $0x0, 0x18(%rbx)
setne %al
testq %r15, %r15
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0xf0c4
leaq 0x32018(%rip), %rsi     # 0x410d1
movq %r14, %rdi
movq %r15, %rdx
callq 0xe200
movl 0x4(%rbx), %edi
shrl $0x6, %edi
andl $0x3fff, %edi           # imm = 0x3FFF
callq 0x22334
leaq 0x38752(%rip), %rsi     # 0x4782e
movq %r14, %rdi
movq %rax, %rdx
callq 0xe200
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andl 0x8(%rbx), %ecx
leaq 0x3be32(%rip), %r15     # 0x4af28
movq %rsp, %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xe2f0
leaq 0x31fc5(%rip), %rsi     # 0x410d7
movq %r14, %rdi
movq %r12, %rdx
callq 0xe200
movl 0x4(%rbx), %ecx
shrl $0x16, %ecx
movq %rsp, %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xe2f0
leaq 0x31fa3(%rip), %rsi     # 0x410e2
movq %r14, %rdi
movq %r12, %rdx
callq 0xe200
movq 0xc(%rbx), %rcx
testb $0x3f, %cl
je 0xf1ec
shrq $0x20, %rcx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
leaq 0x3bdc0(%rip), %r15     # 0x4af28
movq %rsp, %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xe2f0
leaq 0x31f68(%rip), %rsi     # 0x410ec
movq %r14, %rdi
movq %r12, %rdx
callq 0xe200
movl 0xc(%rbx), %ecx
shrl $0x16, %ecx
movq %rsp, %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0xe2f0
leaq 0x31f44(%rip), %rsi     # 0x410f5
movq %r14, %rdi
movq %r12, %rdx
callq 0xe200
movl 0x4(%rbx), %eax
movl 0xc(%rbx), %edi
shrl $0x6, %eax
movl $0x3fff, %ecx           # imm = 0x3FFF
andl %ecx, %eax
shrl $0x6, %edi
andl %ecx, %edi
cmpl %edi, %eax
je 0xf1ec
callq 0x22334
leaq 0x31f1c(%rip), %rsi     # 0x410fd
movq %r14, %rdi
movq %rax, %rdx
callq 0xe200
movq %r14, 0xd0(%rbx)
incl 0x582df(%rip)           # 0x674d8
movq %r14, %rax
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x31e45(%rip), %rdi     # 0x41057
leaq 0x31e4b(%rip), %rsi     # 0x41064
leaq 0x31e4c(%rip), %rcx     # 0x4106c
movl $0x46, %edx
callq 0xe130
leaq 0x31e7e(%rip), %rdi     # 0x410af
leaq 0x31e2c(%rip), %rsi     # 0x41064
leaq 0x31e2d(%rip), %rcx     # 0x4106c
movl $0x47, %edx
callq 0xe130
leaq 0x31e6b(%rip), %rdi     # 0x410bb
leaq 0x31e0d(%rip), %rsi     # 0x41064
leaq 0x31e0e(%rip), %rcx     # 0x4106c
movl $0x48, %edx
callq 0xe130