// File: /workspace/github_cpp_makefile_star2_O3/huiwenliuge[P]EmoAnaer/src/DictCreate.cpp
// Function: fapdDic(_IO_FILE*, _IO_FILE*, _IO_FILE*, int)
void fapdDic(FILE* infp,FILE* srcfp,FILE* outfp,int dim){
	char* tmp  =(char*)calloc(sizeof(char),421);  
	char* sta=tmp;
	int lenTmp,i;

    ChUTF8* hash=fldDic(srcfp,dim);
	ChUTF8 NewS;
    while(fscanf(infp,"%s\n",sta)!=-1){
		tmp=sta;
        while(tmp[0]!='\0'){
            lenTmp=retLenUTF8(tmp);
           if(!hIscontain(hash,tmp,lenTmp)){
                NewS = (ChUTF8)malloc(sizeof(struct chUTF8));
                NewS->schar=(char*)malloc(sizeof(char)*(lenTmp+1));
                memcpy(NewS->schar,tmp,lenTmp);
                NewS->schar[lenTmp]='\0';
//std::cout<<tmp<<":"<<lenTmp<<":"<<NewS->schar<<std::endl;
                NewS->vecftr=(double*)malloc(sizeof(double)*dim);
                for(i=0;i<dim;++i){
                    NewS->vecftr[i]=(rand()%101-50)/50.0;
                }
            
                hashput(hash,NewS);
           }
					
            tmp+=lenTmp;
        }
		memset(sta,'\0',421*sizeof(char));
    }
	
    prtHash2File(hash,outfp,dim);
    fflush(outfp);
    hashFree(hash);

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %ecx, %r14d
movq %rdx, -0x48(%rbp)
movq %rsi, %rbx
movq %rdi, %r15
movl $0x1, %edi
movl $0x1a5, %esi            # imm = 0x1A5
callq 0x20c0
movq %rax, %r13
movq %rbx, %rdi
movl %r14d, -0x2c(%rbp)
movl %r14d, %esi
callq 0x4f3f
movq %rax, -0x38(%rbp)
leaq 0x12cc(%rip), %rsi      # 0x6076
movq %r15, -0x50(%rbp)
movq %r15, %rdi
movq %r13, %rdx
xorl %eax, %eax
callq 0x2280
cmpl $-0x1, %eax
je 0x4f0b
movl -0x2c(%rbp), %eax
movslq %eax, %rcx
shlq $0x3, %rcx
movq %rcx, -0x58(%rbp)
movl %eax, %r12d
movq %r13, -0x40(%rbp)
movb (%r13), %al
testb %al, %al
je 0x4eda
movq -0x40(%rbp), %r13
movl $0x1, %ebx
cmpb $-0x40, %al
jb 0x4e17
movl $0x2, %ebx
cmpb $-0x20, %al
jb 0x4e17
movl $0x3, %ebx
cmpb $-0x10, %al
jb 0x4e17
movl $0x4, %ebx
cmpb $-0x8, %al
jb 0x4e17
cmpb $-0x4, %al
movl $0x6, %ebx
sbbl $0x0, %ebx
movq -0x38(%rbp), %rdi
movq %r13, %rsi
movl %ebx, %edx
callq 0x5144
movl %ebx, %r15d
testb %al, %al
jne 0x4eca
movl $0x18, %edi
callq 0x21f0
movq %rax, %r14
incl %ebx
movq %rbx, %rdi
callq 0x21f0
movq %rax, %rbx
movq %rax, (%r14)
movq %rax, %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x2110
movb $0x0, (%rbx,%r15)
movq -0x58(%rbp), %rdi
callq 0x21f0
movq %rax, 0x8(%r14)
cmpl $0x0, -0x2c(%rbp)
jle 0x4ebe
xorl %ebx, %ebx
callq 0x2050
movsd 0x1346(%rip), %xmm1     # 0x61c8
cltq
imulq $0x288df0cb, %rax, %rcx # imm = 0x288DF0CB
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x24, %rcx
addl %edx, %ecx
imull $0x65, %ecx, %ecx
negl %ecx
addl %ecx, %eax
addl $-0x32, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
movq 0x8(%r14), %rax
movsd %xmm0, (%rax,%rbx,8)
incq %rbx
cmpq %rbx, %r12
jne 0x4e75
movq -0x38(%rbp), %rdi
movq %r14, %rsi
callq 0x51bc
movb (%r13,%r15), %al
addq %r15, %r13
testb %al, %al
jne 0x4de9
movl $0x1a5, %edx            # imm = 0x1A5
movq -0x40(%rbp), %r13
movq %r13, %rdi
xorl %esi, %esi
callq 0x20b0
movq -0x50(%rbp), %rdi
leaq 0x117e(%rip), %rsi      # 0x6076
movq %r13, %rdx
xorl %eax, %eax
callq 0x2280
cmpl $-0x1, %eax
jne 0x4dd9
movq -0x38(%rbp), %r14
movq %r14, %rdi
movq -0x48(%rbp), %rbx
movq %rbx, %rsi
movl -0x2c(%rbp), %edx
callq 0x5203
movq %rbx, %rdi
callq 0x21b0
movq %r14, %rdi
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x52c5