// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/match/sfx-shortreadsort.c
// Function: gt_shortreadsort_resize
static void gt_shortreadsort_resize(GtShortreadsortworkinfo *srsw,
                                    bool firstcodes,
                                    GtUword bucketsize,
                                    GtUword maxremain)
{
  gt_assert(!firstcodes || !srsw->withmediumsizelcps);
  gt_assert(bucketsize <= (GtUword) UINT32_MAX);
  if (srsw->currentbucketsize < bucketsize)
  {
    srsw->shortreadsorttable = gt_realloc(srsw->shortreadsorttable,
                                          sizeof (*srsw->shortreadsorttable) *
                                          bucketsize);
  }
  if (firstcodes && srsw->currentbucketsize < bucketsize)
  {
    srsw->seqnum_relpos_bucket
      = gt_realloc(srsw->seqnum_relpos_bucket,
                   sizeof (*srsw->seqnum_relpos_bucket) * bucketsize);
  }
  if ((firstcodes || srsw->withmediumsizelcps) &&
      srsw->currentbucketsize < bucketsize)
  {
    srsw->mediumsizelcpvalues
      = gt_realloc(srsw->mediumsizelcpvalues,
                   sizeof (*srsw->mediumsizelcpvalues) * bucketsize);
    srsw->mediumsizelcpvalues[0] = 0; /* since it is not set otherwise */
  }
  srsw->tbereservoir.nextfreeGtTwobitencoding = 0;
  if (srsw->currentbucketsize < bucketsize)
  {
    srsw->tbereservoir.allocatedGtTwobitencoding
      = gt_shortreadsort_encoding_size(bucketsize,maxremain);
    srsw->tbereservoir.spaceGtTwobitencoding
      = gt_realloc(srsw->tbereservoir.spaceGtTwobitencoding,
                   sizeof (GtTwobitencoding) *
                   srsw->tbereservoir.allocatedGtTwobitencoding);
    srsw->currentbucketsize = bucketsize;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %r15
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
testl %esi, %esi
je 0x1a7902
cmpb $0x1, 0x52(%r14)
je 0x1a7a31
movq %rbx, %rax
shrq $0x20, %rax
jne 0x1a7a07
cmpq %rbx, 0x40(%r14)
jae 0x1a7931
movq (%r14), %rdi
movq %rbx, %rsi
shlq $0x4, %rsi
leaq 0x1b2ada(%rip), %rdx    # 0x35a400
pushq $0x69
popq %rcx
callq 0x93472
movq %rax, (%r14)
testb %bpl, %bpl
je 0x1a795d
cmpq %rbx, 0x40(%r14)
jae 0x1a7964
movq 0x18(%r14), %rdi
leaq (,%rbx,8), %rsi
leaq 0x1b2ab1(%rip), %rdx    # 0x35a400
pushq $0x6f
popq %rcx
callq 0x93472
movq %rax, 0x18(%r14)
jmp 0x1a7964
cmpb $0x1, 0x52(%r14)
jne 0x1a7989
cmpq %rbx, 0x40(%r14)
jae 0x1a7989
movq 0x10(%r14), %rdi
leaq (%rbx,%rbx), %rsi
leaq 0x1b2a87(%rip), %rdx    # 0x35a400
pushq $0x76
popq %rcx
callq 0x93472
movq %rax, 0x10(%r14)
andw $0x0, (%rax)
andq $0x0, 0x30(%r14)
cmpq %rbx, 0x40(%r14)
jae 0x1a79fc
cvtsi2sd %rbx, %xmm1
movsd 0x13e887(%rip), %xmm0   # 0x2e6228
cmpq $0x41, %r15
jb 0x1a79b4
shrq $0x6, %r15
cvtsi2sd %r15, %xmm2
addsd %xmm2, %xmm0
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %rax
movq %rax, %rcx
subsd 0x140358(%rip), %xmm0   # 0x2e7d20
sarq $0x3f, %rcx
cvttsd2si %xmm0, %rsi
andq %rcx, %rsi
orq %rax, %rsi
movq %rsi, 0x28(%r14)
movq 0x20(%r14), %rdi
shlq $0x3, %rsi
leaq 0x1b2a16(%rip), %rdx    # 0x35a400
movl $0x81, %ecx
callq 0x93472
movq %rax, 0x20(%r14)
movq %rbx, 0x40(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x29055a(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x13d5fb(%rip), %rsi    # 0x2e5013
leaq 0x1b2ae7(%rip), %rdx    # 0x35a506
leaq 0x1b2ac8(%rip), %rcx    # 0x35a4ee
leaq 0x1b29d3(%rip), %r8     # 0x35a400
pushq $0x64
jmp 0x1a7a59
movq 0x290530(%rip), %rax    # 0x437f68
movq (%rax), %rdi
leaq 0x13d5d1(%rip), %rsi    # 0x2e5013
leaq 0x1b2a7c(%rip), %rdx    # 0x35a4c5
leaq 0x1b2a9e(%rip), %rcx    # 0x35a4ee
leaq 0x1b29a9(%rip), %r8     # 0x35a400
pushq $0x63
popq %r9
xorl %eax, %eax
callq 0x17a50
callq 0x17390