/media/libjpeg/simd/jcolsamp.inc

http://github.com/zpao/v8monkey · Unknown · 105 lines · 99 code · 6 blank · 0 comment · 0 complexity · 563458be9acc6f2212ff36135a523f42 MD5 · raw file

  1. ;
  2. ; jcolsamp.inc - private declarations for color conversion & up/downsampling
  3. ;
  4. ; Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
  5. ;
  6. ; Based on
  7. ; x86 SIMD extension for IJG JPEG library
  8. ; Copyright (C) 1999-2006, MIYASAKA Masaru.
  9. ; For conditions of distribution and use, see copyright notice in jsimdext.inc
  10. ;
  11. ; [TAB8]
  12. ; --------------------------------------------------------------------------
  13. ; pseudo-resisters to make ordering of RGB configurable
  14. ;
  15. %if RGB_RED == 0
  16. %define mmA mm0
  17. %define mmB mm1
  18. %define xmmA xmm0
  19. %define xmmB xmm1
  20. %elif RGB_GREEN == 0
  21. %define mmA mm2
  22. %define mmB mm3
  23. %define xmmA xmm2
  24. %define xmmB xmm3
  25. %elif RGB_BLUE == 0
  26. %define mmA mm4
  27. %define mmB mm5
  28. %define xmmA xmm4
  29. %define xmmB xmm5
  30. %else
  31. %define mmA mm6
  32. %define mmB mm7
  33. %define xmmA xmm6
  34. %define xmmB xmm7
  35. %endif
  36. %if RGB_RED == 1
  37. %define mmC mm0
  38. %define mmD mm1
  39. %define xmmC xmm0
  40. %define xmmD xmm1
  41. %elif RGB_GREEN == 1
  42. %define mmC mm2
  43. %define mmD mm3
  44. %define xmmC xmm2
  45. %define xmmD xmm3
  46. %elif RGB_BLUE == 1
  47. %define mmC mm4
  48. %define mmD mm5
  49. %define xmmC xmm4
  50. %define xmmD xmm5
  51. %else
  52. %define mmC mm6
  53. %define mmD mm7
  54. %define xmmC xmm6
  55. %define xmmD xmm7
  56. %endif
  57. %if RGB_RED == 2
  58. %define mmE mm0
  59. %define mmF mm1
  60. %define xmmE xmm0
  61. %define xmmF xmm1
  62. %elif RGB_GREEN == 2
  63. %define mmE mm2
  64. %define mmF mm3
  65. %define xmmE xmm2
  66. %define xmmF xmm3
  67. %elif RGB_BLUE == 2
  68. %define mmE mm4
  69. %define mmF mm5
  70. %define xmmE xmm4
  71. %define xmmF xmm5
  72. %else
  73. %define mmE mm6
  74. %define mmF mm7
  75. %define xmmE xmm6
  76. %define xmmF xmm7
  77. %endif
  78. %if RGB_RED == 3
  79. %define mmG mm0
  80. %define mmH mm1
  81. %define xmmG xmm0
  82. %define xmmH xmm1
  83. %elif RGB_GREEN == 3
  84. %define mmG mm2
  85. %define mmH mm3
  86. %define xmmG xmm2
  87. %define xmmH xmm3
  88. %elif RGB_BLUE == 3
  89. %define mmG mm4
  90. %define mmH mm5
  91. %define xmmG xmm4
  92. %define xmmH xmm5
  93. %else
  94. %define mmG mm6
  95. %define mmH mm7
  96. %define xmmG xmm6
  97. %define xmmH xmm7
  98. %endif
  99. ; --------------------------------------------------------------------------