// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/jkOwnLib/gfBlatLib.c
// Function: gfFindAlignAaTrans
void gfFindAlignAaTrans(struct genoFind *gfs[3], aaSeq *qSeq, struct hash *t3Hash, 
	boolean tIsRc, int minMatch, struct gfOutput *out)
/* Look for qSeq alignment in three translated reading frames. Save alignment
 * via outFunction/outData. */
{
struct gfClump *clumps[3];
int frame;
struct gfClump *clump;
struct gfRange *rangeList = NULL, *range;
aaSeq *targetSeq;
struct ssBundle *bun;
int tileSize = gfs[0]->tileSize;
struct trans3 *t3;
int hitCount;
struct lm *lm = lmInit(0);

gfTransFindClumps(gfs, qSeq, clumps, lm, &hitCount);
for (frame=0; frame<3; ++frame)
    {
    for (clump = clumps[frame]; clump != NULL; clump = clump->next)
	{
	clumpToHspRange(clump, qSeq, tileSize, frame, NULL, &rangeList, TRUE, FALSE);
	}
    }
slReverse(&rangeList);
slSort(&rangeList, gfRangeCmpTarget);
rangeList = gfRangesBundle(rangeList, ffIntronMax/3);
for (range = rangeList; range != NULL; range = range->next)
    {
    targetSeq = range->tSeq;
    t3 = hashMustFindVal(t3Hash, targetSeq->name);
    AllocVar(bun);
    bun->qSeq = qSeq;
    bun->genoSeq = targetSeq;
    bun->ffList = gfRangesToFfItem(range->components, qSeq);
    bun->isProt = TRUE;
    bun->t3List = t3;
    ssStitch(bun, ffCdna, minMatch, ssAliCount);
    saveAlignments(targetSeq->name, t3->seq->size, 0, 
	bun, t3Hash, FALSE, tIsRc, ffCdna, minMatch, out);
    ssBundleFree(&bun);
    }
gfRangeFreeList(&rangeList);
for (frame=0; frame<3; ++frame)
    gfClumpFreeList(&clumps[frame]);
lmCleanup(&lm);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movq %r9, -0x28(%rbp)
movq $0x0, -0x58(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl 0xc(%rax), %eax
movl %eax, -0x74(%rbp)
xorl %edi, %edi
callq 0x3dc20
movq %rax, -0x90(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
leaq -0x40(%rbp), %rdx
movq -0x90(%rbp), %rcx
leaq -0x84(%rbp), %r8
callq 0xf0c0
movl $0x0, -0x44(%rbp)
cmpl $0x3, -0x44(%rbp)
jge 0x127ec
movslq -0x44(%rbp), %rax
movq -0x40(%rbp,%rax,8), %rax
movq %rax, -0x50(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x127df
movq -0x50(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x74(%rbp), %edx
movl -0x44(%rbp), %ecx
xorl %eax, %eax
movl %eax, %r8d
leaq -0x58(%rbp), %r9
xorl %eax, %eax
movl $0x1, (%rsp)
movl $0x0, 0x8(%rsp)
callq 0x12980
movq -0x50(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x50(%rbp)
jmp 0x1279e
jmp 0x127e1
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x1278b
leaq -0x58(%rbp), %rdi
callq 0x2aad0
leaq -0x58(%rbp), %rdi
leaq -0xfd0(%rip), %rsi      # 0x11830
callq 0x2ab90
movq -0x58(%rbp), %rdi
leaq 0xf4490(%rip), %rax     # 0x106ca0
movl (%rax), %eax
movl $0x3, %ecx
cltd
idivl %ecx
movl %eax, %esi
callq 0x119f0
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x60(%rbp)
cmpq $0x0, -0x60(%rbp)
je 0x1292a
movq -0x60(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x18(%rbp), %rdi
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x39590
movq %rax, -0x80(%rbp)
movl $0x48, %edi
callq 0x40c50
movq %rax, -0x70(%rbp)
movq -0x10(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x68(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x60(%rbp), %rax
movq 0x28(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x12370
movq %rax, %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x70(%rbp), %rax
movl $0x1, 0x30(%rax)
movq -0x80(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x70(%rbp), %rdi
movl -0x20(%rbp), %edx
movl 0xf3535(%rip), %ecx     # 0x105df4
movl $0x1, %esi
callq 0x18b80
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x80(%rbp), %rax
movq 0x10(%rax), %rax
movl 0x18(%rax), %esi
movq -0x70(%rbp), %rcx
movq -0x18(%rbp), %r8
movl -0x1c(%rbp), %r11d
movl -0x20(%rbp), %r10d
movq -0x28(%rbp), %rax
xorl %r9d, %r9d
movl %r9d, %edx
movl %r11d, (%rsp)
movl $0x1, 0x8(%rsp)
movl %r10d, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x121d0
leaq -0x70(%rbp), %rdi
callq 0x183a0
movq -0x60(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x60(%rbp)
jmp 0x1282d
leaq -0x58(%rbp), %rdi
callq 0x117e0
movl $0x0, -0x44(%rbp)
cmpl $0x3, -0x44(%rbp)
jge 0x1295f
movslq -0x44(%rbp), %rax
leaq -0x40(%rbp), %rdi
shlq $0x3, %rax
addq %rax, %rdi
callq 0xe5f0
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x1293a
leaq -0x90(%rbp), %rdi
callq 0x3dd90
addq $0xb0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)