// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/rdj-spmlist.c
// Function: gt_spmlist_parse
int gt_spmlist_parse(const char* filename, GtUword min_length,
    GtSpmproc processoverlap, void *data, GtError *err)
{
  int c, retval = 0;
  FILE *file;
  GtFile *infp;

  file = gt_fa_fopen(filename, "rb", err);
  if (file == NULL)
    return -1;
  infp = gt_file_new_from_fileptr(file);
  if (infp == NULL)
    return -1;

  c = gt_file_xfgetc(infp);
  switch (c)
  {
    case EOF:
      gt_error_set(err, "%s: file is empty", filename);
      retval = -1;
      break;
    case GT_SPMLIST_BIN32:
      gt_log_log("Spm file %s format: readjoiner-bin32", filename);
      retval = gt_spmlist_parse_bin32(file, min_length, processoverlap, data,
          err);
      break;
    case GT_SPMLIST_BIN64:
      gt_log_log("Spm file %s format: readjoiner-bin64", filename);
      retval = gt_spmlist_parse_bin64(file, min_length, processoverlap, data,
          err);
      break;
    default:
      gt_file_unget_char(infp, c);
      gt_log_log("Spm file %s format: readjoiner-text", filename);
      retval = gt_spmlist_parse_ascii(infp, min_length, processoverlap, data,
          err);
  }
  gt_file_delete(infp);
  return retval;
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
movq %rsi, 0x40(%rsp)
movq %rdx, 0x38(%rsp)
movq %rcx, 0x30(%rsp)
movq %r8, 0x28(%rsp)
movl $0x0, 0x20(%rsp)
movq 0x48(%rsp), %rdi
movq 0x28(%rsp), %r8
leaq 0x2ec19f(%rip), %rsi    # 0x577ee5
leaq 0x2f5733(%rip), %rdx    # 0x581480
movl $0x102, %ecx            # imm = 0x102
callq 0xd8df0
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
jne 0x28bd71
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
jmp 0x28beb6
movq 0x18(%rsp), %rdi
callq 0xdda20
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x28bd95
movl $0xffffffff, 0x54(%rsp) # imm = 0xFFFFFFFF
jmp 0x28beb6
movq 0x10(%rsp), %rdi
callq 0xddb10
movl %eax, 0x24(%rsp)
movl 0x24(%rsp), %eax
movl %eax, 0xc(%rsp)
subl $-0x1, %eax
je 0x28bdcb
jmp 0x28bdb2
movl 0xc(%rsp), %eax
subl $0x2, %eax
je 0x28bdf0
jmp 0x28bdbd
movl 0xc(%rsp), %eax
subl $0x3, %eax
je 0x28be27
jmp 0x28be5e
movq 0x28(%rsp), %rdi
movq 0x48(%rsp), %rdx
leaq 0x2f575a(%rip), %rsi    # 0x581536
movb $0x0, %al
callq 0xd88c0
movl $0xffffffff, 0x20(%rsp) # imm = 0xFFFFFFFF
jmp 0x28bea4
movq 0x48(%rsp), %rsi
leaq 0x2f574c(%rip), %rdi    # 0x581548
movb $0x0, %al
callq 0xe7740
movq 0x18(%rsp), %rdi
movq 0x40(%rsp), %rsi
movq 0x38(%rsp), %rdx
movq 0x30(%rsp), %rcx
movq 0x28(%rsp), %r8
callq 0x28bec0
movl %eax, 0x20(%rsp)
jmp 0x28bea4
movq 0x48(%rsp), %rsi
leaq 0x2f573a(%rip), %rdi    # 0x58156d
movb $0x0, %al
callq 0xe7740
movq 0x18(%rsp), %rdi
movq 0x40(%rsp), %rsi
movq 0x38(%rsp), %rdx
movq 0x30(%rsp), %rcx
movq 0x28(%rsp), %r8
callq 0x28c040
movl %eax, 0x20(%rsp)
jmp 0x28bea4
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %eax
movsbl %al, %esi
callq 0xddc10
movq 0x48(%rsp), %rsi
leaq 0x2f5717(%rip), %rdi    # 0x581592
movb $0x0, %al
callq 0xe7740
movq 0x10(%rsp), %rdi
movq 0x40(%rsp), %rsi
movq 0x38(%rsp), %rdx
movq 0x30(%rsp), %rcx
movq 0x28(%rsp), %r8
callq 0x28c1c0
movl %eax, 0x20(%rsp)
movq 0x10(%rsp), %rdi
callq 0xde430
movl 0x20(%rsp), %eax
movl %eax, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nop