// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/extended/anno_db_gfflike.c
// Function: gt_feature_index_gfflike_save
static int gt_feature_index_gfflike_save(GtFeatureIndex *fi,
                                         GT_UNUSED GtError *err)
{
  GtFeatureIndexGFFlike *fig;
  ObserverCallbackInfo *oci;
  int had_err = 0;
  GtRDBStmt *stmt_b, *stmt_e;
  gt_assert(fi);
  fig = feature_index_gfflike_cast(fi);
  oci = (ObserverCallbackInfo*) fig->obs->data;

  gt_mutex_lock(fig->dblock);
  stmt_b = gt_rdb_prepare(fig->db, "BEGIN TRANSACTION;", 0, err);
  stmt_e = gt_rdb_prepare(fig->db, "END TRANSACTION;", 0, err);
  gt_rdb_stmt_exec(stmt_b, err);
  if (oci && fig->deleted) {
    had_err = gt_hashmap_foreach(fig->deleted,
                                 gt_feature_index_gfflike_save_del,
                                 oci, err);
  }
  gt_hashmap_reset(fig->deleted);
  gt_rdb_stmt_exec(stmt_e, err);

  gt_rdb_stmt_reset(stmt_b, err);
  gt_rdb_stmt_exec(stmt_b, err);
  if (oci && fig->added) {
    had_err = gt_hashmap_foreach(fig->added,
                                 gt_feature_index_gfflike_save_add,
                                 oci, err);
  }
  gt_hashmap_reset(fig->added);
  gt_rdb_stmt_reset(stmt_e, err);
  gt_rdb_stmt_exec(stmt_e, err);

  gt_rdb_stmt_reset(stmt_b, err);
  gt_rdb_stmt_exec(stmt_b, err);
  if (oci && fig->changed) {
    had_err = gt_hashmap_foreach(fig->changed,
                                 gt_feature_index_gfflike_save_chg,
                                 oci, err);
  }
  gt_hashmap_reset(fig->changed);
  gt_rdb_stmt_reset(stmt_e, err);
  gt_rdb_stmt_exec(stmt_e, err);

  gt_rdb_stmt_delete(stmt_e);
  gt_rdb_stmt_delete(stmt_b);
  gt_mutex_lock(fig->dblock);

  return had_err;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movl $0x0, 0x14(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x131cf6
movq 0x50a2db(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x3e4344(%rip), %rsi    # 0x516013
leaq 0x43454c(%rip), %rdx    # 0x566222
leaq 0x416a06(%rip), %rcx    # 0x5486e3
leaq 0x41576a(%rip), %r8     # 0x54744e
movl $0x4e4, %r9d            # imm = 0x4E4
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x131cf8
callq 0x12dc70
movq %rax, %rdi
movq 0x30(%rsp), %rsi
callq 0x16a0d0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq 0x160(%rax), %rax
movq 0x60(%rax), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x170(%rax), %rdi
callq 0x1211d0
movq 0x20(%rsp), %rax
movq 0x168(%rax), %rdi
movq 0x28(%rsp), %rcx
leaq 0x4169b4(%rip), %rsi    # 0x548701
xorl %eax, %eax
movl %eax, %edx
callq 0x1c4240
movq %rax, 0x8(%rsp)
movq 0x20(%rsp), %rax
movq 0x168(%rax), %rdi
movq 0x28(%rsp), %rcx
leaq 0x4169a1(%rip), %rsi    # 0x548714
xorl %eax, %eax
movl %eax, %edx
callq 0x1c4240
movq %rax, (%rsp)
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
cmpq $0x0, 0x18(%rsp)
je 0x131dc6
movq 0x20(%rsp), %rax
cmpq $0x0, 0x40(%rax)
je 0x131dc6
movq 0x20(%rsp), %rax
movq 0x40(%rax), %rdi
movq 0x18(%rsp), %rdx
movq 0x28(%rsp), %rcx
leaq 0x153(%rip), %rsi       # 0x131f10
callq 0xe11a0
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq 0x40(%rax), %rdi
callq 0xe1260
movq (%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c42f0
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
cmpq $0x0, 0x18(%rsp)
je 0x131e37
movq 0x20(%rsp), %rax
cmpq $0x0, 0x38(%rax)
je 0x131e37
movq 0x20(%rsp), %rax
movq 0x38(%rax), %rdi
movq 0x18(%rsp), %rdx
movq 0x28(%rsp), %rcx
leaq 0x1c2(%rip), %rsi       # 0x131ff0
callq 0xe11a0
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq 0x38(%rax), %rdi
callq 0xe1260
movq (%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c42f0
movq (%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c42f0
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
cmpq $0x0, 0x18(%rsp)
je 0x131eb6
movq 0x20(%rsp), %rax
cmpq $0x0, 0x48(%rax)
je 0x131eb6
movq 0x20(%rsp), %rax
movq 0x48(%rax), %rdi
movq 0x18(%rsp), %rdx
movq 0x28(%rsp), %rcx
leaq 0x1a3(%rip), %rsi       # 0x132050
callq 0xe11a0
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq 0x48(%rax), %rdi
callq 0xe1260
movq (%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c42f0
movq (%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x1c4650
movq (%rsp), %rdi
callq 0x1c46f0
movq 0x8(%rsp), %rdi
callq 0x1c46f0
movq 0x20(%rsp), %rax
movq 0x170(%rax), %rdi
callq 0x1211d0
movl 0x14(%rsp), %eax
addq $0x38, %rsp
retq
nopl (%rax)