// File: /workspace/github_c_makefile_star2_O2/icebert[P]pblat/jkOwnLib/gfClientLib.c
// Function: gfClientSeqList
bioSeq *gfClientSeqList(int fileCount, char *files[], 
	boolean isProt, boolean isTransDna, char *maskType, 
	float minRepDivergence, boolean showStatus)
/* From an array of .fa and .nib file names, create a
 * list of dnaSeqs, which are set up so that upper case is masked and lower case
 * is unmasked sequence. (This is the opposite of the input, but set so that
 * we can use lower case as our primary DNA sequence, which historically predates
 * our use of lower case masking.)  Protein sequence on the other hand is
 * all upper case. */

{
int i;
char *fileName;
bioSeq *seqList = NULL, *seq;
boolean doMask = (maskType != NULL);

unsigned faFastBufSize = 0;
DNA     *faFastBuf = NULL;

for (i=0; i<fileCount; ++i)
    {
    struct dnaSeq *list = NULL, sseq;
    ZeroVar(&sseq);
    fileName = files[i];
    if (nibIsFile(fileName))
	list = nibLoadAllMasked(NIB_MASK_MIXED|NIB_BASE_NAME, fileName);
    else if (twoBitIsSpec(fileName))
	list = twoBitLoadAll(fileName);
    else if (isProt)
      list = faReadAllPep(fileName, &faFastBuf, &faFastBufSize);
    else
      list = faReadAllMixed(fileName, &faFastBuf, &faFastBufSize);
    faFreeFastBuf(&faFastBuf, &faFastBufSize);
    

    /* If necessary mask sequence from file. */
    if (doMask)
	{
	maskNucSeqList(list, fileName, maskType, isTransDna, minRepDivergence);
	}
    else
        {
	/* If not masking send everything to proper case here. */
	for (seq = list; seq != NULL; seq = seq->next)
	    {
	    if (isProt)
		faToProtein(seq->dna, seq->size);
	    else
		faToDna(seq->dna, seq->size);
	    }
	}
    /* Move local list to end of bigger list. */
    seqList = slCat(seqList, list);
    }
if (showStatus)
    {
    /* Total up size and sequence count and report. */
    int count = 0; 
    unsigned long totalSize = 0;
    for (seq = seqList; seq != NULL; seq = seq->next)
        {
	totalSize += seq->size;
	count += 1;
	}
    printf("Loaded %lu letters in %d sequences\n", totalSize, count);
    }
return seqList;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3c8, %rsp            # imm = 0x3C8
movl %r9d, 0x1c(%rsp)
movss %xmm0, 0x24(%rsp)
movq %r8, %r14
movl %ecx, %ebp
movl %edx, %r15d
leaq 0xc(%rsp), %rax
andl $0x0, (%rax)
leaq 0x10(%rsp), %rax
andq $0x0, (%rax)
xorl %eax, %eax
testl %edi, %edi
cmovlel %eax, %edi
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
xorl %ecx, %ecx
xorl %ebx, %ebx
movq %r8, 0x28(%rsp)
movl %ebp, 0x20(%rsp)
cmpq 0x38(%rsp), %rcx
je 0x10763
movq 0x30(%rsp), %rax
movq %rcx, 0x40(%rsp)
movq (%rax,%rcx,8), %r12
movq %r12, %rdi
callq 0x2ce73
testl %eax, %eax
movq %rbx, 0x48(%rsp)
je 0x1040b
pushq $0x5
popq %rdi
movq %r12, %rsi
callq 0x2ca98
jmp 0x1043c
movq %r12, %rdi
callq 0x391eb
movq %r12, %rdi
testl %eax, %eax
je 0x10421
callq 0x38ce1
jmp 0x1043c
leaq 0x10(%rsp), %rsi
leaq 0xc(%rsp), %rdx
testl %r15d, %r15d
je 0x10437
callq 0x23507
jmp 0x1043c
callq 0x23514
movq %rax, %r13
leaq 0x10(%rsp), %rdi
leaq 0xc(%rsp), %rsi
callq 0x22e09
movq %r13, %rbx
testq %r14, %r14
je 0x1051c
movq %r14, %rdi
leaq 0x6c1e3(%rip), %rsi     # 0x7c647
callq 0x1cd23
testl %eax, %eax
je 0x10577
movq %r14, %rdi
leaq 0x6c0f8(%rip), %rsi     # 0x7c573
callq 0x1cd23
testl %eax, %eax
je 0x105b1
movq %r14, %rdi
leaq 0x6cbed(%rip), %rsi     # 0x7d07f
callq 0x1cd23
testl %eax, %eax
jne 0x104b7
leaq 0x1c0(%rsp), %r14
movq %r14, %rdi
leaq 0x6cbcf(%rip), %rsi     # 0x7d07c
movq %r12, %rdx
xorl %eax, %eax
callq 0x6170
movq %r13, %rdi
callq 0x10365
movq %r14, %rdi
pushq $0x1
popq %rbx
movl %ebx, %esi
callq 0x25467
movq %rax, %rbp
movq %rax, 0x58(%rsp)
xorl %edi, %edi
movl %ebx, %esi
callq 0x245c9
movq %rax, %r12
movq %rax, 0x50(%rsp)
movq %r13, %rbx
testq %rbx, %rbx
je 0x10523
movq 0x8(%rbx), %rsi
movq %r12, %rdi
movq %rbx, %rdx
callq 0x242d0
movq (%rbx), %rbx
jmp 0x104e8
movq 0x10(%rbx), %rdi
movl 0x18(%rbx), %esi
testl %r15d, %r15d
je 0x10514
callq 0x2330e
jmp 0x10519
callq 0x23357
movq (%rbx), %rbx
testq %rbx, %rbx
jne 0x10501
jmp 0x10594
movq %rbp, %rdi
movq %rsp, %rsi
xorl %edx, %edx
callq 0x256a7
testl %eax, %eax
jne 0x10546
movq 0x8(%rbp), %rsi
leaq 0x6cb44(%rip), %rdi     # 0x7d083
xorl %eax, %eax
callq 0x223fb
movq (%rsp), %rsi
leaq 0x6cb46(%rip), %rdi     # 0x7d097
callq 0x1db41
testl %eax, %eax
je 0x105ca
leaq 0x50(%rsp), %rdi
callq 0x2494c
leaq 0x58(%rsp), %rdi
callq 0x25cd8
movq 0x28(%rsp), %r14
movl 0x20(%rsp), %ebp
testl %ebp, %ebp
je 0x10594
movq %r13, %rbx
testq %rbx, %rbx
je 0x10594
movq 0x10(%rbx), %rdi
movl 0x18(%rbx), %esi
callq 0x21072
movq (%rbx), %rbx
jmp 0x1057e
movq 0x48(%rsp), %rdi
movq %r13, %rsi
callq 0x1c549
movq %rax, %rbx
movq 0x40(%rsp), %rcx
incq %rcx
jmp 0x103d4
movq %r13, %rbx
testq %rbx, %rbx
je 0x10577
movq 0x10(%rbx), %rdi
movl 0x18(%rbx), %esi
callq 0x1dfc1
movq (%rbx), %rbx
jmp 0x105b4
movq (%rsp), %rsi
leaq 0x6cad0(%rip), %rdi     # 0x7d0a5
callq 0x1db41
testl %eax, %eax
jne 0x105f0
movq 0x8(%rbp), %rsi
leaq 0x6cac2(%rip), %rdi     # 0x7d0ab
xorl %eax, %eax
callq 0x223fb
movq %rbp, %rdi
movq %rsp, %rsi
xorl %edx, %edx
callq 0x256a7
testl %eax, %eax
je 0x10615
movq (%rsp), %rsi
leaq 0x6e52c(%rip), %rdi     # 0x7eb38
callq 0x1db41
testl %eax, %eax
jne 0x10627
movq 0x8(%rbp), %rsi
leaq 0x6ca8b(%rip), %rdi     # 0x7d0ab
xorl %eax, %eax
callq 0x223fb
movq %rbp, %rdi
movq %rsp, %rsi
xorl %edx, %edx
callq 0x256a7
movq %rbp, %rdi
movq %rsp, %rsi
xorl %edx, %edx
callq 0x256a7
testl %eax, %eax
je 0x1055a
movq (%rsp), %rdi
leaq 0xc0(%rsp), %rsi
pushq $0x20
popq %rdx
callq 0x1e59b
cmpl $0xd, %eax
jg 0x10677
movq 0x8(%rbp), %rsi
movl 0x28(%rbp), %edx
leaq 0x6ca5e(%rip), %rdi     # 0x7d0ce
xorl %eax, %eax
callq 0x223fb
leaq 0xc0(%rsp), %rdi
leaq 0x60(%rsp), %rsi
callq 0x35610
movss 0x6c(%rsp), %xmm0
addss 0x70(%rsp), %xmm0
addss 0x74(%rsp), %xmm0
movss 0x24(%rsp), %xmm1
ucomiss %xmm0, %xmm1
jb 0x10634
movq 0x78(%rsp), %rsi
movq %r12, %rdi
callq 0x244c6
movq %rax, %r14
testq %rax, %rax
jne 0x106d2
movq 0x78(%rsp), %rsi
movq 0x8(%rbp), %rdx
leaq 0x6ca30(%rip), %rdi     # 0x7d0fb
xorl %eax, %eax
callq 0x223fb
movl 0x18(%r14), %ebx
movl 0x80(%rsp), %esi
movl 0x84(%rsp), %edx
testl %esi, %esi
jle 0x106fc
cmpl %ebx, %esi
jg 0x106fc
testl %edx, %edx
jle 0x106fc
cmpl %ebx, %edx
jg 0x106fc
cmpl %edx, %esi
jg 0x106fc
movl %edx, %ebx
jmp 0x10740
movq 0x78(%rsp), %r8
leaq 0x6ca38(%rip), %rdi     # 0x7d140
movl %ebx, %ecx
xorl %eax, %eax
callq 0x22186
movl 0x80(%rsp), %esi
testl %esi, %esi
jg 0x1072a
movl $0x1, 0x80(%rsp)
pushq $0x1
popq %rsi
movl 0x84(%rsp), %eax
cmpl %ebx, %eax
jle 0x1073e
movl %ebx, 0x84(%rsp)
jmp 0x10740
movl %eax, %ebx
subl %esi, %ebx
js 0x10634
incl %ebx
movq 0x10(%r14), %rax
movl %esi, %ecx
leaq (%rax,%rcx), %rdi
decq %rdi
movl %ebx, %esi
callq 0x1df53
jmp 0x10634
cmpl $0x0, 0x1c(%rsp)
je 0x10792
xorl %edx, %edx
movq %rbx, %rax
xorl %esi, %esi
testq %rax, %rax
je 0x10784
movslq 0x18(%rax), %rcx
addq %rcx, %rsi
incl %edx
movq (%rax), %rax
jmp 0x10771
leaq 0x6c8cd(%rip), %rdi     # 0x7d058
xorl %eax, %eax
callq 0x6070
movq %rbx, %rax
addq $0x3c8, %rsp            # imm = 0x3C8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop