// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/match/rdj-strgraph.c
// Function: gt_strgraph_redwithrc
GtUword gt_strgraph_redwithrc(GtStrgraph *strgraph, bool show_progressbar)
{
  GtStrgraphVnum vnum;
  GtStrgraphVEdgenum edgenum;
  GtUword counter = 0;
  GtUint64 progress = 0;

  gt_assert(strgraph != NULL);

  if (show_progressbar)
    gt_progressbar_start(&progress,
        (GtUint64)GT_STRGRAPH_NOFVERTICES(strgraph));

  counter = 0;
  if (show_progressbar)
    gt_progressbar_start(&(progress),
        (GtUint64)GT_STRGRAPH_NOFVERTICES(strgraph));
  for (vnum = 0; vnum < GT_STRGRAPH_NOFVERTICES(strgraph); vnum++)
  {
    if (GT_STRGRAPH_V_OUTDEG(strgraph, vnum) > 0)
    {
      for (edgenum = 0; edgenum < GT_STRGRAPH_V_NOFEDGES(strgraph, vnum);
          edgenum++)
      {
        if (!GT_STRGRAPH_EDGE_IS_REDUCED(strgraph, vnum, edgenum) &&
            GT_STRGRAPH_EDGE_DEST(strgraph, vnum, edgenum) ==
            GT_STRGRAPH_V_OTHER(vnum))
        {
          counter++;
          GT_STRGRAPH_EDGE_REDUCE(strgraph, vnum, edgenum);
          GT_STRGRAPH_V_DEC_OUTDEG(strgraph, vnum);
        }
      }
    }
    if (show_progressbar)
      progress++;
  }
  if (show_progressbar)
    gt_progressbar_stop();

  gt_log_log("withrc-matches counter: "GT_WU"", counter);
  /* withrc matches shoud be found twice, check number is even */
  gt_assert((counter & 1) == 0);
#ifndef NDEBUG
  gt_strgraph_check_outdegs(strgraph);
#endif
  return (counter >> 1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq $0x0, 0x18(%rsp)
testq %rdi, %rdi
je 0x1d1512
movl %esi, %ebp
movq %rdi, %rbx
testb %bpl, %bpl
movl %esi, 0x4(%rsp)
je 0x1d107f
movq 0x80(%rbx), %rsi
leaq 0x18(%rsp), %r14
movq %r14, %rdi
callq 0x10ba28
movq 0x80(%rbx), %rsi
movq %r14, %rdi
movl 0x4(%rsp), %ebp
callq 0x10ba28
cmpq $0x0, 0x80(%rbx)
je 0x1d1485
movq $0x0, 0x8(%rsp)
xorl %r12d, %r12d
movq 0x70(%rbx), %rax
testq %rax, %rax
je 0x1d150d
cmpq %r12, 0x8(%rax)
jbe 0x1d150d
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d150d
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
testq %rax, %rax
je 0x1d1469
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14d6
leaq 0x1(%r12), %r13
leaq -0x1(%r12), %rcx
testb $0x1, %r12b
cmoveq %r13, %rcx
movq %rcx, 0x30(%rsp)
xorl %r14d, %r14d
movq %r13, 0x10(%rsp)
movq %r12, 0x20(%rsp)
cmpq %r13, 0x8(%rax)
jbe 0x1d14d6
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14d6
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r13, %rsi
callq 0x2f37dc
movq %rax, %r15
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14d1
cmpq %r12, 0x8(%rax)
jbe 0x1d14d1
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14d1
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
subq %rax, %r15
cmpq %r15, %r14
jae 0x1d1465
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14e0
cmpq %r12, 0x8(%rax)
jbe 0x1d14e0
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14e0
movq 0x88(%rbx), %r15
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
testq %r15, %r15
je 0x1d14db
addq %r14, %rax
cmpq %rax, 0x8(%r15)
jbe 0x1d14db
movl 0x10(%r15), %edx
cmpq $0x41, %rdx
jae 0x1d14db
movq (%r15), %rdi
imulq %rdx, %rax
movq %rax, %rsi
callq 0x2f37dc
movq %rax, %r15
movq 0x90(%rbx), %rdi
callq 0x2f09dd
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl %eax, %ecx
shll %cl, %edx
notl %edx
addl %edx, %edx
movslq %edx, %rax
andq %r15, %rax
shrq %rax
cmpq 0x90(%rbx), %rax
je 0x1d1453
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14e5
cmpq %r12, 0x8(%rax)
jbe 0x1d14e5
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14e5
movq 0x88(%rbx), %r15
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
testq %r15, %r15
je 0x1d14ea
addq %r14, %rax
cmpq %rax, 0x8(%r15)
jbe 0x1d14ea
movl 0x10(%r15), %edx
cmpq $0x41, %rdx
jae 0x1d14ea
movq (%r15), %rdi
imulq %rdx, %rax
movq %rax, %rsi
callq 0x2f37dc
movq %rax, %r15
movq 0x80(%rbx), %rdi
callq 0x2f09dd
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movl %eax, %ecx
shll %cl, %ebp
notl %ebp
movq 0x90(%rbx), %rdi
callq 0x2f09dd
leal 0x1(%rax), %ecx
shll %cl, %ebp
movslq %ebp, %r13
andq %r15, %r13
movq 0x90(%rbx), %rdi
callq 0x2f09dd
leal 0x1(%rax), %ecx
shrq %cl, %r13
cmpq 0x30(%rsp), %r13
jne 0x1d144e
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14f4
cmpq %r12, 0x8(%rax)
jbe 0x1d14f4
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14f4
movq 0x88(%rbx), %rbp
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
movq %rax, %r15
movq 0x90(%rbx), %rdi
callq 0x2f09dd
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
movl %eax, %ecx
shll %cl, %r13d
movq 0x60(%rbx), %rax
testq %rax, %rax
je 0x1d14ef
cmpq %r12, 0x8(%rax)
jbe 0x1d14ef
movl 0x10(%rax), %edx
cmpq $0x41, %rdx
jae 0x1d14ef
movq %rbp, 0x28(%rsp)
movq 0x88(%rbx), %rbp
movq (%rax), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
testq %rbp, %rbp
je 0x1d1503
addq %r14, %rax
cmpq %rax, 0x8(%rbp)
jbe 0x1d1503
movl 0x10(%rbp), %edx
cmpq $0x41, %rdx
jae 0x1d1503
movq (%rbp), %rdi
imulq %rdx, %rax
movq %rax, %rsi
callq 0x2f37dc
movq 0x28(%rsp), %r12
testq %r12, %r12
je 0x1d14f9
addq %r14, %r15
cmpq %r15, 0x8(%r12)
jbe 0x1d14f9
movl 0x10(%r12), %edx
cmpq $0x41, %rdx
jae 0x1d14f9
notl %r13d
addl %r13d, %r13d
notl %r13d
movslq %r13d, %rcx
andq %rcx, %rax
movq 0x90(%rbx), %rcx
leaq (%rax,%rcx,2), %rcx
movq (%r12), %rdi
imulq %rdx, %r15
movq %r15, %rsi
callq 0x2f388c
movq 0x70(%rbx), %r15
testq %r15, %r15
movq 0x20(%rsp), %r12
je 0x1d14fe
cmpq %r12, 0x8(%r15)
jbe 0x1d14fe
movl 0x10(%r15), %edx
cmpq $0x41, %rdx
jae 0x1d14fe
movq (%r15), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
callq 0x2f37dc
cmpq %r12, 0x8(%r15)
jbe 0x1d1508
movl 0x10(%r15), %edx
cmpq $0x41, %rdx
jae 0x1d1508
incq 0x8(%rsp)
decq %rax
movq (%r15), %rdi
movq %rdx, %rsi
imulq %r12, %rsi
movq %rax, %rcx
callq 0x2f388c
movq 0x10(%rsp), %r13
incq %r14
movq 0x60(%rbx), %rax
testq %rax, %rax
jne 0x1d1106
jmp 0x1d14d6
movl 0x4(%rsp), %ebp
testb %bpl, %bpl
je 0x1d1473
incq 0x18(%rsp)
incq %r12
cmpq 0x80(%rbx), %r12
jb 0x1d1099
jmp 0x1d148e
movq $0x0, 0x8(%rsp)
testb %bpl, %bpl
je 0x1d1498
callq 0x10bf8a
leaq 0x1de3cb(%rip), %rdi    # 0x3af86a
movq 0x8(%rsp), %r14
movq %r14, %rsi
xorl %eax, %eax
callq 0x103d72
testb $0x1, %r14b
jne 0x1d1517
movq %rbx, %rdi
callq 0x1d0e7b
shrq %r14
movq %r14, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x6db44
callq 0x6db7d
callq 0x6dad2
callq 0x6db0b
callq 0x6da99
callq 0x6da60
callq 0x6d9ee
callq 0x6da27
callq 0x6d97c
callq 0x6d943
callq 0x6d9b5
callq 0x6d90a
callq 0x6dbb6
callq 0x6dc28
callq 0x6dbef