// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/annotationsketch/track.c
// Function: gt_track_get_height
int gt_track_get_height(const GtTrack *track, double *height,
                        const GtStyle *sty, GtError *err)
{
  GtUword i;
  double track_height = 0,
         bheight = TEXT_SIZE_DEFAULT,
         theight = TEXT_SIZE_DEFAULT,
         tcaptionspace = CAPTION_BAR_SPACE_DEFAULT,
         bcaptionspace = CAPTION_BAR_SPACE_DEFAULT,
         tmp = TRACK_VSPACE_DEFAULT;
  bool show_track_captions = true,
       show_block_captions = true;
  gt_assert(track && sty);
  if (gt_style_get_num(sty, "format", "block_caption_font_size", &bheight,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  if (gt_style_get_num(sty, "format", "track_caption_font_size", &theight,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  if (gt_style_get_num(sty, "format", "track_caption_space", &tcaptionspace,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  if (gt_style_get_num(sty, "format", "block_caption_space", &bcaptionspace,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  if (gt_style_get_num(sty, "format", "block_caption_font_size", &bheight,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  if (gt_style_get_num(sty, "format", "track_caption_font_size", &theight,
                       NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  for (i = 0; i < gt_array_size(track->lines); i++)
  {
    double itmp = BAR_VSPACE_DEFAULT,
           tmp = 0.0;
    int rval;
    GtLine *line;

    line = *(GtLine**) gt_array_get(track->lines, i);
    rval = gt_line_get_height(line, &tmp, sty, err);
    if (rval < 0)
      return -1;
    track_height += tmp;
    show_block_captions = true;

    if (gt_style_get_bool(sty,
                          "format","show_block_captions",
                          &show_block_captions,
                          NULL, err) == GT_STYLE_QUERY_ERROR) {
      return -1;
    }

    /* add caption space if necessary */
    if (gt_line_has_captions(line) && show_block_captions)
    {
      track_height += bheight + bcaptionspace;
    }
    /* add vertical spacer */
    if (gt_style_get_num(sty,
                         "format", "bar_vspace",
                         &itmp, NULL, err) == GT_STYLE_QUERY_ERROR) {
      return -1;
    }
    track_height += itmp;
  }

  /* determine display of track captions */
  if (gt_style_get_bool(sty,
                        "format","show_track_captions",
                        &show_track_captions,
                        NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }

  /* add track caption height and spacer */
  if (show_track_captions)
    track_height += theight + tcaptionspace;
  if (gt_style_get_num(sty,
                       "format", "track_vspace",
                       &tmp, NULL, err) == GT_STYLE_QUERY_ERROR) {
    return -1;
  }
  track_height += tmp;

  *height = track_height;
  return 0;
}

// Assembly:
subq $0x98, %rsp
movq %rdi, 0x88(%rsp)
movq %rsi, 0x80(%rsp)
movq %rdx, 0x78(%rsp)
movq %rcx, 0x70(%rsp)
xorps %xmm0, %xmm0
movsd %xmm0, 0x60(%rsp)
movsd 0x11b236(%rip), %xmm0   # 0x168338
movsd %xmm0, 0x58(%rsp)
movsd 0x11b228(%rip), %xmm0   # 0x168338
movsd %xmm0, 0x50(%rsp)
movsd 0x11ba02(%rip), %xmm0   # 0x168b20
movsd %xmm0, 0x48(%rsp)
movsd 0x11b9f4(%rip), %xmm0   # 0x168b20
movsd %xmm0, 0x40(%rsp)
movsd 0x11b9de(%rip), %xmm0   # 0x168b18
movsd %xmm0, 0x38(%rsp)
movb $0x1, 0x37(%rsp)
movb $0x1, 0x36(%rsp)
cmpq $0x0, 0x88(%rsp)
je 0x4d15d
cmpq $0x0, 0x78(%rsp)
jne 0x4d195
movq 0x166e74(%rip), %rax    # 0x1b3fd8
movq (%rax), %rdi
leaq 0x110ef8(%rip), %rsi    # 0x15e066
leaq 0x11ce91(%rip), %rdx    # 0x16a006
leaq 0x11ce97(%rip), %rcx    # 0x16a013
leaq 0x11cdb6(%rip), %r8     # 0x169f39
movl $0xbc, %r9d
movb $0x0, %al
callq 0xb890
callq 0xb2e0
jmp 0x4d197
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110fee(%rip), %rsi    # 0x15e196
leaq 0x11cd1a(%rip), %rdx    # 0x169ec9
leaq 0x58(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d1d3
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110fb2(%rip), %rsi    # 0x15e196
leaq 0x11baf5(%rip), %rdx    # 0x168ce0
leaq 0x50(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d20f
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110f76(%rip), %rsi    # 0x15e196
leaq 0x11bad1(%rip), %rdx    # 0x168cf8
leaq 0x48(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d24b
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110f3a(%rip), %rsi    # 0x15e196
leaq 0x11cdc4(%rip), %rdx    # 0x16a027
leaq 0x40(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d287
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110efe(%rip), %rsi    # 0x15e196
leaq 0x11cc2a(%rip), %rdx    # 0x169ec9
leaq 0x58(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d2c3
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110ec2(%rip), %rsi    # 0x15e196
leaq 0x11ba05(%rip), %rdx    # 0x168ce0
leaq 0x50(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d2ff
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq $0x0, 0x68(%rsp)
movq 0x68(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x88(%rsp), %rax
movq 0x30(%rax), %rdi
callq 0x76490
movq %rax, %rcx
movq 0x8(%rsp), %rax
cmpq %rcx, %rax
jae 0x4d480
movsd 0x11a4d4(%rip), %xmm0   # 0x167810
movsd %xmm0, 0x28(%rsp)
xorps %xmm0, %xmm0
movsd %xmm0, 0x20(%rsp)
movq 0x88(%rsp), %rax
movq 0x30(%rax), %rdi
movq 0x68(%rsp), %rsi
callq 0x75c80
movq (%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq 0x78(%rsp), %rdx
movq 0x70(%rsp), %rcx
leaq 0x20(%rsp), %rsi
callq 0xb77f0
movl %eax, 0x1c(%rsp)
cmpl $0x0, 0x1c(%rsp)
jge 0x4d39d
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movsd 0x20(%rsp), %xmm0
addsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movb $0x1, 0x36(%rsp)
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110dd1(%rip), %rsi    # 0x15e196
leaq 0x11a8a6(%rip), %rdx    # 0x167c72
leaq 0x36(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x4a140
cmpl $0x2, %eax
jne 0x4d3f0
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movq 0x10(%rsp), %rdi
callq 0xb7600
testb $0x1, %al
jne 0x4d400
jmp 0x4d41f
testb $0x1, 0x36(%rsp)
je 0x4d41f
movsd 0x58(%rsp), %xmm0
addsd 0x40(%rsp), %xmm0
addsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110d66(%rip), %rsi    # 0x15e196
leaq 0x11cc04(%rip), %rdx    # 0x16a03b
leaq 0x28(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d45b
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movsd 0x28(%rsp), %xmm0
addsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movq 0x68(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x68(%rsp)
jmp 0x4d308
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110d05(%rip), %rsi    # 0x15e196
leaq 0x11b834(%rip), %rdx    # 0x168ccc
leaq 0x37(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x4a140
cmpl $0x2, %eax
jne 0x4d4bc
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
testb $0x1, 0x37(%rsp)
je 0x4d4db
movsd 0x50(%rsp), %xmm0
addsd 0x48(%rsp), %xmm0
addsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movq 0x78(%rsp), %rdi
movq 0x70(%rsp), %r9
leaq 0x110caa(%rip), %rsi    # 0x15e196
leaq 0x11b819(%rip), %rdx    # 0x168d0c
leaq 0x38(%rsp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x49af0
cmpl $0x2, %eax
jne 0x4d514
movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF
jmp 0x4d543
movsd 0x38(%rsp), %xmm0
addsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movsd 0x60(%rsp), %xmm0
movq 0x80(%rsp), %rax
movsd %xmm0, (%rax)
movl $0x0, 0x94(%rsp)
movl 0x94(%rsp), %eax
addq $0x98, %rsp
retq
nopw %cs:(%rax,%rax)