40635b:	8b c8                	mov    %eax,%ecx
40635d:	57                   	push   %edi
40635e:	8b 7e 20             	mov    0x20(%esi),%edi
406361:	8b c7                	mov    %edi,%eax
406363:	c1 e8 04             	shr    $0x4,%eax
406366:	a8 01                	test   $0x1,%al
406368:	74 17                	je     0x406381
40636a:	85 d2                	test   %edx,%edx
40636c:	7f 13                	jg     0x406381
40636e:	7c 04                	jl     0x406374
406370:	85 c9                	test   %ecx,%ecx
406372:	73 0d                	jae    0x406381
406374:	f7 d9                	neg    %ecx
406376:	83 d2 00             	adc    $0x0,%edx
406379:	f7 da                	neg    %edx
40637b:	83 cf 40             	or     $0x40,%edi
40637e:	89 7e 20             	mov    %edi,0x20(%esi)
406381:	83 7e 28 00          	cmpl   $0x0,0x28(%esi)
406385:	5f                   	pop    %edi
406386:	7d 09                	jge    0x406391
406388:	c7 46 28 01 00 00 00 	movl   $0x1,0x28(%esi)
40638f:	eb 11                	jmp    0x4063a2
406391:	83 66 20 f7          	andl   $0xfffffff7,0x20(%esi)
406395:	b8 00 02 00 00       	mov    $0x200,%eax
40639a:	39 46 28             	cmp    %eax,0x28(%esi)
40639d:	7e 03                	jle    0x4063a2
40639f:	89 46 28             	mov    %eax,0x28(%esi)
4063a2:	8b c1                	mov    %ecx,%eax
4063a4:	0b c2                	or     %edx,%eax
4063a6:	75 04                	jne    0x4063ac
4063a8:	83 66 20 df          	andl   $0xffffffdf,0x20(%esi)
4063ac:	ff 75 0c             	push   0xc(%ebp)
4063af:	ff 75 08             	push   0x8(%ebp)
4063b2:	83 fb 08             	cmp    $0x8,%ebx
4063b5:	75 0b                	jne    0x4063c2
4063b7:	52                   	push   %edx
4063b8:	51                   	push   %ecx
4063b9:	8b ce                	mov    %esi,%ecx
4063bb:	e8 7b f1 ff ff       	call   0x40553b
4063c0:	eb 08                	jmp    0x4063ca
4063c2:	51                   	push   %ecx
4063c3:	8b ce                	mov    %esi,%ecx
4063c5:	e8 fc f0 ff ff       	call   0x4054c6
4063ca:	8b 46 20             	mov    0x20(%esi),%eax
4063cd:	c1 e8 07             	shr    $0x7,%eax
4063d0:	a8 01                	test   $0x1,%al
4063d2:	74 1a                	je     0x4063ee
4063d4:	83 7e 38 00          	cmpl   $0x0,0x38(%esi)
4063d8:	74 08                	je     0x4063e2
4063da:	8b 46 34             	mov    0x34(%esi),%eax
4063dd:	80 38 30             	cmpb   $0x30,(%eax)
4063e0:	74 0c                	je     0x4063ee
4063e2:	ff 4e 34             	decl   0x34(%esi)
4063e5:	8b 4e 34             	mov    0x34(%esi),%ecx
4063e8:	c6 01 30             	movb   $0x30,(%ecx)
4063eb:	ff 46 38             	incl   0x38(%esi)
4063ee:	b0 01                	mov    $0x1,%al
4063f0:	5e                   	pop    %esi
4063f1:	5b                   	pop    %ebx
4063f2:	5d                   	pop    %ebp
4063f3:	c2 08 00             	ret    $0x8
4063f6:	8b ff                	mov    %edi,%edi
4063f8:	56                   	push   %esi
4063f9:	8b f1                	mov    %ecx,%esi
4063fb:	57                   	push   %edi
4063fc:	83 46 14 04          	addl   $0x4,0x14(%esi)
406400:	8b 46 14             	mov    0x14(%esi),%eax
406403:	8b 78 fc             	mov    -0x4(%eax),%edi
406406:	e8 47 53 00 00       	call   0x40b752
40640b:	85 c0                	test   %eax,%eax
40640d:	75 14                	jne    0x406423
40640f:	e8 f3 18 00 00       	call   0x407d07
406414:	c7 00 16 00 00 00    	movl   $0x16,(%eax)
40641a:	e8 0f 18 00 00       	call   0x407c2e
40641f:	32 c0                	xor    %al,%al
406421:	eb 44                	jmp    0x406467
406423:	ff 76 2c             	push   0x2c(%esi)
406426:	e8 b8 fb ff ff       	call   0x405fe3
40642b:	59                   	pop    %ecx
40642c:	83 e8 01             	sub    $0x1,%eax
40642f:	74 2b                	je     0x40645c
406431:	83 e8 01             	sub    $0x1,%eax
406434:	74 1d                	je     0x406453
406436:	48                   	dec    %eax
406437:	83 e8 01             	sub    $0x1,%eax
40643a:	74 10                	je     0x40644c
40643c:	83 e8 04             	sub    $0x4,%eax
40643f:	75 ce                	jne    0x40640f
406441:	8b 46 18             	mov    0x18(%esi),%eax
406444:	99                   	cltd
406445:	89 07                	mov    %eax,(%edi)
406447:	89 57 04             	mov    %edx,0x4(%edi)
40644a:	eb 15                	jmp    0x406461
40644c:	8b 46 18             	mov    0x18(%esi),%eax
40644f:	89 07                	mov    %eax,(%edi)
406451:	eb 0e                	jmp    0x406461
406453:	66 8b 46 18          	mov    0x18(%esi),%ax
406457:	66 89 07             	mov    %ax,(%edi)
40645a:	eb 05                	jmp    0x406461
40645c:	8a 46 18             	mov    0x18(%esi),%al
40645f:	88 07                	mov    %al,(%edi)
406461:	c6 46 30 01          	movb   $0x1,0x30(%esi)
406465:	b0 01                	mov    $0x1,%al
406467:	5f                   	pop    %edi
406468:	5e                   	pop    %esi
406469:	c3                   	ret
40646a:	8b 51 20             	mov    0x20(%ecx),%edx
40646d:	8b c2                	mov    %edx,%eax
40646f:	c1 e8 05             	shr    $0x5,%eax
406472:	a8 01                	test   $0x1,%al
406474:	74 09                	je     0x40647f
406476:	81 ca 80 00 00 00    	or     $0x80,%edx
40647c:	89 51 20             	mov    %edx,0x20(%ecx)
40647f:	6a 00                	push   $0x0
406481:	6a 08                	push   $0x8
406483:	e8 24 fe ff ff       	call   0x4062ac
406488:	c3                   	ret
406489:	6a 01                	push   $0x1
40648b:	6a 10                	push   $0x10
40648d:	c7 41 28 08 00 00 00 	movl   $0x8,0x28(%ecx)
406494:	c7 41 2c 0a 00 00 00 	movl   $0xa,0x2c(%ecx)
40649b:	e8 0c fe ff ff       	call   0x4062ac
4064a0:	c3                   	ret
4064a1:	8b ff                	mov    %edi,%edi
4064a3:	53                   	push   %ebx
4064a4:	56                   	push   %esi
4064a5:	8b f1                	mov    %ecx,%esi
4064a7:	57                   	push   %edi
4064a8:	83 46 14 04          	addl   $0x4,0x14(%esi)
4064ac:	8b 46 14             	mov    0x14(%esi),%eax
4064af:	8b 7e 28             	mov    0x28(%esi),%edi
4064b2:	8b 58 fc             	mov    -0x4(%eax),%ebx
4064b5:	89 5e 34             	mov    %ebx,0x34(%esi)
4064b8:	83 ff ff             	cmp    $0xffffffff,%edi
4064bb:	75 05                	jne    0x4064c2
4064bd:	bf ff ff ff 7f       	mov    $0x7fffffff,%edi
4064c2:	ff 76 2c             	push   0x2c(%esi)
4064c5:	0f b7 46 32          	movzwl 0x32(%esi),%eax
4064c9:	50                   	push   %eax
4064ca:	ff 76 04             	push   0x4(%esi)
4064cd:	ff 36                	push   (%esi)
4064cf:	e8 85 ef ff ff       	call   0x405459
4064d4:	83 c4 10             	add    $0x10,%esp
4064d7:	84 c0                	test   %al,%al
4064d9:	74 1c                	je     0x4064f7
4064db:	85 db                	test   %ebx,%ebx
4064dd:	75 07                	jne    0x4064e6
4064df:	c7 46 34 ec bc 41 00 	movl   $0x41bcec,0x34(%esi)
4064e6:	57                   	push   %edi
4064e7:	ff 76 34             	push   0x34(%esi)
4064ea:	c6 46 3c 01          	movb   $0x1,0x3c(%esi)
4064ee:	e8 d7 18 00 00       	call   0x407dca
4064f3:	59                   	pop    %ecx
4064f4:	59                   	pop    %ecx
4064f5:	eb 15                	jmp    0x40650c
4064f7:	85 db                	test   %ebx,%ebx
4064f9:	75 07                	jne    0x406502
4064fb:	c7 46 34 e4 bc 41 00 	movl   $0x41bce4,0x34(%esi)
406502:	6a 00                	push   $0x0
406504:	57                   	push   %edi
406505:	8b ce                	mov    %esi,%ecx
406507:	e8 09 00 00 00       	call   0x406515
40650c:	5f                   	pop    %edi
40650d:	89 46 38             	mov    %eax,0x38(%esi)
406510:	b0 01                	mov    $0x1,%al
406512:	5e                   	pop    %esi
406513:	5b                   	pop    %ebx
406514:	c3                   	ret
406515:	8b ff                	mov    %edi,%edi
406517:	55                   	push   %ebp
406518:	8b ec                	mov    %esp,%ebp
40651a:	56                   	push   %esi
40651b:	57                   	push   %edi
40651c:	8b f9                	mov    %ecx,%edi
40651e:	33 f6                	xor    %esi,%esi
406520:	8b 57 34             	mov    0x34(%edi),%edx
406523:	39 75 08             	cmp    %esi,0x8(%ebp)
406526:	7e 25                	jle    0x40654d
406528:	53                   	push   %ebx
406529:	8a 02                	mov    (%edx),%al
40652b:	84 c0                	test   %al,%al
40652d:	74 1d                	je     0x40654c
40652f:	0f b6 c8             	movzbl %al,%ecx
406532:	bb 00 80 00 00       	mov    $0x8000,%ebx
406537:	8b 47 08             	mov    0x8(%edi),%eax
40653a:	8b 00                	mov    (%eax),%eax
40653c:	8b 00                	mov    (%eax),%eax
40653e:	66 85 1c 48          	test   %bx,(%eax,%ecx,2)
406542:	74 01                	je     0x406545
406544:	42                   	inc    %edx
406545:	42                   	inc    %edx
406546:	46                   	inc    %esi
406547:	3b 75 08             	cmp    0x8(%ebp),%esi
40654a:	7c dd                	jl     0x406529
40654c:	5b                   	pop    %ebx
40654d:	5f                   	pop    %edi
40654e:	8b c6                	mov    %esi,%eax
406550:	5e                   	pop    %esi
406551:	5d                   	pop    %ebp
406552:	c2 08 00             	ret    $0x8
406555:	83 79 1c 00          	cmpl   $0x0,0x1c(%ecx)
406559:	74 19                	je     0x406574
40655b:	83 79 1c 07          	cmpl   $0x7,0x1c(%ecx)
40655f:	74 13                	je     0x406574
406561:	e8 a1 17 00 00       	call   0x407d07
406566:	c7 00 16 00 00 00    	movl   $0x16,(%eax)
40656c:	e8 bd 16 00 00       	call   0x407c2e
406571:	32 c0                	xor    %al,%al
406573:	c3                   	ret
406574:	b0 01                	mov    $0x1,%al
406576:	c3                   	ret
406577:	8b ff                	mov    %edi,%edi
406579:	55                   	push   %ebp
40657a:	8b ec                	mov    %esp,%ebp
40657c:	8b d1                	mov    %ecx,%edx
40657e:	8b 0a                	mov    (%edx),%ecx
406580:	8b 41 08             	mov    0x8(%ecx),%eax
406583:	3b 41 04             	cmp    0x4(%ecx),%eax
406586:	8b 45 0c             	mov    0xc(%ebp),%eax
406589:	75 14                	jne    0x40659f
40658b:	80 79 0c 00          	cmpb   $0x0,0xc(%ecx)
40658f:	74 04                	je     0x406595
406591:	ff 00                	incl   (%eax)
406593:	eb 03                	jmp    0x406598
406595:	83 08 ff             	orl    $0xffffffff,(%eax)
406598:	8b 02                	mov    (%edx),%eax
40659a:	8a 40 0c             	mov    0xc(%eax),%al
40659d:	eb 19                	jmp    0x4065b8
40659f:	ff 00                	incl   (%eax)
4065a1:	8b 02                	mov    (%edx),%eax
4065a3:	ff 40 08             	incl   0x8(%eax)
4065a6:	8b 02                	mov    (%edx),%eax
4065a8:	8b 08                	mov    (%eax),%ecx
4065aa:	66 8b 45 08          	mov    0x8(%ebp),%ax
4065ae:	66 89 01             	mov    %ax,(%ecx)
4065b1:	8b 02                	mov    (%edx),%eax
4065b3:	83 00 02             	addl   $0x2,(%eax)
4065b6:	b0 01                	mov    $0x1,%al
4065b8:	5d                   	pop    %ebp
4065b9:	c2 08 00             	ret    $0x8
4065bc:	8b ff                	mov    %edi,%edi
4065be:	55                   	push   %ebp
4065bf:	8b ec                	mov    %esp,%ebp
4065c1:	51                   	push   %ecx
4065c2:	51                   	push   %ecx
4065c3:	53                   	push   %ebx
4065c4:	56                   	push   %esi
4065c5:	8b f1                	mov    %ecx,%esi
4065c7:	57                   	push   %edi
4065c8:	80 7e 3c 00          	cmpb   $0x0,0x3c(%esi)
4065cc:	75 56                	jne    0x406624
4065ce:	8b 46 38             	mov    0x38(%esi),%eax
4065d1:	85 c0                	test   %eax,%eax
4065d3:	7e 4f                	jle    0x406624
4065d5:	8b 5e 34             	mov    0x34(%esi),%ebx
4065d8:	33 ff                	xor    %edi,%edi
4065da:	85 c0                	test   %eax,%eax
4065dc:	74 5e                	je     0x40663c
4065de:	33 c0                	xor    %eax,%eax
4065e0:	66 89 45 fc          	mov    %ax,-0x4(%ebp)
4065e4:	8b 46 08             	mov    0x8(%esi),%eax
4065e7:	50                   	push   %eax
4065e8:	8b 00                	mov    (%eax),%eax
4065ea:	ff 70 04             	push   0x4(%eax)
4065ed:	8d 45 fc             	lea    -0x4(%ebp),%eax
4065f0:	53                   	push   %ebx
4065f1:	50                   	push   %eax
4065f2:	e8 a5 3f 00 00       	call   0x40a59c
4065f7:	83 c4 10             	add    $0x10,%esp
4065fa:	89 45 f8             	mov    %eax,-0x8(%ebp)
4065fd:	85 c0                	test   %eax,%eax
4065ff:	7e 1d                	jle    0x40661e
406601:	8d 4e 18             	lea    0x18(%esi),%ecx
406604:	51                   	push   %ecx
406605:	ff 75 fc             	push   -0x4(%ebp)
406608:	8d 8e 48 04 00 00    	lea    0x448(%esi),%ecx
40660e:	e8 64 ff ff ff       	call   0x406577
406613:	03 5d f8             	add    -0x8(%ebp),%ebx
406616:	47                   	inc    %edi
406617:	3b 7e 38             	cmp    0x38(%esi),%edi
40661a:	75 c2                	jne    0x4065de
40661c:	eb 1e                	jmp    0x40663c
40661e:	83 4e 18 ff          	orl    $0xffffffff,0x18(%esi)
406622:	eb 18                	jmp    0x40663c
406624:	ff 76 0c             	push   0xc(%esi)
406627:	8d 46 18             	lea    0x18(%esi),%eax
40662a:	50                   	push   %eax
40662b:	ff 76 38             	push   0x38(%esi)
40662e:	8d 8e 48 04 00 00    	lea    0x448(%esi),%ecx
406634:	ff 76 34             	push   0x34(%esi)
406637:	e8 0b 00 00 00       	call   0x406647
40663c:	5f                   	pop    %edi
40663d:	5e                   	pop    %esi
40663e:	b0 01                	mov    $0x1,%al
406640:	5b                   	pop    %ebx
406641:	8b e5                	mov    %ebp,%esp
406643:	5d                   	pop    %ebp
406644:	c2 04 00             	ret    $0x4
406647:	8b ff                	mov    %edi,%edi
406649:	55                   	push   %ebp
40664a:	8b ec                	mov    %esp,%ebp
40664c:	51                   	push   %ecx
40664d:	51                   	push   %ecx
40664e:	53                   	push   %ebx
40664f:	8b 5d 14             	mov    0x14(%ebp),%ebx
406652:	8b c1                	mov    %ecx,%eax
406654:	57                   	push   %edi
406655:	89 45 f8             	mov    %eax,-0x8(%ebp)
406658:	8b 0b                	mov    (%ebx),%ecx
40665a:	83 23 00             	andl   $0x0,(%ebx)
40665d:	8b 10                	mov    (%eax),%edx
40665f:	89 4d fc             	mov    %ecx,-0x4(%ebp)
406662:	8b 7a 04             	mov    0x4(%edx),%edi
406665:	39 7a 08             	cmp    %edi,0x8(%edx)
406668:	75 18                	jne    0x406682
40666a:	80 7a 0c 00          	cmpb   $0x0,0xc(%edx)
40666e:	74 0a                	je     0x40667a
406670:	8b 4d 10             	mov    0x10(%ebp),%ecx
406673:	8b 45 0c             	mov    0xc(%ebp),%eax
406676:	01 01                	add    %eax,(%ecx)
406678:	eb 51                	jmp    0x4066cb
40667a:	8b 45 10             	mov    0x10(%ebp),%eax
40667d:	83 08 ff             	orl    $0xffffffff,(%eax)
406680:	eb 4c                	jmp    0x4066ce
406682:	2b 7a 08             	sub    0x8(%edx),%edi
406685:	8b 45 0c             	mov    0xc(%ebp),%eax
406688:	3b f8                	cmp    %eax,%edi
40668a:	72 02                	jb     0x40668e
40668c:	8b f8                	mov    %eax,%edi
40668e:	56                   	push   %esi
40668f:	8d 34 3f             	lea    (%edi,%edi,1),%esi
406692:	56                   	push   %esi
406693:	ff 75 08             	push   0x8(%ebp)
406696:	ff 32                	push   (%edx)
406698:	e8 43 1e 01 00       	call   0x4184e0
40669d:	8b 4d f8             	mov    -0x8(%ebp),%ecx
4066a0:	83 c4 0c             	add    $0xc,%esp
4066a3:	8b 01                	mov    (%ecx),%eax
4066a5:	01 30                	add    %esi,(%eax)
4066a7:	8b 01                	mov    (%ecx),%eax
4066a9:	5e                   	pop    %esi
4066aa:	01 78 08             	add    %edi,0x8(%eax)
4066ad:	8b 01                	mov    (%ecx),%eax
4066af:	80 78 0c 00          	cmpb   $0x0,0xc(%eax)
4066b3:	8b 45 10             	mov    0x10(%ebp),%eax
4066b6:	74 07                	je     0x4066bf
4066b8:	8b 4d 0c             	mov    0xc(%ebp),%ecx
4066bb:	01 08                	add    %ecx,(%eax)
4066bd:	eb 0c                	jmp    0x4066cb
4066bf:	3b 7d 0c             	cmp    0xc(%ebp),%edi