// File: /workspace/github_c_makefile_star2_O1/mishun[P]plantri/fullgen.c
// Function: put_in_liste
void put_in_liste(int sechsecke, SEQUENZ sq, FLAECHENTYP *code, int codesize )
{

ITEMLISTE *item;
SEQUENZLISTE *anfang;
SEQUENZLISTE **puffer;
int i,j, s_eintrag;

/*schreibesequenz(sq);*/
/*schreibelistitems();*/

anfang=mapliste.sechser[sechsecke];
mapliste.total_maps++;
for (i=0; i<sq.laenge; i++)
  { s_eintrag=sq.sequenz[i];
    if (anfang->number_next <= s_eintrag)
      { puffer=anfang->next_level;
	anfang->next_level=(SEQUENZLISTE **)malloc((s_eintrag+1)*sizeof(SEQUENZLISTE *));
	if (anfang->next_level==NULL) { fprintf(stderr,"Can not get more memory"); exit(13); }
	for (j=0; j< anfang->number_next; j++) anfang->next_level[j]=puffer[j];
	for (   ; j <= s_eintrag; j++) anfang->next_level[j]=nil;
	anfang->number_next=s_eintrag+1;
	free(puffer);
      }
    if (anfang->next_level[s_eintrag]==nil)
      {	anfang->next_level[s_eintrag]=(SEQUENZLISTE *)malloc(sizeof(SEQUENZLISTE));
	if (anfang->next_level[s_eintrag]==NULL) { fprintf(stderr,"Can not get more memory"); exit(14); }
	anfang=anfang->next_level[s_eintrag];
	anfang->next_level=nil; anfang->number_next=0;
	anfang->items=anfang->last_item=nil;
      }
    else anfang=anfang->next_level[s_eintrag];
  } /* ende for */

/* jetzt muesste anfang passend stehen zum Eintragen des Codes */

if (anfang->items==nil) item=anfang->items=anfang->last_item=itemalloc(); 
   else { item=anfang->last_item->next_item=itemalloc(); 
	  anfang->last_item=item; }
item->next_item=nil;
for (j=0; j<codesize; j++) item->code[j]=code[j];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movslq %edi, %rax
leaq 0x1a6ce(%rip), %rcx     # 0x1fb50
movq 0x8(%rcx,%rax,8), %rbp
incl 0x1a6c3(%rip)           # 0x1fb50
movl %edx, 0xc(%rsp)
movslq 0x50(%rsp), %r15
testq %r15, %r15
movq %rsi, 0x10(%rsp)
jle 0x5575
xorl %r13d, %r13d
leaq 0x50(%rsp), %rax
movslq 0x4(%rax,%r13,4), %r12
movl 0x8(%rbp), %ebx
cmpl %r12d, %ebx
jg 0x5521
movq (%rbp), %r14
leaq 0x8(,%r12,8), %rdi
callq 0x10e0
movq %rax, (%rbp)
testq %rax, %rax
je 0x55d7
xorl %eax, %eax
testl %ebx, %ebx
jle 0x54f1
movq (%r14,%rax,8), %rcx
movq (%rbp), %rdx
movq %rcx, (%rdx,%rax,8)
incq %rax
cmpq %rax, %rbx
jne 0x54dd
cmpl %r12d, %eax
jg 0x5511
movl %eax, %eax
leal 0x1(%r12), %ecx
movq (%rbp), %rdx
movq $0x0, (%rdx,%rax,8)
incq %rax
cmpq %rax, %rcx
jne 0x54fd
leaq 0x1(%r12), %rax
movl %eax, 0x8(%rbp)
movq %r14, %rdi
callq 0x1030
movq (%rbp), %rbx
movq (%rbx,%r12,8), %r14
testq %r14, %r14
jne 0x5564
movl $0x20, %edi
callq 0x10e0
movq %rax, (%rbx,%r12,8)
movq (%rbp), %rax
movq (%rax,%r12,8), %r14
testq %r14, %r14
je 0x55dc
movq $0x0, (%r14)
movl $0x0, 0x8(%r14)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%r14)
incq %r13
movq %r14, %rbp
cmpq %r15, %r13
jne 0x54a7
jmp 0x5578
movq %rbp, %r14
movq 0x10(%r14), %rbx
callq 0x541e
leaq 0x18(%r14), %rcx
testq %rbx, %rbx
je 0x558f
movq (%rcx), %rdx
jmp 0x5599
addq $0x10, %r14
movq %rcx, %rdx
movq %r14, %rcx
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
movq %rax, (%rdx)
movq %rax, (%rcx)
movq $0x0, (%rax)
testl %esi, %esi
jle 0x55c8
movl %esi, %ecx
xorl %edx, %edx
movb (%rdi,%rdx), %sil
movb %sil, 0x8(%rax,%rdx)
incq %rdx
cmpq %rdx, %rcx
jne 0x55b7
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x1605
callq 0x162a