// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/match/dbs_spaced_seeds.c
// Function: gt_spaced_seed_spec_new
GtSpacedSeedSpec *gt_spaced_seed_spec_new(GtCodetype spacedseed)
{
  uint8_t blocks_length[32] = {0}, shiftleft = 0, shiftright = 0;
  GtCodetype ss_copy, last = (GtCodetype) 1, GT_UNUSED from_blocks = 0;
  GtUword idx, block_num = 0, spec_counter = 0;
  GtSpacedSeedSpec *seed_spec;

  gt_assert(spacedseed & ((GtCodetype) 1));
  blocks_length[0] = 1;
  for (ss_copy = spacedseed >> 1; ss_copy > 0; ss_copy >>= 1)
  {
    GtCodetype current = ss_copy & (GtCodetype) 1;

    if (current != last)
    {
      block_num++;
      last = current;
    }
    gt_assert(block_num < sizeof blocks_length/sizeof blocks_length[0]);
    blocks_length[block_num]++;
  }
  block_num++;
  gt_assert(block_num % 2 == 1);
  seed_spec = gt_malloc(sizeof *seed_spec);
  seed_spec->num_specs = 1 + block_num/2;
  seed_spec->spec_tab = gt_malloc(seed_spec->num_specs *
                                  sizeof *seed_spec->spec_tab);
  gt_assert(seed_spec->spec_tab != NULL);
  last = (GtCodetype) 1;
  for (idx = 0; idx < block_num; idx++)
  {
    const uint8_t width = blocks_length[idx];
    if (last == (GtCodetype) 1)
    {
      from_blocks |= (((((GtCodetype) 1) << width) - 1) << shiftleft);
      last = 0;
      gt_assert(spec_counter < seed_spec->num_specs);
      seed_spec->spec_tab[spec_counter].extract
        = ((((GtCodetype) 1) << (2 * width)) - 1) << (2 * shiftleft);
      seed_spec->spec_tab[spec_counter++].shiftright = 2 * shiftright;
    } else
    {
      last = (GtCodetype) 1;
      shiftright += width;
    }
    shiftleft += width;
  }
  gt_assert(spec_counter == seed_spec->num_specs && from_blocks == spacedseed);
  return seed_spec;
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x70(%rsp)
leaq 0x50(%rsp), %rdi
xorl %esi, %esi
movl $0x20, %edx
callq 0x19360
movb $0x0, 0x4f(%rsp)
movb $0x0, 0x4e(%rsp)
movq $0x1, 0x38(%rsp)
movq $0x0, 0x30(%rsp)
movq $0x0, 0x20(%rsp)
movq $0x0, 0x18(%rsp)
movq 0x70(%rsp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
jne 0x20bd8f
movq 0x430242(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x30a2ab(%rip), %rsi    # 0x516013
leaq 0x365fa3(%rip), %rdx    # 0x571d12
leaq 0x365fba(%rip), %rcx    # 0x571d30
leaq 0x365f78(%rip), %r8     # 0x571cf5
movl $0x12d, %r9d            # imm = 0x12D
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20bd91
movb $0x1, 0x50(%rsp)
movq 0x70(%rsp), %rax
shrq %rax
movq %rax, 0x40(%rsp)
cmpq $0x0, 0x40(%rsp)
jbe 0x20be47
movq 0x40(%rsp), %rax
andq $0x1, %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
cmpq 0x38(%rsp), %rax
je 0x20bde1
movq 0x20(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x20(%rsp)
movq 0x8(%rsp), %rax
movq %rax, 0x38(%rsp)
jmp 0x20bde3
cmpq $0x20, 0x20(%rsp)
jb 0x20be23
movq 0x4301ae(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x30a217(%rip), %rsi    # 0x516013
leaq 0x365f45(%rip), %rdx    # 0x571d48
leaq 0x365f26(%rip), %rcx    # 0x571d30
leaq 0x365ee4(%rip), %r8     # 0x571cf5
movl $0x138, %r9d            # imm = 0x138
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20be25
movq 0x20(%rsp), %rax
movb 0x50(%rsp,%rax), %cl
addb $0x1, %cl
movb %cl, 0x50(%rsp,%rax)
movq 0x40(%rsp), %rax
shrq %rax
movq %rax, 0x40(%rsp)
jmp 0x20bda3
movq 0x20(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
andq $0x1, %rax
cmpq $0x1, %rax
je 0x20be9c
movq 0x430135(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x30a19e(%rip), %rsi    # 0x516013
leaq 0x365f05(%rip), %rdx    # 0x571d81
leaq 0x365ead(%rip), %rcx    # 0x571d30
leaq 0x365e6b(%rip), %r8     # 0x571cf5
movl $0x13c, %r9d            # imm = 0x13C
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20be9e
movl $0x10, %edi
leaq 0x365e4b(%rip), %rsi    # 0x571cf5
movl $0x13d, %edx            # imm = 0x13D
callq 0xe80f0
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rcx
shrq %rcx
addq $0x1, %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x8(%rax)
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rdi
shlq $0x4, %rdi
leaq 0x365e13(%rip), %rsi    # 0x571cf5
movl $0x140, %edx            # imm = 0x140
callq 0xe80f0
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, (%rax)
movq 0x10(%rsp), %rax
cmpq $0x0, (%rax)
jne 0x20bf3a
movq 0x430097(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x30a100(%rip), %rsi    # 0x516013
leaq 0x365e7a(%rip), %rdx    # 0x571d94
leaq 0x365e0f(%rip), %rcx    # 0x571d30
leaq 0x365dcd(%rip), %r8     # 0x571cf5
movl $0x141, %r9d            # imm = 0x141
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20bf3c
movq $0x1, 0x38(%rsp)
movq $0x0, 0x28(%rsp)
movq 0x28(%rsp), %rax
cmpq 0x20(%rsp), %rax
jae 0x20c098
movq 0x28(%rsp), %rax
movb 0x50(%rsp,%rax), %al
movb %al, 0x7(%rsp)
cmpq $0x1, 0x38(%rsp)
jne 0x20c05c
movzbl 0x7(%rsp), %eax
movl %eax, %eax
movl %eax, %ecx
movl $0x1, %eax
shlq %cl, %rax
subq $0x1, %rax
movzbl 0x4f(%rsp), %ecx
movl %ecx, %ecx
shlq %cl, %rax
orq 0x30(%rsp), %rax
movq %rax, 0x30(%rsp)
movq $0x0, 0x38(%rsp)
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rcx
cmpq 0x8(%rcx), %rax
jb 0x20bff1
movq 0x42ffe0(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x30a049(%rip), %rsi    # 0x516013
leaq 0x365ddf(%rip), %rdx    # 0x571db0
leaq 0x365d58(%rip), %rcx    # 0x571d30
leaq 0x365d16(%rip), %r8     # 0x571cf5
movl $0x14a, %r9d            # imm = 0x14A
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20bff3
movzbl 0x7(%rsp), %eax
shll %eax
movl %eax, %eax
movl %eax, %ecx
movl $0x1, %eax
shlq %cl, %rax
subq $0x1, %rax
movzbl 0x4f(%rsp), %ecx
shll %ecx
movl %ecx, %ecx
shlq %cl, %rax
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq (%rax), %rax
movq 0x18(%rsp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movzbl 0x4e(%rsp), %ecx
shll %ecx
movq 0x10(%rsp), %rax
movq (%rax), %rax
movq 0x18(%rsp), %rdx
movq %rdx, %rsi
addq $0x1, %rsi
movq %rsi, 0x18(%rsp)
shlq $0x4, %rdx
addq %rdx, %rax
movl %ecx, 0x8(%rax)
jmp 0x20c075
movq $0x1, 0x38(%rsp)
movzbl 0x7(%rsp), %ecx
movzbl 0x4e(%rsp), %eax
addl %ecx, %eax
movb %al, 0x4e(%rsp)
movzbl 0x7(%rsp), %ecx
movzbl 0x4f(%rsp), %eax
addl %ecx, %eax
movb %al, 0x4f(%rsp)
movq 0x28(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x28(%rsp)
jmp 0x20bf4e
jmp 0x20c09a
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rcx
cmpq 0x8(%rcx), %rax
jne 0x20c0b6
movq 0x30(%rsp), %rax
cmpq 0x70(%rsp), %rax
je 0x20c0ee
movq 0x42fee3(%rip), %rax    # 0x63bfa0
movq (%rax), %rdi
leaq 0x309f4c(%rip), %rsi    # 0x516013
leaq 0x365d06(%rip), %rdx    # 0x571dd4
leaq 0x365c5b(%rip), %rcx    # 0x571d30
leaq 0x365c19(%rip), %r8     # 0x571cf5
movl $0x155, %r9d            # imm = 0x155
movb $0x0, %al
callq 0x199f0
callq 0x19370
jmp 0x20c0f0
movq 0x10(%rsp), %rax
addq $0x78, %rsp
retq
nopw (%rax,%rax)