// File: tomfunkhouser[P]gaps/pkgs/png/pngrtran.c
// Function: png_init_read_transformations
void /* PRIVATE */
png_init_read_transformations(png_structp png_ptr)
{
   png_debug(1, "in png_init_read_transformations");

  {
#if defined(PNG_READ_BACKGROUND_SUPPORTED) || \
    defined(PNG_READ_SHIFT_SUPPORTED) || \
    defined(PNG_READ_GAMMA_SUPPORTED)
   int color_type = png_ptr->color_type;
#endif

#if defined(PNG_READ_EXPAND_SUPPORTED) && defined(PNG_READ_BACKGROUND_SUPPORTED)

#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED
   /* Detect gray background and attempt to enable optimization
    * for gray --> RGB case
    *
    * Note:  if PNG_BACKGROUND_EXPAND is set and color_type is either RGB or
    * RGB_ALPHA (in which case need_expand is superfluous anyway), the
    * background color might actually be gray yet not be flagged as such.
    * This is not a problem for the current code, which uses
    * PNG_BACKGROUND_IS_GRAY only to decide when to do the
    * png_do_gray_to_rgb() transformation.
    */
   if ((png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
       !(color_type & PNG_COLOR_MASK_COLOR))
   {
          png_ptr->mode |= PNG_BACKGROUND_IS_GRAY;
   } else if ((png_ptr->transformations & PNG_BACKGROUND) &&
              !(png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
              (png_ptr->transformations & PNG_GRAY_TO_RGB) &&
              png_ptr->background.red == png_ptr->background.green &&
              png_ptr->background.red == png_ptr->background.blue)
   {
          png_ptr->mode |= PNG_BACKGROUND_IS_GRAY;
          png_ptr->background.gray = png_ptr->background.red;
   }
#endif

   if ((png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
       (png_ptr->transformations & PNG_EXPAND))
   {
      if (!(color_type & PNG_COLOR_MASK_COLOR))  /* i.e., GRAY or GRAY_ALPHA */
      {
         /* Expand background and tRNS chunks */
         switch (png_ptr->bit_depth)
         {
            case 1:
               png_ptr->background.gray *= (png_uint_16)0xff;
               png_ptr->background.red = png_ptr->background.green
                 =  png_ptr->background.blue = png_ptr->background.gray;
               if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
               {
                 png_ptr->trans_color.gray *= (png_uint_16)0xff;
                 png_ptr->trans_color.red = png_ptr->trans_color.green
                   = png_ptr->trans_color.blue = png_ptr->trans_color.gray;
               }
               break;

            case 2:
               png_ptr->background.gray *= (png_uint_16)0x55;
               png_ptr->background.red = png_ptr->background.green
                 = png_ptr->background.blue = png_ptr->background.gray;
               if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
               {
                 png_ptr->trans_color.gray *= (png_uint_16)0x55;
                 png_ptr->trans_color.red = png_ptr->trans_color.green
                   = png_ptr->trans_color.blue = png_ptr->trans_color.gray;
               }
               break;

            case 4:
               png_ptr->background.gray *= (png_uint_16)0x11;
               png_ptr->background.red = png_ptr->background.green
                 = png_ptr->background.blue = png_ptr->background.gray;
               if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
               {
                 png_ptr->trans_color.gray *= (png_uint_16)0x11;
                 png_ptr->trans_color.red = png_ptr->trans_color.green
                   = png_ptr->trans_color.blue = png_ptr->trans_color.gray;
               }
               break;

            case 8:

            case 16:
               png_ptr->background.red = png_ptr->background.green
                 = png_ptr->background.blue = png_ptr->background.gray;
               break;
         }
      }
      else if (color_type == PNG_COLOR_TYPE_PALETTE)
      {
         png_ptr->background.red   =
            png_ptr->palette[png_ptr->background.index].red;
         png_ptr->background.green =
            png_ptr->palette[png_ptr->background.index].green;
         png_ptr->background.blue  =
            png_ptr->palette[png_ptr->background.index].blue;

#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED
        if (png_ptr->transformations & PNG_INVERT_ALPHA)
        {
#ifdef PNG_READ_EXPAND_SUPPORTED
           if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
#endif
           {
           /* Invert the alpha channel (in tRNS) unless the pixels are
            * going to be expanded, in which case leave it for later
            */
              int i, istop;
              istop=(int)png_ptr->num_trans;
              for (i=0; i<istop; i++)
                 png_ptr->trans_alpha[i] = (png_byte)(255 - png_ptr->trans_alpha[i]);
           }
        }
#endif

      }
   }
#endif

#if defined(PNG_READ_BACKGROUND_SUPPORTED) && defined(PNG_READ_GAMMA_SUPPORTED)
   png_ptr->background_1 = png_ptr->background;
#endif
#if defined(PNG_READ_GAMMA_SUPPORTED) && defined(PNG_FLOATING_POINT_SUPPORTED)

   if ((color_type == PNG_COLOR_TYPE_PALETTE && png_ptr->num_trans != 0)
       && (fabs(png_ptr->screen_gamma * png_ptr->gamma - 1.0)
         < PNG_GAMMA_THRESHOLD))
   {
    int i, k;
    k=0;
    for (i=0; i<png_ptr->num_trans; i++)
    {
      if (png_ptr->trans_alpha[i] != 0 && png_ptr->trans_alpha[i] != 0xff)
        k=1; /* Partial transparency is present */
    }
    if (k == 0)
      png_ptr->transformations &= ~PNG_GAMMA;
   }

   if ((png_ptr->transformations & (PNG_GAMMA | PNG_RGB_TO_GRAY)) &&
        png_ptr->gamma != 0.0)
   {
      png_build_gamma_table(png_ptr, png_ptr->bit_depth);

#ifdef PNG_READ_BACKGROUND_SUPPORTED
      if (png_ptr->transformations & PNG_BACKGROUND)
      {
         if (color_type == PNG_COLOR_TYPE_PALETTE)
         {
           /* Could skip if no transparency */
            png_color back, back_1;
            png_colorp palette = png_ptr->palette;
            int num_palette = png_ptr->num_palette;
            int i;
            if (png_ptr->background_gamma_type == PNG_BACKGROUND_GAMMA_FILE)
            {
               back.red = png_ptr->gamma_table[png_ptr->background.red];
               back.green = png_ptr->gamma_table[png_ptr->background.green];
               back.blue = png_ptr->gamma_table[png_ptr->background.blue];

               back_1.red = png_ptr->gamma_to_1[png_ptr->background.red];
               back_1.green = png_ptr->gamma_to_1[png_ptr->background.green];
               back_1.blue = png_ptr->gamma_to_1[png_ptr->background.blue];
            }
            else
            {
               double g, gs;

               switch (png_ptr->background_gamma_type)
               {
                  case PNG_BACKGROUND_GAMMA_SCREEN:
                     g = (png_ptr->screen_gamma);
                     gs = 1.0;
                     break;

                  case PNG_BACKGROUND_GAMMA_FILE:
                     g = 1.0 / (png_ptr->gamma);
                     gs = 1.0 / (png_ptr->gamma * png_ptr->screen_gamma);
                     break;

                  case PNG_BACKGROUND_GAMMA_UNIQUE:
                     g = 1.0 / (png_ptr->background_gamma);
                     gs = 1.0 / (png_ptr->background_gamma *
                                 png_ptr->screen_gamma);
                     break;
                  default:
                     g = 1.0;    /* back_1 */
                     gs = 1.0;   /* back */
               }

               if ( fabs(gs - 1.0) < PNG_GAMMA_THRESHOLD)
               {
                  back.red   = (png_byte)png_ptr->background.red;
                  back.green = (png_byte)png_ptr->background.green;
                  back.blue  = (png_byte)png_ptr->background.blue;
               }
               else
               {
                  back.red = (png_byte)(pow(
                     (double)png_ptr->background.red/255.0, gs) * 255.0 + .5);
                  back.green = (png_byte)(pow(
                     (double)png_ptr->background.green/255.0, gs) * 255.0
                         + .5);
                  back.blue = (png_byte)(pow(
                     (double)png_ptr->background.blue/255.0, gs) * 255.0 + .5);
               }

               back_1.red = (png_byte)(pow(
                  (double)png_ptr->background.red/255.0, g) * 255.0 + .5);
               back_1.green = (png_byte)(pow(
                  (double)png_ptr->background.green/255.0, g) * 255.0 + .5);
               back_1.blue = (png_byte)(pow(
                  (double)png_ptr->background.blue/255.0, g) * 255.0 + .5);
            }
            for (i = 0; i < num_palette; i++)
            {
               if (i < (int)png_ptr->num_trans && png_ptr->trans_alpha[i] != 0xff)
               {
                  if (png_ptr->trans_alpha[i] == 0)
                  {
                     palette[i] = back;
                  }
                  else /* if (png_ptr->trans_alpha[i] != 0xff) */
                  {
                     png_byte v, w;

                     v = png_ptr->gamma_to_1[palette[i].red];
                     png_composite(w, v, png_ptr->trans_alpha[i], back_1.red);
                     palette[i].red = png_ptr->gamma_from_1[w];

                     v = png_ptr->gamma_to_1[palette[i].green];
                     png_composite(w, v, png_ptr->trans_alpha[i], back_1.green);
                     palette[i].green = png_ptr->gamma_from_1[w];

                     v = png_ptr->gamma_to_1[palette[i].blue];
                     png_composite(w, v, png_ptr->trans_alpha[i], back_1.blue);
                     palette[i].blue = png_ptr->gamma_from_1[w];
                  }
               }
               else
               {
                  palette[i].red = png_ptr->gamma_table[palette[i].red];
                  palette[i].green = png_ptr->gamma_table[palette[i].green];
                  palette[i].blue = png_ptr->gamma_table[palette[i].blue];
               }
            }
            /* Prevent the transformations being done again, and make sure
             * that the now spurious alpha channel is stripped - the code
             * has just reduced background composition and gamma correction
             * to a simple alpha channel strip.
             */
            png_ptr->transformations &= ~PNG_BACKGROUND;
            png_ptr->transformations &= ~PNG_GAMMA;
            png_ptr->transformations |= PNG_STRIP_ALPHA;
         }
         /* if (png_ptr->background_gamma_type!=PNG_BACKGROUND_GAMMA_UNKNOWN) */
         else
         /* color_type != PNG_COLOR_TYPE_PALETTE */
         {
            double m = (double)(((png_uint_32)1 << png_ptr->bit_depth) - 1);
            double g = 1.0;
            double gs = 1.0;

            switch (png_ptr->background_gamma_type)
            {
               case PNG_BACKGROUND_GAMMA_SCREEN:
                  g = (png_ptr->screen_gamma);
                  gs = 1.0;
                  break;

               case PNG_BACKGROUND_GAMMA_FILE:
                  g = 1.0 / (png_ptr->gamma);
                  gs = 1.0 / (png_ptr->gamma * png_ptr->screen_gamma);
                  break;

               case PNG_BACKGROUND_GAMMA_UNIQUE:
                  g = 1.0 / (png_ptr->background_gamma);
                  gs = 1.0 / (png_ptr->background_gamma *
                     png_ptr->screen_gamma);
                  break;
            }

            png_ptr->background_1.gray = (png_uint_16)(pow(
               (double)png_ptr->background.gray / m, g) * m + .5);
            png_ptr->background.gray = (png_uint_16)(pow(
               (double)png_ptr->background.gray / m, gs) * m + .5);

            if ((png_ptr->background.red != png_ptr->background.green) ||
                (png_ptr->background.red != png_ptr->background.blue) ||
                (png_ptr->background.red != png_ptr->background.gray))
            {
               /* RGB or RGBA with color background */
               png_ptr->background_1.red = (png_uint_16)(pow(
                  (double)png_ptr->background.red / m, g) * m + .5);
               png_ptr->background_1.green = (png_uint_16)(pow(
                  (double)png_ptr->background.green / m, g) * m + .5);
               png_ptr->background_1.blue = (png_uint_16)(pow(
                  (double)png_ptr->background.blue / m, g) * m + .5);
               png_ptr->background.red = (png_uint_16)(pow(
                  (double)png_ptr->background.red / m, gs) * m + .5);
               png_ptr->background.green = (png_uint_16)(pow(
                  (double)png_ptr->background.green / m, gs) * m + .5);
               png_ptr->background.blue = (png_uint_16)(pow(
                  (double)png_ptr->background.blue / m, gs) * m + .5);
            }
            else
            {
               /* GRAY, GRAY ALPHA, RGB, or RGBA with gray background */
               png_ptr->background_1.red = png_ptr->background_1.green
                 = png_ptr->background_1.blue = png_ptr->background_1.gray;
               png_ptr->background.red = png_ptr->background.green
                 = png_ptr->background.blue = png_ptr->background.gray;
            }
         }
      }
      else
      /* Transformation does not include PNG_BACKGROUND */
#endif /* PNG_READ_BACKGROUND_SUPPORTED */
      if (color_type == PNG_COLOR_TYPE_PALETTE)
      {
         png_colorp palette = png_ptr->palette;
         int num_palette = png_ptr->num_palette;
         int i;

         for (i = 0; i < num_palette; i++)
         {
            palette[i].red = png_ptr->gamma_table[palette[i].red];
            palette[i].green = png_ptr->gamma_table[palette[i].green];
            palette[i].blue = png_ptr->gamma_table[palette[i].blue];
         }

         /* Done the gamma correction. */
         png_ptr->transformations &= ~PNG_GAMMA;
      }
   }
#ifdef PNG_READ_BACKGROUND_SUPPORTED
   else
#endif
#endif /* PNG_READ_GAMMA_SUPPORTED && PNG_FLOATING_POINT_SUPPORTED */
#ifdef PNG_READ_BACKGROUND_SUPPORTED
   /* No GAMMA transformation */
   if ((png_ptr->transformations & PNG_BACKGROUND) &&
       (color_type == PNG_COLOR_TYPE_PALETTE))
   {
      int i;
      int istop = (int)png_ptr->num_trans;
      png_color back;
      png_colorp palette = png_ptr->palette;

      back.red   = (png_byte)png_ptr->background.red;
      back.green = (png_byte)png_ptr->background.green;
      back.blue  = (png_byte)png_ptr->background.blue;

      for (i = 0; i < istop; i++)
      {
         if (png_ptr->trans_alpha[i] == 0)
         {
            palette[i] = back;
         }
         else if (png_ptr->trans_alpha[i] != 0xff)
         {
            /* The png_composite() macro is defined in png.h */
            png_composite(palette[i].red, palette[i].red,
               png_ptr->trans_alpha[i], back.red);
            png_composite(palette[i].green, palette[i].green,
               png_ptr->trans_alpha[i], back.green);
            png_composite(palette[i].blue, palette[i].blue,
               png_ptr->trans_alpha[i], back.blue);
         }
      }

      /* Handled alpha, still need to strip the channel. */
      png_ptr->transformations &= ~PNG_BACKGROUND;
      png_ptr->transformations |= PNG_STRIP_ALPHA;
   }
#endif /* PNG_READ_BACKGROUND_SUPPORTED */

#ifdef PNG_READ_SHIFT_SUPPORTED
   if ((png_ptr->transformations & PNG_SHIFT) &&
      (color_type == PNG_COLOR_TYPE_PALETTE))
   {
      png_uint_16 i;
      png_uint_16 istop = png_ptr->num_palette;
      int sr = 8 - png_ptr->sig_bit.red;
      int sg = 8 - png_ptr->sig_bit.green;
      int sb = 8 - png_ptr->sig_bit.blue;

      if (sr < 0 || sr > 8)
         sr = 0;
      if (sg < 0 || sg > 8)
         sg = 0;
      if (sb < 0 || sb > 8)
         sb = 0;
      for (i = 0; i < istop; i++)
      {
         png_ptr->palette[i].red >>= sr;
         png_ptr->palette[i].green >>= sg;
         png_ptr->palette[i].blue >>= sb;
      }
   }
#endif  /* PNG_READ_SHIFT_SUPPORTED */
 }
#if !defined(PNG_READ_GAMMA_SUPPORTED) && !defined(PNG_READ_SHIFT_SUPPORTED) \
 && !defined(PNG_READ_BACKGROUND_SUPPORTED)
   if (png_ptr)
      return;
#endif
}

// Assembly:
subq $0xf8, %rsp
movq %rdi, 0xf0(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x24e(%rax), %eax
movl %eax, 0xec(%rsp)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
je 0x107b9b
movl 0xec(%rsp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x107b9b
movq 0xf0(%rsp), %rax
movl 0x11c(%rax), %ecx
orl $0x800, %ecx            # imm = 0x800
movl %ecx, 0x11c(%rax)
jmp 0x107c69
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0x107c67
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
jne 0x107c67
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x4000, %eax           # imm = 0x4000
cmpl $0x0, %eax
je 0x107c67
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x264(%rcx), %ecx
cmpl %ecx, %eax
jne 0x107c67
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x266(%rcx), %ecx
cmpl %ecx, %eax
jne 0x107c67
movq 0xf0(%rsp), %rax
movl 0x11c(%rax), %ecx
orl $0x800, %ecx            # imm = 0x800
movl %ecx, 0x11c(%rax)
movq 0xf0(%rsp), %rax
movw 0x262(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x268(%rax)
jmp 0x107c69
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
je 0x10810f
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x1000, %eax           # imm = 0x1000
cmpl $0x0, %eax
je 0x10810f
movl 0xec(%rsp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x107f89
movq 0xf0(%rsp), %rax
movzbl 0x24f(%rax), %eax
decl %eax
movl %eax, %ecx
movq %rcx, 0x48(%rsp)
subl $0xf, %eax
ja 0x107f84
movq 0x48(%rsp), %rax
leaq 0x3192f(%rip), %rcx     # 0x139610
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0xf0(%rsp), %rax
movzwl 0x268(%rax), %ecx
imull $0xff, %ecx, %ecx
movw %cx, 0x268(%rax)
movq 0xf0(%rsp), %rax
movw 0x268(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x2000000, %rax        # imm = 0x2000000
cmpq $0x0, %rax
jne 0x107db4
movq 0xf0(%rsp), %rax
movzwl 0x2e8(%rax), %ecx
imull $0xff, %ecx, %ecx
movw %cx, 0x2e8(%rax)
movq 0xf0(%rsp), %rax
movw 0x2e8(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x2e6(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e4(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e2(%rax)
jmp 0x107f84
movq 0xf0(%rsp), %rax
movzwl 0x268(%rax), %ecx
imull $0x55, %ecx, %ecx
movw %cx, 0x268(%rax)
movq 0xf0(%rsp), %rax
movw 0x268(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x2000000, %rax        # imm = 0x2000000
cmpq $0x0, %rax
jne 0x107e7d
movq 0xf0(%rsp), %rax
movzwl 0x2e8(%rax), %ecx
imull $0x55, %ecx, %ecx
movw %cx, 0x2e8(%rax)
movq 0xf0(%rsp), %rax
movw 0x2e8(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x2e6(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e4(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e2(%rax)
jmp 0x107f84
movq 0xf0(%rsp), %rax
movzwl 0x268(%rax), %ecx
imull $0x11, %ecx, %ecx
movw %cx, 0x268(%rax)
movq 0xf0(%rsp), %rax
movw 0x268(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x2000000, %rax        # imm = 0x2000000
cmpq $0x0, %rax
jne 0x107f46
movq 0xf0(%rsp), %rax
movzwl 0x2e8(%rax), %ecx
imull $0x11, %ecx, %ecx
movw %cx, 0x2e8(%rax)
movq 0xf0(%rsp), %rax
movw 0x2e8(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x2e6(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e4(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x2e2(%rax)
jmp 0x107f84
movq 0xf0(%rsp), %rax
movw 0x268(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
jmp 0x10810d
cmpl $0x3, 0xec(%rsp)
jne 0x10810b
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq 0xf0(%rsp), %rcx
movzbl 0x260(%rcx), %ecx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl (%rax), %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq 0xf0(%rsp), %rcx
movzbl 0x260(%rcx), %ecx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl 0x1(%rax), %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq 0xf0(%rsp), %rcx
movzbl 0x260(%rcx), %ecx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl 0x2(%rax), %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x80000, %rax          # imm = 0x80000
cmpq $0x0, %rax
je 0x108109
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x2000000, %rax        # imm = 0x2000000
cmpq $0x0, %rax
jne 0x108107
movq 0xf0(%rsp), %rax
movzwl 0x242(%rax), %eax
movl %eax, 0xe4(%rsp)
movl $0x0, 0xe8(%rsp)
movl 0xe8(%rsp), %eax
cmpl 0xe4(%rsp), %eax
jge 0x108105
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xe8(%rsp), %rcx
movzbl (%rax,%rcx), %ecx
movl $0xff, %eax
subl %ecx, %eax
movb %al, %dl
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xe8(%rsp), %rcx
movb %dl, (%rax,%rcx)
movl 0xe8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xe8(%rsp)
jmp 0x1080a4
jmp 0x108107
jmp 0x108109
jmp 0x10810b
jmp 0x10810d
jmp 0x10810f
movq 0xf0(%rsp), %rax
movq 0xf0(%rsp), %rcx
movq 0x260(%rcx), %rdx
movq %rdx, 0x26a(%rax)
movw 0x268(%rcx), %cx
movw %cx, 0x272(%rax)
cmpl $0x3, 0xec(%rsp)
jne 0x108266
movq 0xf0(%rsp), %rax
movzwl 0x242(%rax), %eax
cmpl $0x0, %eax
je 0x108266
movq 0xf0(%rsp), %rax
movss 0x290(%rax), %xmm0
movq 0xf0(%rsp), %rax
mulss 0x28c(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2ae7b(%rip), %xmm0    # 0x133008
subsd %xmm0, %xmm1
movaps 0x2b0d8(%rip), %xmm0    # 0x133270
pand %xmm0, %xmm1
movsd 0x315b4(%rip), %xmm0    # 0x139758
ucomisd %xmm1, %xmm0
jbe 0x108266
movl $0x0, 0xdc(%rsp)
movl $0x0, 0xe0(%rsp)
movl 0xe0(%rsp), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x242(%rcx), %ecx
cmpl %ecx, %eax
jge 0x108240
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xe0(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0x0, %eax
je 0x10822b
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xe0(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0xff, %eax
je 0x10822b
movl $0x1, 0xdc(%rsp)
jmp 0x10822d
movl 0xe0(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xe0(%rsp)
jmp 0x1081c4
cmpl $0x0, 0xdc(%rsp)
jne 0x108264
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
andl $0xffffdfff, %ecx       # imm = 0xFFFFDFFF
movl %ecx, 0x124(%rax)
jmp 0x108266
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andq $0x602000, %rax         # imm = 0x602000
cmpq $0x0, %rax
je 0x10933c
movq 0xf0(%rsp), %rax
movss 0x28c(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x1082a8
jp 0x1082a8
jmp 0x10933c
movq 0xf0(%rsp), %rdi
movq 0xf0(%rsp), %rax
movzbl 0x24f(%rax), %esi
callq 0x1097e0
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0x1091d8
cmpl $0x3, 0xec(%rsp)
jne 0x108c96
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq %rax, 0xc8(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x240(%rax), %eax
movl %eax, 0xc4(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x258(%rax), %eax
cmpl $0x2, %eax
jne 0x108428
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x262(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xd9(%rsp)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x264(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xda(%rsp)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x266(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xdb(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x262(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xd6(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x264(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xd7(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xf0(%rsp), %rcx
movzwl 0x266(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xd8(%rsp)
jmp 0x1087b8
movq 0xf0(%rsp), %rax
movzbl 0x258(%rax), %eax
movl %eax, 0x44(%rsp)
subl $0x1, %eax
je 0x10845f
jmp 0x108442
movl 0x44(%rsp), %eax
subl $0x2, %eax
je 0x108492
jmp 0x10844d
movl 0x44(%rsp), %eax
subl $0x3, %eax
je 0x1084f9
jmp 0x10855d
movq 0xf0(%rsp), %rax
movss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
movsd %xmm0, 0xb8(%rsp)
movsd 0x2ab84(%rip), %xmm0    # 0x133008
movsd %xmm0, 0xb0(%rsp)
jmp 0x10857f
movq 0xf0(%rsp), %rax
movss 0x28c(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2ab5a(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0xb8(%rsp)
movq 0xf0(%rsp), %rax
movss 0x28c(%rax), %xmm0
movq 0xf0(%rsp), %rax
mulss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2ab21(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0xb0(%rsp)
jmp 0x10857f
movq 0xf0(%rsp), %rax
movss 0x25c(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2aaf3(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0xb8(%rsp)
movq 0xf0(%rsp), %rax
movss 0x25c(%rax), %xmm0
movq 0xf0(%rsp), %rax
mulss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2aaba(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0xb0(%rsp)
jmp 0x10857f
movsd 0x2aaa3(%rip), %xmm0    # 0x133008
movsd %xmm0, 0xb8(%rsp)
movsd 0x2aa92(%rip), %xmm0    # 0x133008
movsd %xmm0, 0xb0(%rsp)
movsd 0xb0(%rsp), %xmm1
movsd 0x2aa78(%rip), %xmm0    # 0x133008
subsd %xmm0, %xmm1
movaps 0x2acd5(%rip), %xmm0    # 0x133270
pand %xmm0, %xmm1
movsd 0x311b1(%rip), %xmm0    # 0x139758
ucomisd %xmm1, %xmm0
jbe 0x1085f4
movq 0xf0(%rsp), %rax
movw 0x262(%rax), %ax
movb %al, 0xd9(%rsp)
movq 0xf0(%rsp), %rax
movw 0x264(%rax), %ax
movb %al, 0xda(%rsp)
movq 0xf0(%rsp), %rax
movw 0x266(%rax), %ax
movb %al, 0xdb(%rsp)
jmp 0x1086d6
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0x2ac11(%rip), %xmm1    # 0x133220
movsd %xmm1, 0x30(%rsp)
divsd %xmm1, %xmm0
movsd 0xb0(%rsp), %xmm1
callq 0xf880
movsd 0x30(%rsp), %xmm1
mulsd %xmm1, %xmm0
movsd 0x2a9d7(%rip), %xmm2    # 0x133010
movsd %xmm2, 0x38(%rsp)
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xd9(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x264(%rax), %eax
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
movsd 0xb0(%rsp), %xmm1
callq 0xf880
movsd 0x30(%rsp), %xmm1
movsd 0x38(%rsp), %xmm2
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xda(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x266(%rax), %eax
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
movsd 0xb0(%rsp), %xmm1
callq 0xf880
movsd 0x30(%rsp), %xmm2
movsd 0x38(%rsp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xdb(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0x2ab2f(%rip), %xmm1    # 0x133220
movsd %xmm1, 0x20(%rsp)
divsd %xmm1, %xmm0
movsd 0xb8(%rsp), %xmm1
callq 0xf880
movsd 0x20(%rsp), %xmm1
mulsd %xmm1, %xmm0
movsd 0x2a8f5(%rip), %xmm2    # 0x133010
movsd %xmm2, 0x28(%rsp)
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xd6(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x264(%rax), %eax
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
movsd 0xb8(%rsp), %xmm1
callq 0xf880
movsd 0x20(%rsp), %xmm1
movsd 0x28(%rsp), %xmm2
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xd7(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x266(%rax), %eax
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
movsd 0xb8(%rsp), %xmm1
callq 0xf880
movsd 0x20(%rsp), %xmm2
movsd 0x28(%rsp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0xd8(%rsp)
movl $0x0, 0xc0(%rsp)
movl 0xc0(%rsp), %eax
cmpl 0xc4(%rsp), %eax
jge 0x108c42
movl 0xc0(%rsp), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x242(%rcx), %ecx
cmpl %ecx, %eax
jge 0x108b57
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xc0(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0xff, %eax
je 0x108b57
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0xc0(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0x0, %eax
jne 0x10886c
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rcx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movw 0xd9(%rsp), %cx
movw %cx, (%rax)
movb 0xdb(%rsp), %cl
movb %cl, 0x2(%rax)
jmp 0x108b52
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xaf(%rsp)
movzbl 0xaf(%rsp), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0xc0(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0xd6(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0xc0(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0xac(%rsp)
movzwl 0xac(%rsp), %eax
movzwl 0xac(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, 0xae(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a0(%rax), %rax
movzbl 0xae(%rsp), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, (%rax)
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x1(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xaf(%rsp)
movzbl 0xaf(%rsp), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0xc0(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0xd7(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0xc0(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0xaa(%rsp)
movzwl 0xaa(%rsp), %eax
movzwl 0xaa(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, 0xae(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a0(%rax), %rax
movzbl 0xae(%rsp), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x1(%rax)
movq 0xf0(%rsp), %rax
movq 0x2a8(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x2(%rcx), %ecx
movb (%rax,%rcx), %al
movb %al, 0xaf(%rsp)
movzbl 0xaf(%rsp), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0xc0(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0xd8(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0xc0(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0xa8(%rsp)
movzwl 0xa8(%rsp), %eax
movzwl 0xa8(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, 0xae(%rsp)
movq 0xf0(%rsp), %rax
movq 0x2a0(%rax), %rax
movzbl 0xae(%rsp), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x2(%rax)
jmp 0x108c2a
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, (%rax)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x1(%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x1(%rax)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0xc8(%rsp), %rcx
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x2(%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0xc8(%rsp), %rax
movslq 0xc0(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x2(%rax)
jmp 0x108c2c
movl 0xc0(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc0(%rsp)
jmp 0x1087c3
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
andl $0xffffff7f, %ecx       # imm = 0xFFFFFF7F
movl %ecx, 0x124(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
andl $0xffffdfff, %ecx       # imm = 0xFFFFDFFF
movl %ecx, 0x124(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
orq $0x40000, %rcx          # imm = 0x40000
movl %ecx, 0x124(%rax)
jmp 0x1091d3
movq 0xf0(%rsp), %rax
movb 0x24f(%rax), %cl
movl $0x1, %eax
shll %cl, %eax
decl %eax
cvtsi2sd %rax, %xmm0
movsd %xmm0, 0xa0(%rsp)
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x98(%rsp)
movq %rax, 0x90(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x258(%rax), %eax
movl %eax, 0x1c(%rsp)
subl $0x1, %eax
je 0x108d0c
jmp 0x108cef
movl 0x1c(%rsp), %eax
subl $0x2, %eax
je 0x108d3f
jmp 0x108cfa
movl 0x1c(%rsp), %eax
subl $0x3, %eax
je 0x108da3
jmp 0x108e05
movq 0xf0(%rsp), %rax
movss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
movsd %xmm0, 0x98(%rsp)
movsd 0x2a2d7(%rip), %xmm0    # 0x133008
movsd %xmm0, 0x90(%rsp)
jmp 0x108e05
movq 0xf0(%rsp), %rax
movss 0x28c(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2a2ad(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0x98(%rsp)
movq 0xf0(%rsp), %rax
movss 0x28c(%rax), %xmm0
movq 0xf0(%rsp), %rax
mulss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2a274(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0x90(%rsp)
jmp 0x108e05
movq 0xf0(%rsp), %rax
movss 0x25c(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2a249(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0x98(%rsp)
movq 0xf0(%rsp), %rax
movss 0x25c(%rax), %xmm0
movq 0xf0(%rsp), %rax
mulss 0x290(%rax), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x2a210(%rip), %xmm0    # 0x133008
divsd %xmm1, %xmm0
movsd %xmm0, 0x90(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x268(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x98(%rsp), %xmm1
callq 0xf880
movsd 0xa0(%rsp), %xmm1
mulsd %xmm1, %xmm0
movsd 0x2a1c8(%rip), %xmm1    # 0x133010
movsd %xmm1, 0x10(%rsp)
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x272(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x268(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x90(%rsp), %xmm1
callq 0xf880
movsd 0x10(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x268(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x264(%rcx), %ecx
cmpl %ecx, %eax
jne 0x108f2d
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x266(%rcx), %ecx
cmpl %ecx, %eax
jne 0x108f2d
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
movq 0xf0(%rsp), %rcx
movzwl 0x268(%rcx), %ecx
cmpl %ecx, %eax
je 0x109159
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x98(%rsp), %xmm1
callq 0xf880
movsd 0xa0(%rsp), %xmm1
mulsd %xmm1, %xmm0
movsd 0x2a0a0(%rip), %xmm1    # 0x133010
movsd %xmm1, 0x8(%rsp)
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x26c(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x264(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x98(%rsp), %xmm1
callq 0xf880
movsd 0x8(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x26e(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x266(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x98(%rsp), %xmm1
callq 0xf880
movsd 0x8(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x270(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x262(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x90(%rsp), %xmm1
callq 0xf880
movsd 0x8(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x264(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x90(%rsp), %xmm1
callq 0xf880
movsd 0x8(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movzwl 0x266(%rax), %eax
cvtsi2sd %eax, %xmm0
movsd 0xa0(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x90(%rsp), %xmm1
callq 0xf880
movsd 0x8(%rsp), %xmm1
movsd 0xa0(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movw %ax, %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
jmp 0x1091d1
movq 0xf0(%rsp), %rax
movw 0x272(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x270(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x26e(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x26c(%rax)
movq 0xf0(%rsp), %rax
movw 0x268(%rax), %cx
movq 0xf0(%rsp), %rax
movw %cx, 0x266(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x264(%rax)
movq 0xf0(%rsp), %rax
movw %cx, 0x262(%rax)
jmp 0x1091d3
jmp 0x109337
cmpl $0x3, 0xec(%rsp)
jne 0x109335
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq %rax, 0x88(%rsp)
movq 0xf0(%rsp), %rax
movzwl 0x240(%rax), %eax
movl %eax, 0x84(%rsp)
movl $0x0, 0x80(%rsp)
movl 0x80(%rsp), %eax
cmpl 0x84(%rsp), %eax
jge 0x10931b
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0x88(%rsp), %rcx
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0x88(%rsp), %rax
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, (%rax)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0x88(%rsp), %rcx
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x1(%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0x88(%rsp), %rax
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x1(%rax)
movq 0xf0(%rsp), %rax
movq 0x298(%rax), %rax
movq 0x88(%rsp), %rcx
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rcx
movzbl 0x2(%rcx), %ecx
movb (%rax,%rcx), %cl
movq 0x88(%rsp), %rax
movslq 0x80(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x2(%rax)
movl 0x80(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x80(%rsp)
jmp 0x10921e
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
andl $0xffffdfff, %ecx       # imm = 0xFFFFDFFF
movl %ecx, 0x124(%rax)
jmp 0x109337
jmp 0x109658
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0x109656
cmpl $0x3, 0xec(%rsp)
jne 0x109656
movq 0xf0(%rsp), %rax
movzwl 0x242(%rax), %eax
movl %eax, 0x78(%rsp)
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movq %rax, 0x68(%rsp)
movq 0xf0(%rsp), %rax
movw 0x262(%rax), %ax
movb %al, 0x75(%rsp)
movq 0xf0(%rsp), %rax
movw 0x264(%rax), %ax
movb %al, 0x76(%rsp)
movq 0xf0(%rsp), %rax
movw 0x266(%rax), %ax
movb %al, 0x77(%rsp)
movl $0x0, 0x7c(%rsp)
movl 0x7c(%rsp), %eax
cmpl 0x78(%rsp), %eax
jge 0x109621
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0x7c(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0x0, %eax
jne 0x10941e
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rcx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movw 0x75(%rsp), %cx
movw %cx, (%rax)
movb 0x77(%rsp), %cl
movb %cl, 0x2(%rax)
jmp 0x10960f
movq 0xf0(%rsp), %rax
movq 0x2d8(%rax), %rax
movslq 0x7c(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0xff, %eax
je 0x10960d
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rcx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl (%rax), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0x7c(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0x75(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0x7c(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0x66(%rsp)
movzwl 0x66(%rsp), %eax
movzwl 0x66(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, %cl
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, (%rax)
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rcx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl 0x1(%rax), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0x7c(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0x76(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0x7c(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0x64(%rsp)
movzwl 0x64(%rsp), %eax
movzwl 0x64(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, %cl
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x1(%rax)
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rcx
imulq $0x3, %rcx, %rcx
addq %rcx, %rax
movzbl 0x2(%rax), %eax
movzwl %ax, %eax
movq 0xf0(%rsp), %rcx
movq 0x2d8(%rcx), %rcx
movslq 0x7c(%rsp), %rdx
movzbl (%rcx,%rdx), %ecx
movzwl %cx, %ecx
imull %ecx, %eax
movzbl 0x77(%rsp), %ecx
movzwl %cx, %ecx
movq 0xf0(%rsp), %rdx
movq 0x2d8(%rdx), %rdx
movslq 0x7c(%rsp), %rsi
movzbl (%rdx,%rsi), %edx
movzwl %dx, %esi
movl $0xff, %edx
subl %esi, %edx
movzwl %dx, %edx
imull %edx, %ecx
addl %ecx, %eax
addl $0x80, %eax
movw %ax, 0x62(%rsp)
movzwl 0x62(%rsp), %eax
movzwl 0x62(%rsp), %ecx
sarl $0x8, %ecx
addl %ecx, %eax
sarl $0x8, %eax
movb %al, %cl
movq 0x68(%rsp), %rax
movslq 0x7c(%rsp), %rdx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movb %cl, 0x2(%rax)
jmp 0x10960f
jmp 0x109611
movl 0x7c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x7c(%rsp)
jmp 0x1093ce
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
andl $0xffffff7f, %ecx       # imm = 0xFFFFFF7F
movl %ecx, 0x124(%rax)
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %ecx
orq $0x40000, %rcx          # imm = 0x40000
movl %ecx, 0x124(%rax)
jmp 0x109658
movq 0xf0(%rsp), %rax
movl 0x124(%rax), %eax
andl $0x8, %eax
cmpl $0x0, %eax
je 0x1097ce
cmpl $0x3, 0xec(%rsp)
jne 0x1097ce
movq 0xf0(%rsp), %rax
movw 0x240(%rax), %ax
movw %ax, 0x5e(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x2c8(%rax), %ecx
movl $0x8, %eax
subl %ecx, %eax
movl %eax, 0x58(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x2c9(%rax), %ecx
movl $0x8, %eax
subl %ecx, %eax
movl %eax, 0x54(%rsp)
movq 0xf0(%rsp), %rax
movzbl 0x2ca(%rax), %ecx
movl $0x8, %eax
subl %ecx, %eax
movl %eax, 0x50(%rsp)
cmpl $0x0, 0x58(%rsp)
jl 0x1096f0
cmpl $0x8, 0x58(%rsp)
jle 0x1096f8
movl $0x0, 0x58(%rsp)
cmpl $0x0, 0x54(%rsp)
jl 0x109706
cmpl $0x8, 0x54(%rsp)
jle 0x10970e
movl $0x0, 0x54(%rsp)
cmpl $0x0, 0x50(%rsp)
jl 0x10971c
cmpl $0x8, 0x50(%rsp)
jle 0x109724
movl $0x0, 0x50(%rsp)
movw $0x0, 0x60(%rsp)
movzwl 0x60(%rsp), %eax
movzwl 0x5e(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1097cc
movl 0x58(%rsp), %ecx
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movzwl 0x60(%rsp), %edx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movzbl (%rax), %edx
sarl %cl, %edx
movl %edx, %ecx
movb %cl, (%rax)
movl 0x54(%rsp), %ecx
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movzwl 0x60(%rsp), %edx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movzbl 0x1(%rax), %edx
sarl %cl, %edx
movl %edx, %ecx
movb %cl, 0x1(%rax)
movl 0x50(%rsp), %ecx
movq 0xf0(%rsp), %rax
movq 0x238(%rax), %rax
movzwl 0x60(%rsp), %edx
imulq $0x3, %rdx, %rdx
addq %rdx, %rax
movzbl 0x2(%rax), %edx
sarl %cl, %edx
movl %edx, %ecx
movb %cl, 0x2(%rax)
movw 0x60(%rsp), %ax
addw $0x1, %ax
movw %ax, 0x60(%rsp)
jmp 0x10972b
jmp 0x1097ce
addq $0xf8, %rsp
retq
nopw %cs:(%rax,%rax)