// File: /workspace/github_cpp_makefile_star2_O3/attractivechaos[P]udb2/stb/./stb.h
// Function: stb_rand
unsigned long stb_rand()
{
   unsigned long * b = stb__mt_buffer;
   int idx = stb__mt_index;
   unsigned long s,r;
   int i;
	
   if (idx >= STB__MT_LEN*sizeof(unsigned long)) {
      if (idx > STB__MT_LEN*sizeof(unsigned long))
         stb_srand(0);
      idx = 0;
      i = 0;
      for (; i < STB__MT_IB; i++) {
         s = STB__TWIST(b, i, i+1);
         b[i] = b[i + STB__MT_IA] ^ (s >> 1) ^ STB__MAGIC(s);
      }
      for (; i < STB__MT_LEN-1; i++) {
         s = STB__TWIST(b, i, i+1);
         b[i] = b[i - STB__MT_IB] ^ (s >> 1) ^ STB__MAGIC(s);
      }
      
      s = STB__TWIST(b, STB__MT_LEN-1, 0);
      b[STB__MT_LEN-1] = b[STB__MT_IA-1] ^ (s >> 1) ^ STB__MAGIC(s);
   }
   stb__mt_index = idx + sizeof(unsigned long);
   
   r = *(unsigned long *)((unsigned char *)b + idx);
   
   r ^= (r >> 11);
   r ^= (r << 7) & 0x9D2C5680;
   r ^= (r << 15) & 0xEFC60000;
   r ^= (r >> 18);
   
   return r;
}

// Assembly:
movl 0xdee1(%rip), %eax      # 0x1a22c
cmpq $0x137f, %rax           # imm = 0x137F
jbe 0xc4b1
cmpl $0x1380, %eax           # imm = 0x1380
je 0xc39f
xorl %eax, %eax
leaq 0x126e9(%rip), %rcx     # 0x1ea50
xorl %edx, %edx
imulq $0x7ff8a3ed, %rdx, %rdx # imm = 0x7FF8A3ED
addq $0x2aa01d31, %rdx       # imm = 0x2AA01D31
movq %rdx, %rsi
shrq $0x10, %rsi
movq %rdx, %rdi
shlq $0x10, %rdi
addq %rsi, %rdi
xorq $0x31415926, %rdi       # imm = 0x31415926
movq %rdi, (%rax,%rcx)
addq $0x8, %rax
cmpq $0x1380, %rax           # imm = 0x1380
jne 0xc369
movl $0x9908b0df, %eax       # imm = 0x9908B0DF
movq 0x126a5(%rip), %rsi     # 0x1ea50
xorl %edx, %edx
leaq 0x1269c(%rip), %rcx     # 0x1ea50
movq 0x8(%rcx,%rdx,8), %rdi
movl $0x9908b0df, %r8d       # imm = 0x9908B0DF
testb $0x1, %dil
jne 0xc3c8
xorl %r8d, %r8d
andl $0x80000000, %esi       # imm = 0x80000000
movl %edi, %r9d
andl $0x7ffffffe, %r9d       # imm = 0x7FFFFFFE
orl %esi, %r9d
shrl %r9d
xorq 0xc68(%rcx,%rdx,8), %r8
xorq %r9, %r8
movq %r8, (%rcx,%rdx,8)
leaq 0x1(%rdx), %r8
movq %rdi, %rsi
movq %r8, %rdx
cmpq $0xe3, %r8
jne 0xc3b4
movq 0x12d60(%rip), %xmm0    # 0x1f168
pshufd $0x44, %xmm0, %xmm3     # xmm3 = xmm0[0,1,0,1]
xorl %edx, %edx
movaps 0x5d2a(%rip), %xmm0     # 0x12140
movaps 0x5d33(%rip), %xmm1     # 0x12150
movdqa 0x5d3b(%rip), %xmm2     # 0x12160
movaps 0x720(%rcx,%rdx,8), %xmm4
shufps $0x4e, %xmm4, %xmm3     # xmm3 = xmm3[2,3],xmm4[0,1]
andps %xmm0, %xmm3
movaps %xmm4, %xmm5
andps %xmm1, %xmm5
orps %xmm3, %xmm5
psrlq $0x1, %xmm5
movaps %xmm4, %xmm3
pslld $0x1f, %xmm4
psrad $0x1f, %xmm4
pand %xmm2, %xmm4
pxor (%rcx,%rdx,8), %xmm4
pxor %xmm5, %xmm4
movdqu %xmm4, 0x718(%rcx,%rdx,8)
addq $0x2, %rdx
cmpq $0x18c, %rdx            # imm = 0x18C
jne 0xc425
movl $0x80000000, %edx       # imm = 0x80000000
andl 0x1394b(%rip), %edx     # 0x1fdc8
movq 0x125cc(%rip), %rcx     # 0x1ea50
movl %ecx, %esi
andl $0x7ffffffe, %esi       # imm = 0x7FFFFFFE
orl %edx, %esi
shrl %esi
xorl %edx, %edx
testb $0x1, %cl
cmovneq %rax, %rdx
xorq 0x13210(%rip), %rdx     # 0x1f6b0
xorq %rsi, %rdx
movq %rdx, 0x1391e(%rip)     # 0x1fdc8
movl $0x8, %eax
jmp 0xc4bf
leaq 0x12598(%rip), %rcx     # 0x1ea50
movq (%rax,%rcx), %rcx
addl $0x8, %eax
movl %eax, 0xdd67(%rip)      # 0x1a22c
movq %rcx, %rax
shrq $0xb, %rax
xorq %rcx, %rax
movl %eax, %ecx
shll $0x7, %ecx
andl $0x9d2c5680, %ecx       # imm = 0x9D2C5680
xorq %rax, %rcx
movl %ecx, %edx
shll $0xf, %edx
andl $0xefc60000, %edx       # imm = 0xEFC60000
xorq %rcx, %rdx
movq %rdx, %rax
shrq $0x12, %rax
xorq %rdx, %rax
retq