// File: /workspace/github_c_makefile_star2_O0/DVaronos[P]AnLogProject1/list.c
// Function: Wrehash
WHash* Wrehash(WHash* H){
  WHash*  Temp;
  int i,index,j;
  Temp=(WHash* )malloc( (H->size*2) *  sizeof(WHash) ); //Dimiourgo ena neo HasTable me thn diplasia xoritikotita
  Temp->size=H->size * 2;
  Temp->count=H->count;
  for(i=0 ; i< Temp->size ; i++){
    Temp[i].word=NULL;
    Temp[i].tfidf=0.0;
  }
  for(i=0 ; i< H->size ; i++){  //Pernaw ta dedomena tou paliou sto neo HasTable

    if(H[i].word!=NULL){  //Ean to arxiko Hash exei dedomena se afthn thn thesh
      j=0;
      while(1){ //Evresi tou bucket pou tha paei to neo product
        if(!j){ //Sthn proth epanalipsh ipologizoume mono thn sinartish hash
          index=whashf(H[i].word,Temp->size);
					j=1;
        }else{
          index++;
					if(index>=Temp->size) index-=Temp->size;
        }
        if(Temp[index].word==NULL){  //Ean einai adio to bucket tha isagoume se afto thn camera
          break;
        }
      }
			//Antigrafi twn dedomenwn
      Temp[index].word=strdup(H[i].word);
      Temp[index].tfidf=H[i].tfidf;
    }
  }
  FreeWHash(H);
  return Temp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl 0x14(%rax), %eax
shll %eax
cltq
imulq $0x18, %rax, %rdi
callq 0x1190
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movl 0x14(%rax), %ecx
shll %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x8(%rbp), %rax
movl 0x10(%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x10(%rax)
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x500d
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq $0x0, 0x8(%rax)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
xorps %xmm0, %xmm0
movsd %xmm0, (%rax)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x4fc9
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x511a
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
cmpq $0x0, 0x8(%rax)
je 0x510a
movl $0x0, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
jne 0x5076
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
movq -0x10(%rbp), %rax
movl 0x14(%rax), %esi
callq 0x4f30
movl %eax, -0x18(%rbp)
movl $0x1, -0x1c(%rbp)
jmp 0x509c
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
movl -0x18(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jl 0x509a
movq -0x10(%rbp), %rax
movl 0x14(%rax), %ecx
movl -0x18(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x18(%rbp)
jmp 0x509c
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
cmpq $0x0, 0x8(%rax)
jne 0x50b4
jmp 0x50b6
jmp 0x5045
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
callq 0x1250
movq %rax, %rcx
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rdx
imulq $0x18, %rdx, %rdx
addq %rdx, %rax
movq %rcx, 0x8(%rax)
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movsd (%rax), %xmm0
movq -0x10(%rbp), %rax
movslq -0x18(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movsd %xmm0, (%rax)
jmp 0x510c
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x5014
movq -0x8(%rbp), %rdi
callq 0x4c80
movq -0x10(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)