// File: /workspace/github_c_makefile_star2_O2/ComplexNetworks-DCC-FCUP[P]gtrieScanner/GTrie.cpp
// Function: GTrieNode::showAsText(_IO_FILE*)
void GTrieNode::showAsText(FILE *f) {
  int i;
  for (i=0; i<depth; i++) fprintf(f,"   ");
  fprintf(f,"[");
  for (i=0; i<depth; i++) 
    fprintf(f,"%s", out[i]?"1":"0");
  fprintf(f,"][");
  for (i=0; i<depth; i++) 
    fprintf(f,"%s", in[i]?"1":"0");
  fprintf(f,"] ");

  if (cond_ok) fprintf(f,"{}");
  else {    
    list< list<iPair> >:: iterator jj;
    list<iPair>:: iterator kk;
    for (jj=cond.begin(); jj!=cond.end(); jj++) {
      fputc('|', f);
      for (kk=(*jj).begin(); kk!=(*jj).end(); kk++) {
	if (kk!=(*jj).begin()) fputc(' ', f);
	fprintf(f,"%d<%d", kk->first, kk->second);
      }
      fputc('|', f);
    }
  }

  fputc('+', f);

  if (cond_this_ok) fprintf(f,"{}");
  else {
    list< list<int> >:: iterator jjj;
    list<int>:: iterator kkk;
    for (jjj=this_node_cond.begin(); jjj!=this_node_cond.end(); jjj++) {
      fputc('|', f);
      if ((*jjj).size()==0) fprintf(f,"{}");
      else {
	for (kkk=(*jjj).begin(); kkk!=(*jjj).end(); kkk++) {
	  if (kkk!=(*jjj).begin()) fputc(',', f);
	  fprintf(f,"%d", *kkk);	
	}
	fprintf(f,"<%d", depth-1);
      }
      fputc('|', f);
    }
  }
      
  fputc(' ', f);
        
  fprintf(f,"%s\n", is_graph?"isGraph":"");

  list<GTrieNode *>::iterator ii;
  for(ii=child.begin(); ii!=child.end(); ii++)
    (*ii)->showAsText(f);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, 0x8(%rsp)
xorl %ebp, %ebp
leaq 0x9574(%rip), %r15      # 0x1144b
pushq $0x3
popq %r12
pushq $0x1
popq %r13
movq 0x8(%rsp), %rax
cmpl 0x4c(%rax), %ebp
jge 0x7efe
movq %r15, %rdi
movq %r12, %rsi
movq %r13, %rdx
movq %rbx, %rcx
callq 0x2420
incl %ebp
jmp 0x7edf
pushq $0x5b
popq %rdi
movq %rbx, %rsi
callq 0x22a0
xorl %r14d, %r14d
leaq 0x8af1(%rip), %r15      # 0x10a04
leaq 0x8dae(%rip), %r12      # 0x10cc8
movq 0x8(%rsp), %r13
movslq 0x4c(%r13), %rax
cmpq %rax, %r14
jge 0x7f46
movq 0x60(%r13), %rax
cmpb $0x0, (%rax,%r14)
movq %r15, %rdi
jne 0x7f39
movq %r12, %rdi
movq %rbx, %rsi
callq 0x2240
incq %r14
jmp 0x7f1f
leaq 0x8d7d(%rip), %rdi      # 0x10cca
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x2420
xorl %r14d, %r14d
leaq 0x8a9f(%rip), %r15      # 0x10a04
leaq 0x8d5c(%rip), %r12      # 0x10cc8
movslq 0x4c(%r13), %rax
cmpq %rax, %r14
jge 0x7f93
movq 0x58(%r13), %rax
cmpb $0x0, (%rax,%r14)
movq %r15, %rdi
jne 0x7f86
movq %r12, %rdi
movq %rbx, %rsi
callq 0x2240
incq %r14
jmp 0x7f6c
leaq 0x8d33(%rip), %rdi      # 0x10ccd
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x2420
cmpb $0x1, 0x48(%r13)
jne 0x805c
leaq 0x8d16(%rip), %rdi      # 0x10cd0
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x2420
pushq $0x2b
popq %rdi
movq %rbx, %rsi
callq 0x22a0
movq 0x8(%rsp), %r14
cmpb $0x0, 0x49(%r14)
je 0x80d2
leaq 0x8ce6(%rip), %rdi      # 0x10cd0
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x2420
pushq $0x20
popq %rdi
movq %rbx, %rsi
callq 0x22a0
leaq 0x8ccf(%rip), %rax      # 0x10cd9
leaq 0x8097(%rip), %rdx      # 0x100a8
movq 0x8(%rsp), %r15
cmpb $0x0, 0x50(%r15)
cmovneq %rax, %rdx
leaq 0x9497(%rip), %rsi      # 0x114bd
movq %rbx, %rdi
xorl %eax, %eax
callq 0x2310
addq $0x30, %r15
movq %r15, %r14
movq (%r14), %r14
cmpq %r15, %r14
je 0x804d
movq 0x10(%r14), %rdi
movq %rbx, %rsi
callq 0x7eb8
jmp 0x8037
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
addq $0x18, %r13
pushq $0x7c
popq %rbp
leaq 0x8c69(%rip), %r15      # 0x10cd3
pushq $0x20
popq %r12
movq %r13, 0x10(%rsp)
movq (%r13), %r13
cmpq 0x10(%rsp), %r13
je 0x7fc8
movl %ebp, %edi
movq %rbx, %rsi
callq 0x22a0
leaq 0x10(%r13), %rbp
movq %rbp, %r14
movq (%r14), %r14
cmpq %rbp, %r14
je 0x80c3
cmpq (%rbp), %r14
je 0x80ac
movl %r12d, %edi
movq %rbx, %rsi
callq 0x22a0
movl 0x10(%r14), %edx
movl 0x14(%r14), %ecx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x2310
jmp 0x8093
pushq $0x7c
popq %rbp
movl %ebp, %edi
movq %rbx, %rsi
callq 0x22a0
jmp 0x8073
pushq $0x7c
popq %rbp
leaq 0x8ad6(%rip), %r12      # 0x10bb2
pushq $0x2c
popq %r13
movq (%r14), %r14
cmpq 0x8(%rsp), %r14
je 0x7ff8
movl %ebp, %edi
movq %rbx, %rsi
callq 0x22a0
leaq 0x10(%r14), %r15
cmpq $0x0, 0x20(%r14)
movq %r15, %rbp
je 0x814e
movq (%rbp), %rbp
cmpq %r15, %rbp
je 0x8131
cmpq (%r15), %rbp
je 0x811f
movl %r13d, %edi
movq %rbx, %rsi
callq 0x22a0
movl 0x10(%rbp), %edx
movq %rbx, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0x2310
jmp 0x8106
movq 0x8(%rsp), %rax
movl 0x4c(%rax), %edx
decl %edx
movq %rbx, %rdi
leaq 0x8b90(%rip), %rsi      # 0x10cd5
xorl %eax, %eax
callq 0x2310
jmp 0x8163
leaq 0x8b7b(%rip), %rdi      # 0x10cd0
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
callq 0x2420
pushq $0x7c
popq %rbp
movl %ebp, %edi
movq %rbx, %rsi
callq 0x22a0
jmp 0x80e0
nop