// File: /workspace/github_c_makefile_star2_O0/richarddurbin[P]hash10x/dict.c
// Function: dictAdd
int dictAdd (DICT *dict, char *s, int *ip)
{
  int i, x ;

  if (dictFind (dict, s, ip)) return 0 ;

  i = ++dict->max ;
  dict->table[newPos] = i ;
  dict->names[i] = (char*) myalloc (strlen(s) + 1) ;
  strcpy (dict->names[i], s) ;
  if (ip) *ip = i-1 ;

  if (dict->max > 0.3 * dict->size) /* double table size and remap */
    { int *newTable ;
      ++dict->dim ; dict->size *= 2 ;
      dict->names = (char**) remap (dict->names, (dict->max+1)*sizeof(char*), (dict->size/2)*sizeof(char*)) ;
      newTable = (int*) mycalloc (dict->size, sizeof(int)) ;
      for (i = 1 ; i <= dict->max ; ++i)
	{ s = dict->names[i] ;
	  x = hashString (s, dict->dim, 0) ;
	  if (!newTable[x])
	    newTable[x] = i ;
	  else
	    { int d = hashString (s, dict->dim, 1) ;
	      while (1)
		{ x = (x + d) & ((1 << dict->dim) - 1) ;
		  if (!newTable[x])
		    { newTable[x] = i ; break ; }
		}
	    }
	}
      free (dict->table) ; dict->table = newTable ;
    }

  return 1 ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x6da0
cmpl $0x0, %eax
je 0x7016
movl $0x0, -0x4(%rbp)
jmp 0x7208
movq -0x10(%rbp), %rcx
movl 0x10(%rcx), %eax
addl $0x1, %eax
movl %eax, 0x10(%rcx)
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %edx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movslq 0x7350(%rip), %rcx      # 0xe388
movl %edx, (%rax,%rcx,4)
movq -0x18(%rbp), %rdi
callq 0x10a0
movq %rax, %rdi
addq $0x1, %rdi
callq 0x8260
movq %rax, %rdx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x24(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movq -0x18(%rbp), %rsi
callq 0x1060
cmpq $0x0, -0x20(%rbp)
je 0x708d
movl -0x24(%rbp), %ecx
subl $0x1, %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
cvtsi2sdl 0x10(%rax), %xmm0
movq -0x10(%rbp), %rax
cvtsi2sdl 0x18(%rax), %xmm2
movsd 0x2d99(%rip), %xmm1     # 0x9e40
mulsd %xmm2, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x7201
movq -0x10(%rbp), %rax
movl 0x14(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x14(%rax)
movq -0x10(%rbp), %rax
movl 0x18(%rax), %ecx
shll %ecx
movl %ecx, 0x18(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
addl $0x1, %eax
cltq
shlq $0x3, %rax
movl %eax, %esi
movq -0x10(%rbp), %rax
movl 0x18(%rax), %eax
movl $0x2, %ecx
cltd
idivl %ecx
cltq
shlq $0x3, %rax
movl %eax, %edx
callq 0x7220
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movslq 0x18(%rax), %rdi
movl $0x4, %esi
callq 0x82b0
movq %rax, -0x30(%rbp)
movl $0x1, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x10(%rcx), %eax
jg 0x71e8
movq -0x10(%rbp), %rax
movq (%rax), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movl 0x14(%rax), %esi
xorl %edx, %edx
callq 0x6f10
movl %eax, -0x28(%rbp)
movq -0x30(%rbp), %rax
movslq -0x28(%rbp), %rcx
cmpl $0x0, (%rax,%rcx,4)
jne 0x7180
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rax
movslq -0x28(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
jmp 0x71d8
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movl 0x14(%rax), %esi
movl $0x1, %edx
callq 0x6f10
movl %eax, -0x34(%rbp)
movl -0x28(%rbp), %eax
addl -0x34(%rbp), %eax
movq -0x10(%rbp), %rcx
movl 0x14(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
subl $0x1, %ecx
andl %ecx, %eax
movl %eax, -0x28(%rbp)
movq -0x30(%rbp), %rax
movslq -0x28(%rbp), %rcx
cmpl $0x0, (%rax,%rcx,4)
jne 0x71d4
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rax
movslq -0x28(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
jmp 0x71d6
jmp 0x7198
jmp 0x71d8
jmp 0x71da
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x712a
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x1040
movq -0x30(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)