// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/extended/anno_db_gfflike.c
// Function: anno_db_gfflike_build
GtFeatureIndex* anno_db_gfflike_build(GtAnnoDBSchema *schema, GtRDB *db,
                                      GtError *err)
{
  int had_err = 0;
  GtFeatureIndex *fi = NULL;
  GtFeatureIndexGFFlike *fis;
  GtAnnoDBGFFlike *adg;
  ObserverCallbackInfo *oci;
  gt_assert(schema && db);
  gt_error_check(err);

  adg = anno_db_gfflike_cast(schema);
  had_err = gt_rdb_accept(db, adg->visitor, err);

  if (!had_err) {
    fi = gt_feature_index_create(feature_index_gfflike_class());
    fis = feature_index_gfflike_cast(fi);
    fis->obs = gt_feature_node_observer_new();
    fis->obs->data = oci = gt_calloc(1, sizeof (ObserverCallbackInfo));
    fis->node_to_parent_array = gt_hashmap_new(GT_HASH_DIRECT, NULL,
                                               (GtFree) gt_array_delete);
    fis->cache_node2id = node_ul_gt_hashmap_new();
    fis->cache_id2node = ul_node_gt_hashmap_new();
    fis->string_caches = gt_hashmap_new(GT_HASH_DIRECT,
                                        NULL,
                                        (GtFree) gt_hashmap_delete);
    fis->seqid_cache = gt_hashmap_new(GT_HASH_STRING, NULL,
                                      (GtFree) gt_str_delete);
    fis->ref_nodes   = gt_hashmap_new(GT_HASH_DIRECT, (GtFree) delete_ref_node,
                                      NULL);
    fis->source_cache = gt_hashmap_new(GT_HASH_STRING, NULL,
                                       (GtFree) gt_str_delete);
    fis->dblock = gt_mutex_new();

    /* set up callbacks */
    oci->fis = fis;
    fis->changed = gt_hashmap_new(GT_HASH_DIRECT, NULL, NULL);
    fis->deleted = gt_hashmap_new(GT_HASH_DIRECT, NULL, NULL);
    fis->added = gt_hashmap_new(GT_HASH_DIRECT, NULL, NULL);
    oci->had_err = 0;
    oci->err = err;
    fis->obs->deleted = NULL;
    fis->obs->score_changed = node_score_changed_callback;
    fis->obs->strand_changed = node_strand_changed_callback;
    fis->obs->phase_changed = node_phase_changed_callback;
    fis->obs->attribute_changed = node_attribute_change_callback;
    fis->obs->attribute_deleted = node_attribute_delete_callback;
    fis->obs->child_added = node_child_add_callback;
    fis->db = gt_rdb_ref(db);

    if (prepstmt_init(fis, err)) {
      gt_feature_index_delete(fi);
      fi = NULL;
    }
  }
  return fi;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movq %rdx, 0x30(%rsp)
movl $0x0, 0x2c(%rsp)
movq $0x0, 0x20(%rsp)
cmpq $0x0, 0x40(%rsp)
je 0x12f844
cmpq $0x0, 0x38(%rsp)
jne 0x12f87c
movq 0x50c755(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x3e67be(%rip), %rsi    # 0x516013
leaq 0x417edb(%rip), %rdx    # 0x547737
leaq 0x417ee1(%rip), %rcx    # 0x547744
leaq 0x417be4(%rip), %r8     # 0x54744e
movl $0x794, %r9d            # imm = 0x794
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x12f87e
jmp 0x12f880
cmpq $0x0, 0x30(%rsp)
je 0x12f8d0
movq 0x30(%rsp), %rdi
callq 0xd8a60
testb $0x1, %al
jne 0x12f898
jmp 0x12f8d0
movq 0x50c701(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x3e676a(%rip), %rsi    # 0x516013
leaq 0x3e690f(%rip), %rdx    # 0x5161bf
leaq 0x417e8d(%rip), %rcx    # 0x547744
leaq 0x417b90(%rip), %r8     # 0x54744e
movl $0x795, %r9d            # imm = 0x795
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x12f8d2
callq 0x12dac0
movq %rax, %rdi
movq 0x40(%rsp), %rsi
callq 0x132ad0
movq %rax, 0x10(%rsp)
movq 0x38(%rsp), %rdi
movq 0x10(%rsp), %rax
movq 0x18(%rax), %rsi
movq 0x30(%rsp), %rdx
callq 0x1c3e90
movl %eax, 0x2c(%rsp)
cmpl $0x0, 0x2c(%rsp)
jne 0x12fba6
callq 0x12dc70
movq %rax, %rdi
callq 0x169310
movq %rax, 0x20(%rsp)
callq 0x12dc70
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x16a0d0
movq %rax, 0x18(%rsp)
callq 0x170f90
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x160(%rax)
movl $0x1, %edi
movl $0x18, %esi
leaq 0x417af0(%rip), %rdx    # 0x54744e
movl $0x79e, %ecx            # imm = 0x79E
callq 0xe83c0
movq %rax, %rcx
movq %rcx, 0x8(%rsp)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
movq %rcx, 0x60(%rax)
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %esi
leaq -0xada0d(%rip), %rdx    # 0x81f80
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x10(%rax)
callq 0x12fbb0
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x50(%rax)
callq 0x12fbf0
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x58(%rax)
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %esi
leaq -0x4e25d(%rip), %rdx    # 0xe1770
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x28(%rax)
movl $0x1, %edi
xorl %eax, %eax
movl %eax, %esi
leaq -0x1048e(%rip), %rdx    # 0x11f560
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x18(%rax)
xorl %edi, %edi
leaq 0x228(%rip), %rsi       # 0x12fc30
xorl %eax, %eax
movl %eax, %edx
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x30(%rax)
movl $0x1, %edi
xorl %eax, %eax
movl %eax, %esi
leaq -0x104cd(%rip), %rdx    # 0x11f560
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x20(%rax)
callq 0x1210d0
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x170(%rax)
movq 0x18(%rsp), %rcx
movq 0x8(%rsp), %rax
movq %rcx, 0x8(%rax)
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x48(%rax)
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x40(%rax)
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0xe0c40
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x38(%rax)
movq 0x8(%rsp), %rax
movl $0x0, 0x10(%rax)
movq 0x30(%rsp), %rcx
movq 0x8(%rsp), %rax
movq %rcx, (%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
movq $0x0, 0x58(%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x162(%rip), %rcx       # 0x12fc50
movq %rcx, (%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x1ec(%rip), %rcx       # 0x12fcf0
movq %rcx, 0x10(%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x235(%rip), %rcx       # 0x12fd50
movq %rcx, 0x8(%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x27e(%rip), %rcx       # 0x12fdb0
movq %rcx, 0x28(%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x317(%rip), %rcx       # 0x12fe60
movq %rcx, 0x30(%rax)
movq 0x18(%rsp), %rax
movq 0x160(%rax), %rax
leaq 0x3a0(%rip), %rcx       # 0x12ff00
movq %rcx, 0x50(%rax)
movq 0x38(%rsp), %rdi
callq 0x1c3ce0
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x168(%rax)
movq 0x18(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x12fff0
cmpl $0x0, %eax
je 0x12fba4
movq 0x20(%rsp), %rdi
callq 0x169460
movq $0x0, 0x20(%rsp)
jmp 0x12fba6
movq 0x20(%rsp), %rax
addq $0x48, %rsp
retq