// File: /workspace/github_c_makefile_star2_O2/jonof[P]jftekwar/src/tekldsv.c
// Function: savegame
int
savegame(int saveno)
{
     int      i, fil;
     intptr_t tmpanimates[MAXANIMATES];

     sprintf((char *)tempbuf,"savegam%d.tek",saveno);
   
     if( (fil = open((char *)tempbuf,O_BINARY|O_TRUNC|O_CREAT|O_WRONLY,S_IWRITE)) == -1 ) {
          return(-1);
     }

     lseek(fil, 0, SEEK_SET);

     write(fil,loadsavenames[saveno-1],MAXLOADSAVESIZE);

     write(fil,boardfilename,80);

     write(fil,&numplayers,2);
     write(fil,&myconnectindex,2);
     write(fil,&connecthead,2);
     write(fil,connectpoint2,MAXPLAYERS<<1);

     write(fil,posx,MAXPLAYERS<<2);
     write(fil,posy,MAXPLAYERS<<2);
     write(fil,posz,MAXPLAYERS<<2);
     write(fil,horiz,MAXPLAYERS<<2);
     write(fil,zoom,MAXPLAYERS<<2);
     write(fil,hvel,MAXPLAYERS<<2);
     write(fil,ang,MAXPLAYERS<<1);
     write(fil,cursectnum,MAXPLAYERS<<1);
     write(fil,ocursectnum,MAXPLAYERS<<1);
     write(fil,playersprite,MAXPLAYERS<<1);
     write(fil,deaths,MAXPLAYERS<<1);
     write(fil,lastchaingun,MAXPLAYERS<<2);
     write(fil,health,MAXPLAYERS<<2);
     write(fil,score,MAXPLAYERS<<2);
     write(fil,saywatchit,MAXPLAYERS<<2);
     write(fil,numbombs,MAXPLAYERS<<1);
     write(fil,&screensize,2);
     write(fil,oflags,MAXPLAYERS<<1);
     write(fil,dimensionmode,MAXPLAYERS);
     write(fil,revolvedoorstat,MAXPLAYERS);
     write(fil,revolvedoorang,MAXPLAYERS<<1);
     write(fil,revolvedoorrotang,MAXPLAYERS<<1);
     write(fil,revolvedoorx,MAXPLAYERS<<2);
     write(fil,revolvedoory,MAXPLAYERS<<2);

     write(fil,&numsectors,2);
     write(fil,sector,sizeof(sectortype)*numsectors);

     write(fil,&numwalls,2);
     write(fil,wall,sizeof(walltype)*numwalls);

     // Store all sprites (even holes) to preserve indeces
     write(fil,sprite,sizeof(spritetype)*MAXSPRITES);
     write(fil,headspritesect,(MAXSECTORS+1)<<1);
     write(fil,prevspritesect,MAXSPRITES<<1);
     write(fil,nextspritesect,MAXSPRITES<<1);
     write(fil,headspritestat,(MAXSTATUS+1)<<1);
     write(fil,prevspritestat,MAXSPRITES<<1);
     write(fil,nextspritestat,MAXSPRITES<<1);

     write(fil,&vel,4);
     write(fil,&svel,4);
     write(fil,&angvel,4);

     write(fil,&locselectedgun,4);
     write(fil,&locvel,1);
     write(fil,&olocvel,1);
     write(fil,&locsvel,2);                                  // Les 09/28/95
     write(fil,&olocsvel,2);                                 // Les 09/28/95
     write(fil,&locangvel,2);                                // Les 09/28/95
     write(fil,&olocangvel,2);                               // Les 09/28/95
     write(fil,&locbits,2);
     write(fil,&olocbits,2);

     write(fil,&locselectedgun2,4);
     write(fil,&locvel2,1);
     write(fil,&olocvel2,1);
     write(fil,&locsvel2,2);                                 // Les 09/28/95
     write(fil,&olocsvel2,2);                                // Les 09/28/95
     write(fil,&locangvel2,2);                               // Les 09/28/95
     write(fil,&olocangvel2,2);                              // Les 09/28/95
     write(fil,&locbits2,2);
     write(fil,&olocbits2,2);

     write(fil,syncvel,MAXPLAYERS);
     write(fil,osyncvel,MAXPLAYERS);
     write(fil,syncsvel,MAXPLAYERS<<1);                      // Les 09/28/95
     write(fil,osyncsvel,MAXPLAYERS<<1);                     // Les 09/28/95
     write(fil,syncangvel,MAXPLAYERS<<1);                    // Les 09/28/95
     write(fil,osyncangvel,MAXPLAYERS<<1);                   // Les 09/28/95
     write(fil,syncbits,MAXPLAYERS<<1);
     write(fil,osyncbits,MAXPLAYERS<<1);

     write(fil,&screenpeek,2);
     write(fil,&oldmousebstatus,2);
     write(fil,&brightness,2);
     write(fil,&neartagsector,2);
     write(fil,&neartagwall,2);
     write(fil,&neartagsprite,2);
     write(fil,&lockclock,4);
     write(fil,&neartagdist,4);
     write(fil,&neartaghitdist,4);
     write(fil,&masterslavetexttime,4);

     write(fil,rotatespritelist,16<<1);
     write(fil,&rotatespritecnt,2);
     write(fil,warpsectorlist,16<<1);
     write(fil,&warpsectorcnt,2);
     write(fil,xpanningsectorlist,16<<1);
     write(fil,&xpanningsectorcnt,2);
     write(fil,ypanningwalllist,64<<1);
     write(fil,&ypanningwallcnt,2);
     write(fil,floorpanninglist,64<<1);
     write(fil,&floorpanningcnt,2);
     write(fil,dragsectorlist,16<<1);
     write(fil,dragxdir,16<<1);
     write(fil,dragydir,16<<1);
     write(fil,&dragsectorcnt,2);
     write(fil,dragx1,16<<2);
     write(fil,dragy1,16<<2);
     write(fil,dragx2,16<<2);
     write(fil,dragy2,16<<2);
     write(fil,dragfloorz,16<<2);
     write(fil,&swingcnt,2);
     write(fil,swingwall,(32*5)<<1);
     write(fil,swingsector,32<<1);
     write(fil,swingangopen,32<<1);
     write(fil,swingangclosed,32<<1);
     write(fil,swingangopendir,32<<1);
     write(fil,swingang,32<<1);
     write(fil,swinganginc,32<<1);
     write(fil,swingx,(32*8)<<2);
     write(fil,swingy,(32*8)<<2);
     write(fil,revolvesector,4<<1);
     write(fil,revolveang,4<<1);
     write(fil,&revolvecnt,2);
     write(fil,revolvex,(4*16)<<2);
     write(fil,revolvey,(4*16)<<2);
     write(fil,revolvepivotx,4<<2);
     write(fil,revolvepivoty,4<<2);
     write(fil,subwaytracksector,(4*128)<<1);
     write(fil,subwaynumsectors,4<<1);
     write(fil,&subwaytrackcnt,2);
     write(fil,subwaystop,(4*8)<<2);
     write(fil,subwaystopcnt,4<<2);
     write(fil,subwaytrackx1,4<<2);
     write(fil,subwaytracky1,4<<2);
     write(fil,subwaytrackx2,4<<2);
     write(fil,subwaytracky2,4<<2);
     write(fil,subwayx,4<<2);
     write(fil,subwaygoalstop,4<<2);
     write(fil,subwayvel,4<<2);
     write(fil,subwaypausetime,4<<2);
     write(fil,waterfountainwall,MAXPLAYERS<<1);
     write(fil,waterfountaincnt,MAXPLAYERS<<1);
     write(fil,slimesoundcnt,MAXPLAYERS<<1);

     // Warning: only works if all pointers are in sector structures!
     for(i=MAXANIMATES-1;i>=0;i--)
          tmpanimates[i] = (intptr_t)animateptr[i] - (intptr_t)sector;
     write(fil,tmpanimates, sizeof(intptr_t)*MAXANIMATES);
     write(fil,animategoal,MAXANIMATES<<2);
     write(fil,animatevel,MAXANIMATES<<2);
     write(fil,animateacc,MAXANIMATES<<2);
     write(fil,&animatecnt,4);

     write(fil,&totalclock,4);
     write(fil,&numframes,4);
     write(fil,&randomseed,4);

    #ifdef UNINITENGINECRASH
     write(fil,startumost,MAXXDIM<<1);
     write(fil,startdmost,MAXXDIM<<1);
    #endif
 
     write(fil,&numpalookups,2);

     write(fil,&visibility,4);
     write(fil,&parallaxtype,1);
     write(fil,&parallaxyoffs,4);
     write(fil,pskyoff,MAXPSKYTILES<<1);
     write(fil,&pskybits,2);

     write(fil,show2dsector,MAXSECTORS>>3);
     write(fil,show2dwall,MAXWALLS>>3);
     write(fil,show2dsprite,MAXSPRITES>>3);
     write(fil,&automapping,1);

     write(fil,invredcards,MAXPLAYERS<<2);  // sizeof(invredcards));
     write(fil,invbluecards,MAXPLAYERS<<2); // sizeof(invbluecards));
     write(fil,invaccutrak,MAXPLAYERS<<2);  // sizeof(invaccutrak));

     tekgunsave(fil);
     tektagsave(fil);
     tekstatsave(fil);

     teksavemissioninfo(fil);
 
     close(fil);

     showmessage("GAME SAVED");

     return(0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1008, %rsp           # imm = 0x1008
movl %edi, %ebp
leaq 0xc8d42(%rip), %rbx     # 0xda5f0
leaq 0x6fbfe(%rip), %rsi     # 0x814b3
movq %rbx, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x8f20
movq %rbx, %rdi
movl $0x241, %esi            # imm = 0x241
movl $0x80, %edx
xorl %eax, %eax
callq 0x8670
cmpl $-0x1, %eax
je 0x123ed
movl %eax, %ebx
movl %eax, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0x83b0
decl %ebp
movslq %ebp, %rax
imulq $0xc, %rax, %rsi
addq 0xb56f5(%rip), %rsi     # 0xc6ff0
pushq $0xc
popq %rdx
movl %ebx, %edi
callq 0x8f10
leaq 0xc9f04(%rip), %rsi     # 0xdb810
pushq $0x50
popq %rdx
movl %ebx, %edi
callq 0x8f10
leaq 0x78a20f(%rip), %rsi    # 0x79bb2c
pushq $0x2
popq %r15
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x78a1f2(%rip), %rsi    # 0x79bb24
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x78a1ed(%rip), %rsi    # 0x79bb30
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x78a1ec(%rip), %rsi    # 0x79bb40
pushq $0x20
popq %r14
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc8b67(%rip), %rsi     # 0xda4d0
pushq $0x40
popq %rbp
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc8b93(%rip), %rsi     # 0xda510
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc8bc2(%rip), %rsi     # 0xda550
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc9ec1(%rip), %rsi     # 0xdb860
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc9f20(%rip), %rsi     # 0xdb8d0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc9ddf(%rip), %rsi     # 0xdb7a0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc8ade(%rip), %rsi     # 0xda4b0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9d3d(%rip), %rsi     # 0xdb720
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9d8c(%rip), %rsi     # 0xdb780
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9d4b(%rip), %rsi     # 0xdb750
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9dda(%rip), %rsi     # 0xdb7f0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111c19(%rip), %rsi    # 0x123640
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0xc8b58(%rip), %rsi     # 0xda590
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111c37(%rip), %rsi    # 0x123680
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111c66(%rip), %rsi    # 0x1236c0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111c95(%rip), %rsi    # 0x123700
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xca126(%rip), %rsi     # 0xdbba2
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9ed3(%rip), %rsi     # 0xdb960
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9e22(%rip), %rsi     # 0xdb8c0
pushq $0x10
popq %r12
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc9c8d(%rip), %rsi     # 0xdb740
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x111c5c(%rip), %rsi    # 0x123720
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111c6b(%rip), %rsi    # 0x123740
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111c7a(%rip), %rsi    # 0x123760
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111ca9(%rip), %rsi    # 0x1237a0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x5652d8(%rip), %r14    # 0x576de0
movl %ebx, %edi
movq %r14, %rsi
movq %r15, %rdx
callq 0x8f10
movswq (%r14), %rax
imulq $0x28, %rax, %rdx
leaq 0x3d8dbc(%rip), %r13    # 0x3ea8e0
movl %ebx, %edi
movq %r13, %rsi
callq 0x8f10
leaq 0x5abfb3(%rip), %r14    # 0x5bdae8
movl %ebx, %edi
movq %r14, %rsi
movq %r15, %rdx
callq 0x8f10
movswq (%r14), %rdx
shlq $0x5, %rdx
leaq 0x34dd7f(%rip), %rsi    # 0x35f8d0
movl %ebx, %edi
callq 0x8f10
leaq 0x411fd1(%rip), %rsi    # 0x423b30
movl $0xb0000, %edx          # imm = 0xB0000
movl %ebx, %edi
callq 0x8f10
leaq 0x54181e(%rip), %rsi    # 0x553390
movl $0x2002, %edx           # imm = 0x2002
movl %ebx, %edi
callq 0x8f10
leaq 0x54381b(%rip), %rsi    # 0x5553a0
movl $0x8000, %edx           # imm = 0x8000
movl %ebx, %edi
callq 0x8f10
leaq 0x54b808(%rip), %rsi    # 0x55d3a0
movl $0x8000, %edx           # imm = 0x8000
movl %ebx, %edi
callq 0x8f10
leaq 0x5537f5(%rip), %rsi    # 0x5653a0
movl $0x802, %edx            # imm = 0x802
movl %ebx, %edi
callq 0x8f10
leaq 0x553ff2(%rip), %rsi    # 0x565bb0
movl $0x8000, %edx           # imm = 0x8000
movl %ebx, %edi
callq 0x8f10
leaq 0x55bfdf(%rip), %rsi    # 0x56dbb0
movl $0x8000, %edx           # imm = 0x8000
movl %ebx, %edi
callq 0x8f10
leaq 0xc9bfc(%rip), %rsi     # 0xdb7e0
pushq $0x4
popq %r12
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc9beb(%rip), %rsi     # 0xdb7e4
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc9bde(%rip), %rsi     # 0xdb7e8
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x10f045(%rip), %rsi    # 0x120c60
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x10f059(%rip), %rsi    # 0x120c85
pushq $0x1
popq %r14
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc98cf(%rip), %rsi     # 0xdb510
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x10f034(%rip), %rsi    # 0x120c86
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc98af(%rip), %rsi     # 0xdb512
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x10f014(%rip), %rsi    # 0x120c88
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9891(%rip), %rsi     # 0xdb516
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9f0e(%rip), %rsi     # 0xdbba4
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9873(%rip), %rsi     # 0xdb51a
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x1117e0(%rip), %rsi    # 0x123498
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x1117c7(%rip), %rsi    # 0x123490
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9837(%rip), %rsi     # 0xdb511
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x1117a7(%rip), %rsi    # 0x123492
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9818(%rip), %rsi     # 0xdb514
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111787(%rip), %rsi    # 0x123494
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc97fa(%rip), %rsi     # 0xdb518
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111767(%rip), %rsi    # 0x123496
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc97dc(%rip), %rsi     # 0xdb51c
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc97ef(%rip), %rsi     # 0xdb540
movl %ebx, %edi
pushq $0x10
popq %r14
movq %r14, %rdx
callq 0x8f10
leaq 0xc97ca(%rip), %rsi     # 0xdb530
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9809(%rip), %rsi     # 0xdb580
movl %ebx, %edi
pushq $0x20
popq %r14
movq %r14, %rdx
callq 0x8f10
leaq 0xc97d4(%rip), %rsi     # 0xdb560
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9843(%rip), %rsi     # 0xdb5e0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9812(%rip), %rsi     # 0xdb5c0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc86d1(%rip), %rsi     # 0xda490
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9850(%rip), %rsi     # 0xdb620
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc867d(%rip), %rsi     # 0xda45e
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc866e(%rip), %rsi     # 0xda460
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc865f(%rip), %rsi     # 0xda462
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9b1e(%rip), %rsi     # 0xdb932
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9b0b(%rip), %rsi     # 0xdb930
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc9afe(%rip), %rsi     # 0xdb934
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0xc8641(%rip), %rsi     # 0xda488
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x111d88(%rip), %rsi    # 0x123be0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc9acf(%rip), %rsi     # 0xdb938
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc96a6(%rip), %rsi     # 0xdb520
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x111d65(%rip), %rsi    # 0x123bf0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111d74(%rip), %rsi    # 0x123c10
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111d73(%rip), %rsi    # 0x123c20
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111de2(%rip), %rsi    # 0x123ca0
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111de1(%rip), %rsi    # 0x123cb0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111df0(%rip), %rsi    # 0x123cd0
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111def(%rip), %rsi    # 0x123ce0
movl $0x80, %edx
movl %ebx, %edi
callq 0x8f10
leaq 0x111e5c(%rip), %rsi    # 0x123d60
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111e5b(%rip), %rsi    # 0x123d70
movl $0x80, %edx
movl %ebx, %edi
callq 0x8f10
leaq 0x111ec8(%rip), %rsi    # 0x123df0
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111ec7(%rip), %rsi    # 0x123e00
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111ed6(%rip), %rsi    # 0x123e20
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111ee5(%rip), %rsi    # 0x123e40
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x111ef4(%rip), %rsi    # 0x123e60
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111ef3(%rip), %rsi    # 0x123e70
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111f22(%rip), %rsi    # 0x123eb0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111f51(%rip), %rsi    # 0x123ef0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111f80(%rip), %rsi    # 0x123f30
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111faf(%rip), %rsi    # 0x123f70
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x111fde(%rip), %rsi    # 0x123fb0
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x111fdd(%rip), %rsi    # 0x123fc0
movl $0x140, %edx            # imm = 0x140
movl %ebx, %edi
callq 0x8f10
leaq 0x11210a(%rip), %rsi    # 0x124100
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x112139(%rip), %rsi    # 0x124140
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x112168(%rip), %rsi    # 0x124180
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x112197(%rip), %rsi    # 0x1241c0
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x1121c6(%rip), %rsi    # 0x124200
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x1121f5(%rip), %rsi    # 0x124240
movl %ebx, %edi
movq %rbp, %rdx
callq 0x8f10
leaq 0x112224(%rip), %rsi    # 0x124280
movl $0x400, %edx            # imm = 0x400
movl %ebx, %edi
callq 0x8f10
leaq 0x112611(%rip), %rsi    # 0x124680
movl $0x400, %edx            # imm = 0x400
movl %ebx, %edi
callq 0x8f10
leaq 0x1129fe(%rip), %rsi    # 0x124a80
pushq $0x8
popq %r14
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x1129f1(%rip), %rsi    # 0x124a88
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x1129e8(%rip), %rsi    # 0x124a90
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x1129e7(%rip), %rsi    # 0x124aa0
movl $0x100, %edx            # imm = 0x100
movl %ebx, %edi
callq 0x8f10
leaq 0x112ad4(%rip), %rsi    # 0x124ba0
movl $0x100, %edx            # imm = 0x100
movl %ebx, %edi
callq 0x8f10
leaq 0x112bc1(%rip), %rsi    # 0x124ca0
movl %ebx, %edi
pushq $0x10
popq %r12
movq %r12, %rdx
callq 0x8f10
leaq 0x112bbc(%rip), %rsi    # 0x124cb0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112bbb(%rip), %rsi    # 0x124cc0
movl $0x400, %edx            # imm = 0x400
movl %ebx, %edi
callq 0x8f10
leaq 0x112fa8(%rip), %rsi    # 0x1250c0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x112f9f(%rip), %rsi    # 0x1250c8
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x112f96(%rip), %rsi    # 0x1250d0
movl $0x80, %edx
movl %ebx, %edi
callq 0x8f10
leaq 0x113003(%rip), %rsi    # 0x125150
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x113002(%rip), %rsi    # 0x125160
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x113001(%rip), %rsi    # 0x125170
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x113000(%rip), %rsi    # 0x125180
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112fff(%rip), %rsi    # 0x125190
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112ffe(%rip), %rsi    # 0x1251a0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112ffd(%rip), %rsi    # 0x1251b0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112ffc(%rip), %rsi    # 0x1251c0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x112ffb(%rip), %rsi    # 0x1251d0
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0xc972a(%rip), %rsi     # 0xdb910
movl %ebx, %edi
pushq $0x20
popq %r14
movq %r14, %rdx
callq 0x8f10
leaq 0xc9745(%rip), %rsi     # 0xdb940
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0xc9694(%rip), %rsi     # 0xdb8a0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
movl $0x1ff, %eax            # imm = 0x1FF
leaq 0x10ea6e(%rip), %rcx    # 0x120c90
testl %eax, %eax
js 0x12237
movl %eax, %edx
movq (%rcx,%rdx,8), %rsi
subq %r13, %rsi
movq %rsi, (%rsp,%rdx,8)
decl %eax
jmp 0x12222
movq %rsp, %rsi
movl $0x1000, %edx           # imm = 0x1000
movl %ebx, %edi
callq 0x8f10
leaq 0x10fa43(%rip), %rsi    # 0x121c90
movl $0x800, %edx            # imm = 0x800
movl %ebx, %edi
callq 0x8f10
leaq 0x110230(%rip), %rsi    # 0x122490
movl $0x800, %edx            # imm = 0x800
movl %ebx, %edi
callq 0x8f10
leaq 0x110a1d(%rip), %rsi    # 0x122c90
movl $0x800, %edx            # imm = 0x800
movl %ebx, %edi
callq 0x8f10
leaq 0xc81ea(%rip), %rsi     # 0xda470
pushq $0x4
popq %r15
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x5410cd(%rip), %rsi    # 0x553368
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x5b7a60(%rip), %rsi    # 0x5c9d0c
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x5cb14b(%rip), %rsi    # 0x5dd408
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x5a93da(%rip), %rsi    # 0x5bb6a8
pushq $0x2
popq %r12
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x541089(%rip), %rsi    # 0x55336c
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x4f264e(%rip), %rsi    # 0x504942
pushq $0x1
popq %r14
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x4f263b(%rip), %rsi    # 0x504944
movl %ebx, %edi
movq %r15, %rdx
callq 0x8f10
leaq 0x4f2426(%rip), %rsi    # 0x504740
movl $0x200, %edx            # imm = 0x200
movl %ebx, %edi
callq 0x8f10
leaq 0x4f2613(%rip), %rsi    # 0x504940
movl %ebx, %edi
movq %r12, %rdx
callq 0x8f10
leaq 0x53fe22(%rip), %rsi    # 0x552160
movl $0x200, %edx            # imm = 0x200
movl %ebx, %edi
callq 0x8f10
leaq 0x54080f(%rip), %rsi    # 0x552b60
movl $0x800, %edx            # imm = 0x800
movl %ebx, %edi
callq 0x8f10
leaq 0x53fffc(%rip), %rsi    # 0x552360
movl $0x800, %edx            # imm = 0x800
movl %ebx, %edi
callq 0x8f10
leaq 0x540fe9(%rip), %rsi    # 0x553360
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x114a08(%rip), %rsi    # 0x126d90
pushq $0x40
popq %r14
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x114a33(%rip), %rsi    # 0x126dd0
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
leaq 0x114a62(%rip), %rsi    # 0x126e10
movl %ebx, %edi
movq %r14, %rdx
callq 0x8f10
movl %ebx, %edi
callq 0x10adc
movl %ebx, %edi
callq 0x2a4f7
movl %ebx, %edi
callq 0x25363
movl %ebx, %edi
callq 0x17cce
movl %ebx, %edi
callq 0x8310
leaq 0x6f0eb(%rip), %rdi     # 0x814cd
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x1373a
jmp 0x123f0
pushq $-0x1
popq %rbx
movl %ebx, %eax
addq $0x1008, %rsp           # imm = 0x1008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq