comparison src/hermes/mmxp2_32.asm @ 2134:180fa05e98e2

Merged r3106:3107 from branches/SDL-1.2: Hermes PIC fixes.
author Ryan C. Gordon <icculus@icculus.org>
date Wed, 27 Jun 2007 10:17:35 +0000
parents eb4d9d99849b
children 15b4a74cdac1
comparison
equal deleted inserted replaced
2133:03715e20ec3c 2134:180fa05e98e2
26 SDL_FUNC _ConvertMMXpII32_16RGB565 26 SDL_FUNC _ConvertMMXpII32_16RGB565
27 SDL_FUNC _ConvertMMXpII32_16BGR565 27 SDL_FUNC _ConvertMMXpII32_16BGR565
28 SDL_FUNC _ConvertMMXpII32_16RGB555 28 SDL_FUNC _ConvertMMXpII32_16RGB555
29 SDL_FUNC _ConvertMMXpII32_16BGR555 29 SDL_FUNC _ConvertMMXpII32_16BGR555
30 30
31 EXTERN _mmxreturn
32
33 ;; Macros for conversion routines 31 ;; Macros for conversion routines
34 32
35 %macro _push_immq_mask 1 33 %macro _push_immq_mask 1
36 push dword %1 34 push dword %1
37 push dword %1 35 push dword %1
119 add esi, BYTE 4 117 add esi, BYTE 4
120 add edi, BYTE 3 118 add edi, BYTE 3
121 dec ecx 119 dec ecx
122 jnz .L3 120 jnz .L3
123 .L4: 121 .L4:
124 jmp _mmxreturn 122 return
125 123
126 124
127 125
128 _ConvertMMXpII32_16RGB565: 126 _ConvertMMXpII32_16RGB565:
129 127
188 add edi, BYTE 2 186 add edi, BYTE 2
189 dec ecx 187 dec ecx
190 jnz .L3 188 jnz .L3
191 189
192 .L4: 190 .L4:
193 jmp _mmxreturn 191 retn
194 192
195 193
196 _ConvertMMXpII32_16BGR565: 194 _ConvertMMXpII32_16BGR565:
197 195
198 load_immq mm5, mmx32_rgb565_r 196 load_immq mm5, mmx32_rgb565_r
258 add edi, BYTE 2 256 add edi, BYTE 2
259 dec edx 257 dec edx
260 jnz .L3 258 jnz .L3
261 259
262 .L4: 260 .L4:
263 jmp _mmxreturn 261 retn
264 262
265 _ConvertMMXpII32_16BGR555: 263 _ConvertMMXpII32_16BGR555:
266 264
267 ; the 16BGR555 converter is identical to the RGB555 one, 265 ; the 16BGR555 converter is identical to the RGB555 one,
268 ; except it uses a different multiplier for the pmaddwd 266 ; except it uses a different multiplier for the pmaddwd
398 396
399 dec ecx 397 dec ecx
400 jnz .L3 398 jnz .L3
401 399
402 .L4: 400 .L4:
403 jmp _mmxreturn 401 retn
404 402
405 %ifidn __OUTPUT_FORMAT__,elf 403 %ifidn __OUTPUT_FORMAT__,elf
406 section .note.GNU-stack noalloc noexec nowrite progbits 404 section .note.GNU-stack noalloc noexec nowrite progbits
407 %endif 405 %endif