Disassembly: 
  L1: 8b ff ?? mov edi, edi
   55 ?? push ebp
   8b ec ?? mov ebp, esp
   56 ?? push esi
   8b 75 08 ?? mov esi, dword ss:[ebp + 8]
   57 ?? push edi
   33 ff ?? xor edi, edi
   3b f7 ?? cmp esi, edi
   75 1d ?? jne basic block L5
  
  L2: e8 82 d7 ff ff ?? call function 0x0040c7ec
  
  L3: 57 ?? push edi
   57 ?? push edi
   57 ?? push edi
   57 ?? push edi
   57 ?? push edi
   c7 00 16 00 00 00 ?? mov dword ds:[eax], 0x00000016<22>
   e8 66 78 ff ff ?? call function 0x004068e0
  
  L4: 83 c4 14 ?? add esp, 0x14<20>
   e9 f7 00 00 00 ?? jmp basic block L34
  
  L5: 8b 46 0c ?? mov eax, dword ds:[esi + 12]
   a8 83 ?? test al, 0x83<131,-125>
   0f 84 ec 00 00 00 ?? je basic block L34
  
  L6: a8 40 ?? test al, 0x40<64>
   0f 85 e4 00 00 00 ?? jne basic block L34
  
  L7: a8 02 ?? test al, 2
   74 0b ?? je basic block L9
  
  L8: 83 c8 20 ?? or eax, 0x20<32>
   89 46 0c ?? mov dword ds:[esi + 12], eax
   e9 d5 00 00 00 ?? jmp basic block L34
  
  L9: 83 c8 01 ?? or eax, 1
   89 46 0c ?? mov dword ds:[esi + 12], eax
   a9 0c 01 00 00 ?? test eax, 0x0000010c<268>
   75 09 ?? jne basic block L12
  
  L10: 56 ?? push esi
   e8 5f 02 00 00 ?? call function 0x0040f316
  
  L11: 59 ?? pop ecx
   eb 05 ?? jmp basic block L13
  
  L12: 8b 46 08 ?? mov eax, dword ds:[esi + 8]
   89 06 ?? mov dword ds:[esi], eax
  
  L13: ff 76 18 ?? push dword ds:[esi + 0x18<24>]
   ff 76 08 ?? push dword ds:[esi + 8]
   56 ?? push esi
   e8 b5 00 00 00 ?? call function 0x0040f180
  
  L14: 59 ?? pop ecx
   50 ?? push eax
   e8 d0 e4 00 00 ?? call function 0x0041d5a2
  
  L15: 83 c4 0c ?? add esp, 12
   89 46 04 ?? mov dword ds:[esi + 4], eax
   3b c7 ?? cmp eax, edi
   0f 84 89 00 00 00 ?? je basic block L33
  
  L16: 83 f8 ff ?? cmp eax, 0xff<255,-1>
   0f 84 80 00 00 00 ?? je basic block L33
  
  L17: f6 46 0c 82 ?? test byte ds:[esi + 12], 0x82<130,-126>
   75 4f ?? jne basic block L28
  
  L18: 56 ?? push esi
   e8 8b 00 00 00 ?? call function 0x0040f180
  
  L19: 59 ?? pop ecx
   83 f8 ff ?? cmp eax, 0xff<255,-1>
   74 2e ?? je basic block L25
  
  L20: 56 ?? push esi
   e8 7f 00 00 00 ?? call function 0x0040f180
  
  L21: 59 ?? pop ecx
   83 f8 fe ?? cmp eax, 0xfe<254,-2>
   74 22 ?? je basic block L25
  
  L22: 56 ?? push esi
   e8 73 00 00 00 ?? call function 0x0040f180
  
  L23: c1 f8 05 ?? sar eax, 5
   56 ?? push esi
   8d 3c 85 c0 66 43 00 ?? lea edi, ds:[0x004366c0 + eax * 4]
   e8 63 00 00 00 ?? call function 0x0040f180
  
  L24: 83 e0 1f ?? and eax, 0x1f<31>
   59 ?? pop ecx
   c1 e0 06 ?? shl eax, 6
   03 07 ?? add eax, dword ds:[edi]
   59 ?? pop ecx
   eb 05 ?? jmp basic block L26
  
  L25: b8 a8 49 43 00 ?? mov eax, 0x004349a8
  
  L26: 8a 40 04 ?? mov al, byte ds:[eax + 4]
   24 82 ?? and al, 0x82<130,-126>
   3c 82 ?? cmp al, 0x82<130,-126>
   75 07 ?? jne basic block L28
  
  L27: 81 4e 0c 00 20 00 00 ?? or dword ds:[esi + 12], 0x00002000<8192>
  
  L28: 81 7e 18 00 02 00 00 ?? cmp dword ds:[esi + 0x18<24>], 0x00000200<512>
   75 15 ?? jne basic block L32
  
  L29: 8b 46 0c ?? mov eax, dword ds:[esi + 12]
   a8 08 ?? test al, 8
   74 0e ?? je basic block L32
  
  L30: a9 00 04 00 00 ?? test eax, 0x00000400<1024>
   75 07 ?? jne basic block L32
  
  L31: c7 46 18 00 10 00 00 ?? mov dword ds:[esi + 0x18<24>], 0x00001000<4096>
  
  L32: 8b 0e ?? mov ecx, dword ds:[esi]
   ff 4e 04 ?? dec dword ds:[esi + 4]
   0f b6 01 ?? movzx eax, byte ds:[ecx]
   41 ?? inc ecx
   89 0e ?? mov dword ds:[esi], ecx
   eb 13 ?? jmp basic block L35
  
  L33: f7 d8 ?? neg eax
   1b c0 ?? sbb eax, eax
   83 e0 10 ?? and eax, 0x10<16>
   83 c0 10 ?? add eax, 0x10<16>
   09 46 0c ?? or dword ds:[esi + 12], eax
   89 7e 04 ?? mov dword ds:[esi + 4], edi
  
  L34: 83 c8 ff ?? or eax, 0xff<255,-1>
  
  L35: 5f ?? pop edi
   5e ?? pop esi
   5d ?? pop ebp
   c3 ?? ret
  
  