// File: /workspace/github_c_makefile_star2_O3/kieselsteini[P]PiXL-old/lua53.c
// Function: luaH_resize
void luaH_resize (lua_State *L, Table *t, unsigned int nasize,
                                          unsigned int nhsize) {
  unsigned int i;
  int j;
  unsigned int oldasize = t->sizearray;
  int oldhsize = allocsizenode(t);
  Node *nold = t->node;  /* save old hash ... */
  if (nasize > oldasize)  /* array part must grow? */
    setarrayvector(L, t, nasize);
  /* create new hash part with appropriate size */
  setnodevector(L, t, nhsize);
  if (nasize < oldasize) {  /* array part must shrink? */
    t->sizearray = nasize;
    /* re-insert elements from vanishing slice */
    for (i=nasize; i<oldasize; i++) {
      if (!ttisnil(&t->array[i]))
        luaH_setint(L, t, i + 1, &t->array[i]);
    }
    /* shrink array */
    luaM_reallocvector(L, t->array, oldasize, nasize, TValue);
  }
  /* re-insert elements from hash part */
  for (j = oldhsize - 1; j >= 0; j--) {
    Node *old = nold + j;
    if (!ttisnil(gval(old))) {
      /* doesn't need barrier/invalidate cache, as entry was
         already present in the table */
      setobjt2t(L, luaH_set(L, t, gkey(old)), gval(old));
    }
  }
  if (oldhsize > 0)  /* not the dummy node? */
    luaM_freearray(L, nold, cast(size_t, oldhsize)); /* free old hash */
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, %r13d
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movl 0xc(%rsi), %edx
cmpq $0x0, 0x20(%rsi)
je 0xb2ed
movb 0xb(%r14), %cl
movl $0x1, %r12d
shll %cl, %r12d
jmp 0xb2f0
xorl %r12d, %r12d
movq 0x18(%r14), %rax
movq %rax, 0x10(%rsp)
cmpl %ebp, %edx
movq %rdx, 0x8(%rsp)
jae 0xb43c
movq 0x10(%r14), %rsi
shlq $0x4, %rdx
movl %ebp, %r15d
movq %r15, %rcx
shlq $0x4, %rcx
movq %rbx, %rdi
callq 0x11d07
movq %rax, 0x10(%r14)
movl 0xc(%r14), %edx
cmpl %ebp, %edx
jae 0xb433
subq %rdx, %r15
leaq 0x3(%r15), %rcx
andq $-0x4, %rcx
decq %r15
movq %r15, %xmm0
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
shlq $0x4, %rdx
addq %rdx, %rax
addq $0x38, %rax
xorl %edx, %edx
movdqa 0x26cb3(%rip), %xmm1    # 0x32010
movdqa 0x26cbb(%rip), %xmm2    # 0x32020
movdqa 0x26cc3(%rip), %xmm3    # 0x32030
pxor %xmm3, %xmm0
pcmpeqd %xmm4, %xmm4
movq %rdx, %xmm5
pshufd $0x44, %xmm5, %xmm5     # xmm5 = xmm5[0,1,0,1]
movdqa %xmm5, %xmm6
por %xmm2, %xmm6
pxor %xmm3, %xmm6
movdqa %xmm6, %xmm7
pcmpgtd %xmm0, %xmm7
pcmpeqd %xmm0, %xmm6
pshufd $0xf5, %xmm6, %xmm8     # xmm8 = xmm6[1,1,3,3]
pand %xmm7, %xmm8
pshufd $0xf5, %xmm7, %xmm6     # xmm6 = xmm7[1,1,3,3]
por %xmm8, %xmm6
movd %xmm6, %esi
notl %esi
testb $0x1, %sil
je 0xb3bf
movl $0x0, -0x30(%rax)
pxor %xmm4, %xmm6
pextrw $0x4, %xmm6, %esi
testb $0x1, %sil
je 0xb3d5
movl $0x0, -0x20(%rax)
por %xmm1, %xmm5
pxor %xmm3, %xmm5
movdqa %xmm5, %xmm6
pcmpgtd %xmm0, %xmm6
pcmpeqd %xmm0, %xmm5
pshufd $0xf5, %xmm5, %xmm7     # xmm7 = xmm5[1,1,3,3]
pand %xmm6, %xmm7
pshufd $0xf5, %xmm6, %xmm5     # xmm5 = xmm6[1,1,3,3]
por %xmm7, %xmm5
pxor %xmm4, %xmm5
pextrw $0x0, %xmm5, %esi
testb $0x1, %sil
je 0xb411
movl $0x0, -0x10(%rax)
pextrw $0x4, %xmm5, %esi
testb $0x1, %sil
je 0xb422
movl $0x0, (%rax)
addq $0x4, %rdx
addq $0x40, %rax
cmpq %rdx, %rcx
jne 0xb375
movl %ebp, 0xc(%r14)
movq 0x8(%rsp), %rdx
testl %r13d, %r13d
movl %r12d, 0x4(%rsp)
je 0xb46d
decl %r13d
xorl %eax, %eax
cmpl $0x100, %r13d           # imm = 0x100
jb 0xb482
xorl %eax, %eax
movl %r13d, %ecx
addl $0x8, %eax
shrl $0x8, %ecx
cmpl $0xffff, %r13d          # imm = 0xFFFF
movl %ecx, %r13d
ja 0xb459
jmp 0xb485
leaq 0x2793c(%rip), %rax     # 0x32db0
movq %rax, 0x18(%r14)
movb $0x0, 0xb(%r14)
xorl %r12d, %r12d
jmp 0xb4f6
movl %r13d, %ecx
movl %ecx, %ecx
leaq 0x276f2(%rip), %rdx     # 0x32b80
movzbl (%rcx,%rdx), %r13d
addl %eax, %r13d
cmpl $0x1f, %r13d
jge 0xb5ec
movl $0x1, %r15d
movl %r13d, %ecx
shll %cl, %r15d
movq %r15, %r12
shlq $0x5, %r12
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
movq %r12, %rcx
callq 0x11d07
movq %rax, 0x18(%r14)
movl $0x1c, %eax
movq 0x18(%r14), %rcx
movq $0x0, -0x4(%rcx,%rax)
movl $0x0, -0x14(%rcx,%rax)
addq $0x20, %rax
decq %r15
jne 0xb4cb
movb %r13b, 0xb(%r14)
addq 0x18(%r14), %r12
movq 0x8(%rsp), %rdx
movq %r12, 0x20(%r14)
cmpl %ebp, %edx
jbe 0xb567
movl %ebp, 0xc(%r14)
movl %ebp, %r13d
movq %rdx, %rbp
negq %rbp
leaq 0x1(%r13), %r15
movq %r13, %r12
shlq $0x4, %r12
movq 0x10(%r14), %rcx
cmpl $0x0, 0x8(%rcx,%r12)
je 0xb533
addq %r12, %rcx
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0xbc07
leaq (%r15,%rbp), %rax
incq %rax
incq %r15
addq $0x10, %r12
cmpq $0x1, %rax
jne 0xb516
movq 0x10(%r14), %rsi
movq 0x8(%rsp), %rdx
shlq $0x4, %rdx
shlq $0x4, %r13
movq %rbx, %rdi
movq %r13, %rcx
callq 0x11d07
movq %rax, 0x10(%r14)
movl 0x4(%rsp), %eax
testl %eax, %eax
jle 0xb5dd
movl %eax, %r12d
leaq 0x1(%r12), %r13
movq %r12, %rax
shlq $0x5, %rax
movq 0x10(%rsp), %rcx
leaq (%rax,%rcx), %r15
addq $-0x10, %r15
cmpl $0x0, -0x8(%r15)
je 0xb5ad
leaq -0x10(%r15), %rbp
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0xbb5e
movdqu (%rbp), %xmm0
movdqu %xmm0, (%rax)
decq %r13
addq $-0x20, %r15
cmpq $0x1, %r13
ja 0xb58b
cmpl $0x0, 0x4(%rsp)
jle 0xb5dd
shlq $0x5, %r12
movq 0x18(%rbx), %rbx
movq 0x8(%rbx), %rdi
movq 0x10(%rsp), %rsi
movq %r12, %rdx
xorl %ecx, %ecx
callq *(%rbx)
subq %r12, 0x18(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x294c1(%rip), %rsi     # 0x34ab4
movq %rbx, %rdi
xorl %eax, %eax
callq 0x11359