40a2a4:	e8 ef fd ff ff       	call   0x40a098
40a2a9:	84 c0                	test   %al,%al
40a2ab:	74 06                	je     0x40a2b3
40a2ad:	db 2c 24             	fldt   (%esp)
40a2b0:	d9 1e                	fstps  (%esi)
40a2b2:	9b                   	fwait
40a2b3:	83 c4 0c             	add    $0xc,%esp
40a2b6:	5e                   	pop    %esi
40a2b7:	5b                   	pop    %ebx
40a2b8:	c3                   	ret
40a2b9:	8d 40 00             	lea    0x0(%eax),%eax
40a2bc:	53                   	push   %ebx
40a2bd:	56                   	push   %esi
40a2be:	8b f2                	mov    %edx,%esi
40a2c0:	8b d8                	mov    %eax,%ebx
40a2c2:	8b c3                	mov    %ebx,%eax
40a2c4:	e8 43 a9 ff ff       	call   0x404c0c
40a2c9:	8b d6                	mov    %esi,%edx
40a2cb:	b1 01                	mov    $0x1,%cl
40a2cd:	e8 c6 fd ff ff       	call   0x40a098
40a2d2:	5e                   	pop    %esi
40a2d3:	5b                   	pop    %ebx
40a2d4:	c3                   	ret
40a2d5:	8d 40 00             	lea    0x0(%eax),%eax
40a2d8:	55                   	push   %ebp
40a2d9:	8b ec                	mov    %esp,%ebp
40a2db:	53                   	push   %ebx
40a2dc:	31 db                	xor    %ebx,%ebx
40a2de:	89 c1                	mov    %eax,%ecx
40a2e0:	dd 45 08             	fldl   0x8(%ebp)
40a2e3:	d8 8b 78 b8 49 00    	fmuls  0x49b878(%ebx)
40a2e9:	83 ec 08             	sub    $0x8,%esp
40a2ec:	df 3c 24             	fistpll (%esp)
40a2ef:	9b                   	fwait
40a2f0:	58                   	pop    %eax
40a2f1:	5a                   	pop    %edx
40a2f2:	09 d2                	or     %edx,%edx
40a2f4:	79 11                	jns    0x40a307
40a2f6:	f7 da                	neg    %edx
40a2f8:	f7 d8                	neg    %eax
40a2fa:	83 da 00             	sbb    $0x0,%edx
40a2fd:	f7 b3 7c b8 49 00    	divl   0x49b87c(%ebx)
40a303:	f7 d8                	neg    %eax
40a305:	eb 06                	jmp    0x40a30d
40a307:	f7 b3 7c b8 49 00    	divl   0x49b87c(%ebx)
40a30d:	05 5a 95 0a 00       	add    $0xa955a,%eax
40a312:	89 11                	mov    %edx,(%ecx)
40a314:	89 41 04             	mov    %eax,0x4(%ecx)
40a317:	5b                   	pop    %ebx
40a318:	5d                   	pop    %ebp
40a319:	c2 08 00             	ret    $0x8
40a31c:	55                   	push   %ebp
40a31d:	8b ec                	mov    %esp,%ebp
40a31f:	83 c4 f8             	add    $0xfffffff8,%esp
40a322:	56                   	push   %esi
40a323:	8b 75 0c             	mov    0xc(%ebp),%esi
40a326:	c6 45 ff 00          	movb   $0x0,-0x1(%ebp)
40a32a:	66 83 f8 18          	cmp    $0x18,%ax
40a32e:	73 4d                	jae    0x40a37d
40a330:	66 83 fa 3c          	cmp    $0x3c,%dx
40a334:	73 47                	jae    0x40a37d
40a336:	66 83 f9 3c          	cmp    $0x3c,%cx
40a33a:	73 41                	jae    0x40a37d
40a33c:	66 81 fe e8 03       	cmp    $0x3e8,%si
40a341:	73 3a                	jae    0x40a37d
40a343:	0f b7 c0             	movzwl %ax,%eax
40a346:	69 c0 80 ee 36 00    	imul   $0x36ee80,%eax,%eax
40a34c:	0f b7 d2             	movzwl %dx,%edx
40a34f:	69 d2 60 ea 00 00    	imul   $0xea60,%edx,%edx
40a355:	03 c2                	add    %edx,%eax
40a357:	0f b7 d1             	movzwl %cx,%edx
40a35a:	69 d2 e8 03 00 00    	imul   $0x3e8,%edx,%edx
40a360:	03 c2                	add    %edx,%eax
40a362:	0f b7 d6             	movzwl %si,%edx
40a365:	03 c2                	add    %edx,%eax
40a367:	89 45 f8             	mov    %eax,-0x8(%ebp)
40a36a:	db 45 f8             	fildl  -0x8(%ebp)
40a36d:	d8 35 88 a3 40 00    	fdivs  0x40a388
40a373:	8b 45 08             	mov    0x8(%ebp),%eax
40a376:	dd 18                	fstpl  (%eax)
40a378:	9b                   	fwait
40a379:	c6 45 ff 01          	movb   $0x1,-0x1(%ebp)
40a37d:	0f b6 45 ff          	movzbl -0x1(%ebp),%eax
40a381:	5e                   	pop    %esi
40a382:	59                   	pop    %ecx
40a383:	59                   	pop    %ecx
40a384:	5d                   	pop    %ebp
40a385:	c2 08 00             	ret    $0x8
40a388:	80 cb a4             	or     $0xa4,%bl
40a38b:	4c                   	dec    %esp
40a38c:	55                   	push   %ebp
40a38d:	8b ec                	mov    %esp,%ebp
40a38f:	83 c4 f4             	add    $0xfffffff4,%esp
40a392:	53                   	push   %ebx
40a393:	56                   	push   %esi
40a394:	57                   	push   %edi
40a395:	8b f9                	mov    %ecx,%edi
40a397:	8b f2                	mov    %edx,%esi
40a399:	8b d8                	mov    %eax,%ebx
40a39b:	8d 45 fc             	lea    -0x4(%ebp),%eax
40a39e:	50                   	push   %eax
40a39f:	ff 75 10             	push   0x10(%ebp)
40a3a2:	ff 75 0c             	push   0xc(%ebp)
40a3a5:	8d 45 f4             	lea    -0xc(%ebp),%eax
40a3a8:	e8 2b ff ff ff       	call   0x40a2d8
40a3ad:	8b 45 f4             	mov    -0xc(%ebp),%eax
40a3b0:	8d 4d fe             	lea    -0x2(%ebp),%ecx
40a3b3:	66 ba 60 ea          	mov    $0xea60,%dx
40a3b7:	e8 6c e3 ff ff       	call   0x408728
40a3bc:	56                   	push   %esi
40a3bd:	8b cb                	mov    %ebx,%ecx
40a3bf:	0f b7 45 fe          	movzwl -0x2(%ebp),%eax
40a3c3:	66 ba 3c 00          	mov    $0x3c,%dx
40a3c7:	e8 5c e3 ff ff       	call   0x408728
40a3cc:	8b 45 08             	mov    0x8(%ebp),%eax
40a3cf:	50                   	push   %eax
40a3d0:	8b cf                	mov    %edi,%ecx
40a3d2:	0f b7 45 fc          	movzwl -0x4(%ebp),%eax
40a3d6:	66 ba e8 03          	mov    $0x3e8,%dx
40a3da:	e8 49 e3 ff ff       	call   0x408728
40a3df:	5f                   	pop    %edi
40a3e0:	5e                   	pop    %esi
40a3e1:	5b                   	pop    %ebx
40a3e2:	8b e5                	mov    %ebp,%esp
40a3e4:	5d                   	pop    %ebp
40a3e5:	c2 0c 00             	ret    $0xc
40a3e8:	53                   	push   %ebx
40a3e9:	56                   	push   %esi
40a3ea:	8b c8                	mov    %eax,%ecx
40a3ec:	0f b7 c1             	movzwl %cx,%eax
40a3ef:	83 e0 03             	and    $0x3,%eax
40a3f2:	85 c0                	test   %eax,%eax
40a3f4:	75 21                	jne    0x40a417
40a3f6:	0f b7 d9             	movzwl %cx,%ebx
40a3f9:	8b c3                	mov    %ebx,%eax
40a3fb:	be 64 00 00 00       	mov    $0x64,%esi
40a400:	33 d2                	xor    %edx,%edx
40a402:	f7 f6                	div    %esi
40a404:	85 d2                	test   %edx,%edx
40a406:	75 14                	jne    0x40a41c
40a408:	8b c3                	mov    %ebx,%eax
40a40a:	b9 90 01 00 00       	mov    $0x190,%ecx
40a40f:	33 d2                	xor    %edx,%edx
40a411:	f7 f1                	div    %ecx
40a413:	85 d2                	test   %edx,%edx
40a415:	74 05                	je     0x40a41c
40a417:	33 c0                	xor    %eax,%eax
40a419:	5e                   	pop    %esi
40a41a:	5b                   	pop    %ebx
40a41b:	c3                   	ret
40a41c:	b0 01                	mov    $0x1,%al
40a41e:	5e                   	pop    %esi
40a41f:	5b                   	pop    %ebx
40a420:	c3                   	ret
40a421:	8d 40 00             	lea    0x0(%eax),%eax
40a424:	55                   	push   %ebp
40a425:	8b ec                	mov    %esp,%ebp
40a427:	83 c4 f8             	add    $0xfffffff8,%esp
40a42a:	53                   	push   %ebx
40a42b:	56                   	push   %esi
40a42c:	57                   	push   %edi
40a42d:	8b d9                	mov    %ecx,%ebx
40a42f:	8b fa                	mov    %edx,%edi
40a431:	66 89 45 fe          	mov    %ax,-0x2(%ebp)
40a435:	c6 45 fd 00          	movb   $0x0,-0x3(%ebp)
40a439:	0f b7 45 fe          	movzwl -0x2(%ebp),%eax
40a43d:	e8 a6 ff ff ff       	call   0x40a3e8
40a442:	83 e0 7f             	and    $0x7f,%eax
40a445:	8d 04 40             	lea    (%eax,%eax,2),%eax
40a448:	8d 34 c5 d8 b7 49 00 	lea    0x49b7d8(,%eax,8),%esi
40a44f:	66 83 7d fe 01       	cmpw   $0x1,-0x2(%ebp)
40a454:	0f 82 86 00 00 00    	jb     0x40a4e0
40a45a:	66 81 7d fe 0f 27    	cmpw   $0x270f,-0x2(%ebp)
40a460:	77 7e                	ja     0x40a4e0
40a462:	66 83 ff 01          	cmp    $0x1,%di
40a466:	72 78                	jb     0x40a4e0
40a468:	66 83 ff 0c          	cmp    $0xc,%di
40a46c:	77 72                	ja     0x40a4e0
40a46e:	66 83 fb 01          	cmp    $0x1,%bx
40a472:	72 6c                	jb     0x40a4e0
40a474:	0f b7 c7             	movzwl %di,%eax
40a477:	66 3b 5c 46 fe       	cmp    -0x2(%esi,%eax,2),%bx
40a47c:	77 62                	ja     0x40a4e0
40a47e:	0f b7 c7             	movzwl %di,%eax
40a481:	48                   	dec    %eax
40a482:	85 c0                	test   %eax,%eax
40a484:	7e 0e                	jle    0x40a494
40a486:	b9 01 00 00 00       	mov    $0x1,%ecx
40a48b:	66 03 5c 4e fe       	add    -0x2(%esi,%ecx,2),%bx
40a490:	41                   	inc    %ecx
40a491:	48                   	dec    %eax
40a492:	75 f7                	jne    0x40a48b
40a494:	0f b7 4d fe          	movzwl -0x2(%ebp),%ecx
40a498:	49                   	dec    %ecx
40a499:	8b c1                	mov    %ecx,%eax
40a49b:	be 64 00 00 00       	mov    $0x64,%esi
40a4a0:	99                   	cltd
40a4a1:	f7 fe                	idiv   %esi
40a4a3:	69 f1 6d 01 00 00    	imul   $0x16d,%ecx,%esi
40a4a9:	8b d1                	mov    %ecx,%edx
40a4ab:	85 d2                	test   %edx,%edx
40a4ad:	79 03                	jns    0x40a4b2
40a4af:	83 c2 03             	add    $0x3,%edx
40a4b2:	c1 fa 02             	sar    $0x2,%edx
40a4b5:	03 f2                	add    %edx,%esi
40a4b7:	2b f0                	sub    %eax,%esi
40a4b9:	8b c1                	mov    %ecx,%eax
40a4bb:	b9 90 01 00 00       	mov    $0x190,%ecx
40a4c0:	99                   	cltd
40a4c1:	f7 f9                	idiv   %ecx
40a4c3:	03 f0                	add    %eax,%esi
40a4c5:	0f b7 c3             	movzwl %bx,%eax
40a4c8:	03 f0                	add    %eax,%esi
40a4ca:	81 ee 5a 95 0a 00    	sub    $0xa955a,%esi
40a4d0:	89 75 f8             	mov    %esi,-0x8(%ebp)
40a4d3:	db 45 f8             	fildl  -0x8(%ebp)
40a4d6:	8b 45 08             	mov    0x8(%ebp),%eax
40a4d9:	dd 18                	fstpl  (%eax)
40a4db:	9b                   	fwait
40a4dc:	c6 45 fd 01          	movb   $0x1,-0x3(%ebp)
40a4e0:	0f b6 45 fd          	movzbl -0x3(%ebp),%eax
40a4e4:	5f                   	pop    %edi
40a4e5:	5e                   	pop    %esi
40a4e6:	5b                   	pop    %ebx
40a4e7:	59                   	pop    %ecx
40a4e8:	59                   	pop    %ecx
40a4e9:	5d                   	pop    %ebp
40a4ea:	c2 04 00             	ret    $0x4
40a4ed:	8d 40 00             	lea    0x0(%eax),%eax
40a4f0:	55                   	push   %ebp
40a4f1:	8b ec                	mov    %esp,%ebp
40a4f3:	83 c4 e8             	add    $0xffffffe8,%esp
40a4f6:	53                   	push   %ebx
40a4f7:	56                   	push   %esi
40a4f8:	89 4d f4             	mov    %ecx,-0xc(%ebp)
40a4fb:	89 55 f8             	mov    %edx,-0x8(%ebp)
40a4fe:	89 45 fc             	mov    %eax,-0x4(%ebp)
40a501:	8b 5d 08             	mov    0x8(%ebp),%ebx
40a504:	ff 75 10             	push   0x10(%ebp)
40a507:	ff 75 0c             	push   0xc(%ebp)
40a50a:	8d 45 e8             	lea    -0x18(%ebp),%eax
40a50d:	e8 c6 fd ff ff       	call   0x40a2d8
40a512:	8b 4d ec             	mov    -0x14(%ebp),%ecx
40a515:	85 c9                	test   %ecx,%ecx
40a517:	7f 24                	jg     0x40a53d
40a519:	8b 45 fc             	mov    -0x4(%ebp),%eax
40a51c:	66 c7 00 00 00       	movw   $0x0,(%eax)
40a521:	8b 45 f8             	mov    -0x8(%ebp),%eax
40a524:	66 c7 00 00 00       	movw   $0x0,(%eax)
40a529:	8b 45 f4             	mov    -0xc(%ebp),%eax
40a52c:	66 c7 00 00 00       	movw   $0x0,(%eax)
40a531:	66 c7 03 00 00       	movw   $0x0,(%ebx)
40a536:	33 d2                	xor    %edx,%edx
40a538:	e9 f2 00 00 00       	jmp    0x40a62f
40a53d:	8b c1                	mov    %ecx,%eax
40a53f:	be 07 00 00 00       	mov    $0x7,%esi
40a544:	99                   	cltd
40a545:	f7 fe                	idiv   %esi
40a547:	42                   	inc    %edx
40a548:	66 89 13             	mov    %dx,(%ebx)
40a54b:	49                   	dec    %ecx
40a54c:	66 bb 01 00          	mov    $0x1,%bx
40a550:	81 f9 b1 3a 02 00    	cmp    $0x23ab1,%ecx
40a556:	7c 13                	jl     0x40a56b
40a558:	81 e9 b1 3a 02 00    	sub    $0x23ab1,%ecx
40a55e:	66 81 c3 90 01       	add    $0x190,%bx
40a563:	81 f9 b1 3a 02 00    	cmp    $0x23ab1,%ecx
40a569:	7d ed                	jge    0x40a558
40a56b:	8d 45 f2             	lea    -0xe(%ebp),%eax
40a56e:	50                   	push   %eax
40a56f:	8d 45 f0             	lea    -0x10(%ebp),%eax
40a572:	66 ba ac 8e          	mov    $0x8eac,%dx
40a576:	91                   	xchg   %eax,%ecx
40a577:	e8 ac e1 ff ff       	call   0x408728
40a57c:	66 83 7d f0 04       	cmpw   $0x4,-0x10(%ebp)
40a581:	75 0a                	jne    0x40a58d
40a583:	66 ff 4d f0          	decw   -0x10(%ebp)
40a587:	66 81 45 f2 ac 8e    	addw   $0x8eac,-0xe(%ebp)
40a58d:	66 6b 45 f0 64       	imul   $0x64,-0x10(%ebp),%ax
40a592:	66 03 d8             	add    %ax,%bx
40a595:	8d 45 f2             	lea    -0xe(%ebp),%eax
40a598:	50                   	push   %eax
40a599:	8d 4d f0             	lea    -0x10(%ebp),%ecx
40a59c:	0f b7 45 f2          	movzwl -0xe(%ebp),%eax
40a5a0:	66 ba b5 05          	mov    $0x5b5,%dx
40a5a4:	e8 7f e1 ff ff       	call   0x408728
40a5a9:	0f b7 45 f0          	movzwl -0x10(%ebp),%eax
40a5ad:	03 c0                	add    %eax,%eax
40a5af:	03 c0                	add    %eax,%eax
40a5b1:	66 03 d8             	add    %ax,%bx
40a5b4:	8d 45 f2             	lea    -0xe(%ebp),%eax
40a5b7:	50                   	push   %eax
40a5b8:	8d 4d f0             	lea    -0x10(%ebp),%ecx
40a5bb:	0f b7 45 f2          	movzwl -0xe(%ebp),%eax
40a5bf:	66 ba 6d 01          	mov    $0x16d,%dx
40a5c3:	e8 60 e1 ff ff       	call   0x408728
40a5c8:	66 83 7d f0 04       	cmpw   $0x4,-0x10(%ebp)
40a5cd:	75 0a                	jne    0x40a5d9
40a5cf:	66 ff 4d f0          	decw   -0x10(%ebp)
40a5d3:	66 81 45 f2 6d 01    	addw   $0x16d,-0xe(%ebp)
40a5d9:	66 03 5d f0          	add    -0x10(%ebp),%bx
40a5dd:	8b c3                	mov    %ebx,%eax
40a5df:	e8 04 fe ff ff       	call   0x40a3e8
40a5e4:	8b d0                	mov    %eax,%edx
40a5e6:	0f b6 c2             	movzbl %dl,%eax
40a5e9:	8d 04 40             	lea    (%eax,%eax,2),%eax
40a5ec:	8d 34 c5 d8 b7 49 00 	lea    0x49b7d8(,%eax,8),%esi
40a5f3:	66 b8 01 00          	mov    $0x1,%ax
40a5f7:	0f b7 c8             	movzwl %ax,%ecx
40a5fa:	0f b7 4c 4e fe       	movzwl -0x2(%esi,%ecx,2),%ecx
40a5ff:	66 89 4d f0          	mov    %cx,-0x10(%ebp)
40a603:	0f b7 4d f2          	movzwl -0xe(%ebp),%ecx
40a607:	66 3b 4d f0          	cmp    -0x10(%ebp),%cx
40a60b:	72 0b                	jb     0x40a618
40a60d:	0f b7 4d f0          	movzwl -0x10(%ebp),%ecx
40a611:	66 29 4d f2          	sub    %cx,-0xe(%ebp)
40a615:	40                   	inc    %eax
40a616:	eb df                	jmp    0x40a5f7
40a618:	8b 4d fc             	mov    -0x4(%ebp),%ecx
40a61b:	66 89 19             	mov    %bx,(%ecx)
40a61e:	8b 4d f8             	mov    -0x8(%ebp),%ecx
40a621:	66 89 01             	mov    %ax,(%ecx)
40a624:	0f b7 45 f2          	movzwl -0xe(%ebp),%eax
40a628:	40                   	inc    %eax
40a629:	8b 4d f4             	mov    -0xc(%ebp),%ecx
40a62c:	66 89 01             	mov    %ax,(%ecx)
40a62f:	8b c2                	mov    %edx,%eax
40a631:	5e                   	pop    %esi
40a632:	5b                   	pop    %ebx
40a633:	8b e5                	mov    %ebp,%esp
40a635:	5d                   	pop    %ebp
40a636:	c2 0c 00             	ret    $0xc
40a639:	8d 40 00             	lea    0x0(%eax),%eax
40a63c:	55                   	push   %ebp
40a63d:	8b ec                	mov    %esp,%ebp
40a63f:	51                   	push   %ecx
40a640:	56                   	push   %esi
40a641:	8b f0                	mov    %eax,%esi
40a643:	ff 75 0c             	push   0xc(%ebp)
40a646:	ff 75 08             	push   0x8(%ebp)
40a649:	8d 45 fe             	lea    -0x2(%ebp),%eax
40a64c:	50                   	push   %eax
40a64d:	8b c6                	mov    %esi,%eax
40a64f:	e8 9c fe ff ff       	call   0x40a4f0
40a654:	5e                   	pop    %esi
40a655:	59                   	pop    %ecx
40a656:	5d                   	pop    %ebp
40a657:	c2 08 00             	ret    $0x8
40a65a:	8b c0                	mov    %eax,%eax
40a65c:	55                   	push   %ebp