// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/jkOwnLib/gfBlatLib.c
// Function: gfAlignStrand
void gfAlignStrand(int *pConn, char *tSeqDir, struct dnaSeq *seq,
    boolean isRc, int minMatch, struct hash *tFileCache, struct gfOutput *out)
/* Search genome on server with one strand of other sequence to find homology. 
 * Then load homologous bits of genome locally and do detailed alignment.
 * Call 'outFunction' with each alignment that is found. */
{
struct ssBundle *bun;
struct gfRange *rangeList = NULL, *range;
struct dnaSeq *targetSeq;
char targetName[PATH_LEN];

rangeList = gfQuerySeq(*pConn, seq);
close(*pConn);
*pConn = -1;
slSort(&rangeList, gfRangeCmpTarget);
rangeList = gfRangesBundle(rangeList, ffIntronMax);
for (range = rangeList; range != NULL; range = range->next)
    {
    getTargetName(range->tName, out->includeTargetFile, targetName);
    targetSeq = gfiExpandAndLoadCached(range, tFileCache, tSeqDir, 
    	seq->size, &range->tTotalSize, FALSE, FALSE, usualExpansion);
    AllocVar(bun);
    bun->qSeq = seq;
    bun->genoSeq = targetSeq;
    alignComponents(range, bun, ffCdna);
    ssStitch(bun, ffCdna, minMatch, ssAliCount);
    saveAlignments(targetName, range->tTotalSize, range->tStart, 
	bun, NULL, isRc, FALSE, ffCdna, minMatch, out);
    ssBundleFree(&bun);
    freeDnaSeq(&targetSeq);
    }
gfRangeFreeList(&rangeList);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x270, %rsp            # imm = 0x270
movq 0x10(%rbp), %rax
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, -0x38(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %edi
movq -0x18(%rbp), %rsi
callq 0x11e70
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %edi
callq 0x6e90
movq -0x8(%rbp), %rax
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
leaq -0x38(%rbp), %rdi
leaq -0x4f1(%rip), %rsi      # 0x11830
callq 0x2ab90
movq -0x38(%rbp), %rdi
leaq 0xf4f6f(%rip), %rax     # 0x106ca0
movl (%rax), %esi
callq 0x119f0
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
je 0x11e5c
movq -0x40(%rbp), %rax
movq 0x10(%rax), %rdi
movq 0x10(%rbp), %rax
movl 0x48(%rax), %esi
leaq -0x250(%rbp), %rdx
callq 0x11f70
movq -0x40(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x10(%rbp), %rdx
movq -0x18(%rbp), %rax
movl 0x18(%rax), %ecx
movq -0x40(%rbp), %r8
addq $0x40, %r8
movl 0xf4065(%rip), %eax     # 0x105df0
xorl %r9d, %r9d
movl $0x0, (%rsp)
movl %eax, 0x8(%rsp)
callq 0x16390
movq %rax, -0x48(%rbp)
movl $0x48, %edi
callq 0x40c50
movq %rax, -0x30(%rbp)
movq -0x18(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x48(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x40(%rbp), %rdi
movq -0x30(%rbp), %rsi
movl $0x1, %edx
callq 0x11ff0
movq -0x30(%rbp), %rdi
movl -0x20(%rbp), %edx
movl 0xf400d(%rip), %ecx     # 0x105df4
movl $0x1, %esi
callq 0x18b80
leaq -0x250(%rbp), %rdi
movq -0x40(%rbp), %rax
movl 0x40(%rax), %esi
movq -0x40(%rbp), %rax
movl 0x20(%rax), %edx
movq -0x30(%rbp), %rcx
movl -0x1c(%rbp), %r9d
movl -0x20(%rbp), %r10d
movq 0x10(%rbp), %rax
xorl %r8d, %r8d
xorl %r11d, %r11d
movl $0x0, (%rsp)
movl $0x1, 0x8(%rsp)
movl %r10d, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x121d0
leaq -0x30(%rbp), %rdi
callq 0x183a0
leaq -0x48(%rbp), %rdi
callq 0x327f0
movq -0x40(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x40(%rbp)
jmp 0x11d44
leaq -0x38(%rbp), %rdi
callq 0x117e0
addq $0x270, %rsp            # imm = 0x270
popq %rbp
retq
nop