]> git.pld-linux.org Git - packages/Mesa.git/blob - Mesa-dri-asm.patch
- add missing asm files
[packages/Mesa.git] / Mesa-dri-asm.patch
1 --- Mesa-6.3.2.orig/Makefile    2005-08-16 16:36:04.000000000 -0700
2 +++ Mesa-6.3.2/Makefile 2005-08-21 20:59:37.000000000 -0700
3 @@ -270,7 +270,7 @@
4         $(DIRECTORY)/src/mesa/drivers/dri/common/xmlpool/*.[ch]         \
5         $(DIRECTORY)/src/mesa/drivers/dri/common/xmlpool/*.po           \
6         $(DIRECTORY)/src/mesa/drivers/dri/dri_client/imports/*.h        \
7 -       $(DIRECTORY)/src/mesa/drivers/dri/*/*.[ch]                      \
8 +       $(DIRECTORY)/src/mesa/drivers/dri/*/*.[chS]                     \
9         $(DIRECTORY)/src/mesa/drivers/dri/*/Makefile                    \
10         $(DIRECTORY)/src/mesa/drivers/dri/*/Doxyfile                    \
11         $(DIRECTORY)/src/mesa/drivers/dri/*/server/*.[ch]
12 diff -urN Mesa-6.3.2.orig/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S Mesa-6.3.2/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S
13 --- Mesa-6.3.2.orig/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S 1969-12-31 16:00:00.000000000 -0800
14 +++ Mesa-6.3.2/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S      2004-06-02 15:09:11.000000000 -0700
15 @@ -0,0 +1,495 @@
16 +/* $XFree86: xc/lib/GL/mesa/src/drv/r200/r200_vtxtmp_x86.S,v 1.2 2002/11/07 18:31:59 tsi Exp $ */
17 +/**************************************************************************
18 +
19 +Copyright 2002 Tungsten Graphics Inc., Cedar Park, Texas.
20 +
21 +All Rights Reserved.
22 +
23 +Permission is hereby granted, free of charge, to any person obtaining a
24 +copy of this software and associated documentation files (the "Software"),
25 +to deal in the Software without restriction, including without limitation
26 +on the rights to use, copy, modify, merge, publish, distribute, sub
27 +license, and/or sell copies of the Software, and to permit persons to whom
28 +the Software is furnished to do so, subject to the following conditions:
29 +
30 +The above copyright notice and this permission notice (including the next
31 +paragraph) shall be included in all copies or substantial portions of the
32 +Software.
33 +
34 +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
35 +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
36 +FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
37 +ATI, TUNGSTEN GRAPHICS AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM,
38 +DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
39 +OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
40 +USE OR OTHER DEALINGS IN THE SOFTWARE.
41 +
42 +**************************************************************************/
43 +
44 +#define GLOBL( x )     \
45 +.globl x;              \
46 +x:
47 +
48 +.data
49 +.align 4
50 +
51 +/*
52 +       vertex 3f vertex size 4
53 +*/
54 +       
55 +GLOBL ( _x86_Vertex3f_4 )
56 +       movl    (0), %ecx
57 +       movl    4(%esp), %eax
58 +       movl    8(%esp), %edx
59 +       movl    %eax, (%ecx)
60 +       movl    %edx, 4(%ecx)
61 +       movl    12(%esp), %eax
62 +       movl    (0), %edx
63 +       movl    %eax, 8(%ecx)
64 +       movl    %edx, 12(%ecx)
65 +       movl    (0), %eax
66 +       addl    $16, %ecx
67 +       dec     %eax
68 +       movl    %ecx, (0)
69 +       movl    %eax, (0)
70 +       je      .1 
71 +       ret
72 +.1:    jmp     *0
73 +       
74 +GLOBL ( _x86_Vertex3f_4_end )
75 +
76 +/*
77 +       vertex 3f vertex size 6
78 +*/
79 +GLOBL ( _x86_Vertex3f_6 )
80 +       push    %edi
81 +       movl    (0), %edi
82 +       movl    8(%esp), %eax
83 +       movl    12(%esp), %edx
84 +       movl    16(%esp), %ecx
85 +       movl    %eax, (%edi)
86 +       movl    %edx, 4(%edi)
87 +       movl    %ecx, 8(%edi)
88 +       movl    (0), %eax
89 +       movl    (0), %edx
90 +       movl    (0), %ecx
91 +       movl    %eax, 12(%edi)
92 +       movl    %edx, 16(%edi)
93 +       movl    %ecx, 20(%edi)
94 +       addl    $24, %edi
95 +       movl    (0), %eax
96 +       movl    %edi, (0)
97 +       dec     %eax
98 +       pop     %edi
99 +       movl    %eax, (0)
100 +       je      .2
101 +       ret
102 +.2:    jmp     *0
103 +GLOBL ( _x86_Vertex3f_6_end )
104 +/*
105 +       vertex 3f generic size
106 +*/
107 +GLOBL ( _x86_Vertex3f )
108 +       push    %edi
109 +       push    %esi
110 +       movl    $0, %esi
111 +       movl    (0), %edi
112 +       movl    12(%esp), %eax
113 +       movl    16(%esp), %edx
114 +       movl    20(%esp), %ecx
115 +       movl    %eax, (%edi)
116 +       movl    %edx, 4(%edi)
117 +       movl    %ecx, 8(%edi)
118 +       addl    $12, %edi
119 +       movl    $0, %ecx
120 +       repz
121 +       movsl %ds:(%esi), %es:(%edi)
122 +       movl    (0), %eax
123 +       movl    %edi, (0)
124 +       dec     %eax
125 +       movl    %eax, (0)
126 +       pop     %esi
127 +       pop     %edi
128 +       je      .3
129 +       ret
130 +.3:    jmp     *0
131 +
132 +GLOBL ( _x86_Vertex3f_end )
133 +
134 +/*
135 +       Vertex 3fv vertex size 6
136 +*/
137 +GLOBL ( _x86_Vertex3fv_6 )
138 +       movl    (0), %eax
139 +       movl    4(%esp), %ecx
140 +       movl    (%ecx), %edx
141 +       movl    %edx, (%eax)
142 +       movl    4(%ecx), %edx
143 +       movl    8(%ecx), %ecx
144 +       movl    %edx, 4(%eax)
145 +       movl    %ecx, 8(%eax)
146 +       movl    (28), %edx
147 +       movl    (32), %ecx
148 +       movl    %edx, 12(%eax)
149 +       movl    %ecx, 16(%eax)
150 +       movl    (36), %edx
151 +       movl    %edx, 20(%eax)
152 +       addl    $24, %eax
153 +       movl    %eax, 0
154 +       movl    4, %eax
155 +       dec     %eax
156 +       movl    %eax, 4
157 +       je      .4
158 +       ret
159 +.4:    jmp    *8
160 +       
161 +GLOBL ( _x86_Vertex3fv_6_end )
162 +
163 +/*
164 +       Vertex 3fv vertex size 8
165 +*/
166 +GLOBL ( _x86_Vertex3fv_8 )
167 +       movl    (0), %eax
168 +       movl    4(%esp), %ecx
169 +       movl    (%ecx), %edx
170 +       movl    %edx ,(%eax)
171 +       movl    4(%ecx) ,%edx
172 +       movl    8(%ecx) ,%ecx
173 +       movl    %edx, 4(%eax)
174 +       movl    %ecx, 8(%eax)
175 +       movl    (28), %edx
176 +       movl    (32), %ecx
177 +       movl    %edx, 12(%eax)
178 +       movl    %ecx, 16(%eax)
179 +       movl    (28), %edx
180 +       movl    (32), %ecx
181 +       movl    %edx, 20(%eax)
182 +       movl    %ecx, 24(%eax)
183 +       movl    (36), %edx
184 +       movl    %edx, 28(%eax)
185 +       addl    $32, %eax
186 +       movl    %eax, (0)
187 +       movl    4, %eax
188 +       dec     %eax
189 +       movl    %eax, (4)
190 +       je      .5
191 +       ret
192 +.5:    jmp    *8
193 +       
194 +GLOBL ( _x86_Vertex3fv_8_end )
195 +
196 +/*
197 +       Vertex 3fv generic vertex size
198 +*/
199 +GLOBL ( _x86_Vertex3fv )
200 +       movl    4(%esp), %edx
201 +       push    %edi
202 +       push    %esi
203 +       movl    (0x1010101), %edi
204 +       movl    (%edx), %eax
205 +       movl    4(%edx), %ecx
206 +       movl    8(%edx), %esi
207 +       movl    %eax, (%edi)
208 +       movl    %ecx, 4(%edi)
209 +       movl    %esi, 8(%edi)
210 +       addl    $12, %edi
211 +       movl    $6, %ecx
212 +       movl    $0x58, %esi
213 +       repz
214 +       movsl %ds:(%esi), %es:(%edi)
215 +       movl    %edi, (0x1010101)
216 +       movl    (0x2020202), %eax
217 +       pop     %esi
218 +       pop     %edi
219 +       dec     %eax
220 +       movl    %eax, (0x2020202)
221 +       je      .6
222 +       ret
223 +.6:    jmp    *0
224 +GLOBL ( _x86_Vertex3fv_end )
225 +
226 +
227 +/**
228 + * Generic handler for 2 float format data.  This can be used for
229 + * TexCoord2f and possibly other functions.
230 + */
231 +
232 +GLOBL ( _x86_Attribute2f )
233 +       movl    $0x0, %edx
234 +       movl    4(%esp), %eax
235 +       movl    8(%esp), %ecx
236 +       movl    %eax, (%edx)
237 +       movl    %ecx, 4(%edx)
238 +       ret
239 +GLOBL ( _x86_Attribute2f_end )
240 +
241 +
242 +/**
243 + * Generic handler for 2 float vector format data.  This can be used for
244 + * TexCoord2fv and possibly other functions.
245 + */
246 +
247 +GLOBL( _x86_Attribute2fv)
248 +       movl 4(%esp), %eax      /* load 'v' off stack */
249 +       movl (%eax), %ecx       /* load v[0] */
250 +       movl 4(%eax), %eax      /* load v[1] */
251 +       movl %ecx, 0            /* store v[0] to current vertex */
252 +       movl %eax, 4            /* store v[1] to current vertex */
253 +       ret
254 +GLOBL ( _x86_Attribute2fv_end )
255 +
256 +
257 +/**
258 + * Generic handler for 3 float format data.  This can be used for
259 + * Normal3f, Color3f (when the color target is also float), or
260 + * TexCoord3f.
261 + */
262 +
263 +GLOBL ( _x86_Attribute3f )
264 +       movl    4(%esp), %ecx
265 +       movl    8(%esp), %edx
266 +       movl    12(%esp), %eax
267 +       movl    %ecx, 0
268 +       movl    %edx, 4
269 +       movl    %eax, 8
270 +       ret
271 +GLOBL ( _x86_Attribute3f_end )
272 +
273 +/**
274 + * Generic handler for 3 float vector format data.  This can be used for
275 + * Normal3f, Color3f (when the color target is also float), or
276 + * TexCoord3f.
277 + */
278 +
279 +GLOBL( _x86_Attribute3fv)
280 +       movl 4(%esp), %eax      /* load 'v' off stack */
281 +       movl (%eax), %ecx       /* load v[0] */
282 +       movl 4(%eax), %edx      /* load v[1] */
283 +       movl 8(%eax), %eax      /* load v[2] */
284 +       movl %ecx, 0            /* store v[0] to current vertex */
285 +       movl %edx, 4            /* store v[1] to current vertex */
286 +       movl %eax, 8            /* store v[2] to current vertex */
287 +       ret
288 +GLOBL ( _x86_Attribute3fv_end )
289 +
290 +
291 +/*
292 +       Color 4ubv_ub
293 +*/
294 +GLOBL ( _x86_Color4ubv_ub )
295 +       movl 4(%esp), %eax
296 +       movl $0x12345678, %edx
297 +       movl (%eax), %eax
298 +       movl %eax, (%edx)
299 +       ret
300 +GLOBL ( _x86_Color4ubv_ub_end )
301 +
302 +/*
303 +       Color 4ubv 4f
304 +*/
305 +GLOBL ( _x86_Color4ubv_4f )
306 +       push    %ebx
307 +       movl    $0, %edx
308 +       xor     %eax, %eax
309 +       xor     %ecx, %ecx
310 +       movl    8(%esp), %ebx
311 +       movl    (%ebx), %ebx
312 +       mov     %bl, %al
313 +       mov     %bh, %cl
314 +       movl    (%edx,%eax,4),%eax
315 +       movl    (%edx,%ecx,4),%ecx
316 +       movl    %eax, (0xdeadbeaf)
317 +       movl    %ecx, (0xdeadbeaf)
318 +       xor     %eax, %eax
319 +       xor     %ecx, %ecx
320 +       shr     $16, %ebx
321 +       mov     %bl, %al
322 +       mov     %bh, %cl
323 +       movl    (%edx,%eax,4), %eax
324 +       movl    (%edx,%ecx,4), %ecx
325 +       movl    %eax, (0xdeadbeaf)
326 +       movl    %ecx, (0xdeadbeaf)
327 +       pop     %ebx
328 +       ret
329 +GLOBL ( _x86_Color4ubv_4f_end )
330 +
331 +/*
332 +
333 +       Color4ub_ub
334 +*/
335 +GLOBL( _x86_Color4ub_ub )
336 +       push    %ebx
337 +       movl    8(%esp), %eax
338 +       movl    12(%esp), %edx
339 +       movl    16(%esp), %ecx
340 +       movl    20(%esp), %ebx
341 +       mov     %al, (0)
342 +       mov     %dl, (0)
343 +       mov     %cl, (0)
344 +       mov     %bl, (0)
345 +       pop     %ebx
346 +       ret
347 +GLOBL( _x86_Color4ub_ub_end )
348 +
349 +
350 +/* \todo: change the "and $7, %eax" to something like "target & 4 ? target & 5 : target & 3)" */
351 +/*
352 +       MultiTexCoord2fv st0/st1
353 +*/
354 +GLOBL( _x86_MultiTexCoord2fv )
355 +       movl    4(%esp), %eax
356 +       movl    8(%esp), %ecx
357 +       and     $7, %eax
358 +       movl    (%ecx), %edx
359 +       shl     $3, %eax
360 +       movl    4(%ecx), %ecx
361 +       movl    %edx, 0xdeadbeef(%eax)
362 +       movl    %ecx, 0xdeadbeef(%eax)
363 +       ret
364 +GLOBL( _x86_MultiTexCoord2fv_end )
365 +
366 +/*
367 +       MultiTexCoord2fv
368 +*/
369 +
370 +GLOBL( _x86_MultiTexCoord2fv_2 )
371 +       movl    4(%esp,1), %eax
372 +       movl    8(%esp,1), %ecx
373 +       and     $0x7, %eax
374 +       movl    0(,%eax,4), %edx
375 +       movl    (%ecx), %eax
376 +       movl    %eax, (%edx)
377 +       movl    4(%ecx), %eax
378 +       movl    %eax, 4(%edx)
379 +       ret
380 +GLOBL( _x86_MultiTexCoord2fv_2_end )
381 +
382 +/*
383 +       MultiTexCoord2f st0/st1
384 +*/
385 +GLOBL( _x86_MultiTexCoord2f )
386 +       movl    4(%esp), %eax
387 +       movl    8(%esp), %edx
388 +       movl    12(%esp), %ecx
389 +       and     $7, %eax
390 +       shl     $3, %eax
391 +       movl    %edx, 0xdeadbeef(%eax)
392 +       movl    %ecx, 0xdeadbeef(%eax)
393 +       ret
394 +GLOBL( _x86_MultiTexCoord2f_end )
395 +
396 +/*
397 +       MultiTexCoord2f
398 +*/
399 +GLOBL( _x86_MultiTexCoord2f_2 )
400 +       movl    4(%esp), %eax
401 +       movl    8(%esp), %edx
402 +       movl    12(%esp,1), %ecx
403 +       and     $7,%eax
404 +       movl    0(,%eax,4), %eax
405 +       movl    %edx, (%eax)
406 +       movl    %ecx, 4(%eax)
407 +       ret
408 +GLOBL( _x86_MultiTexCoord2f_2_end )
409 +
410 +#if defined(USE_SSE_ASM)
411 +/**
412 + * This can be used as a template for either Color3fv (when the color
413 + * target is also a 3f) or Normal3fv.
414 + */
415 +
416 +GLOBL( _sse_Attribute3fv )
417 +       movl    4(%esp), %eax
418 +       movlps  (%eax), %xmm0
419 +       movl    8(%eax), %eax
420 +       movlps  %xmm0, 0
421 +       movl    %eax, 8
422 +       ret
423 +GLOBL( _sse_Attribute3fv_end )
424 +
425 +/**
426 + * This can be used as a template for either Color3f (when the color
427 + * target is also a 3f) or Normal3f.
428 + */
429 +
430 +GLOBL( _sse_Attribute3f )
431 +       movlps  4(%esp), %xmm0
432 +       movl    12(%esp), %eax
433 +       movlps  %xmm0, 0
434 +       movl    %eax, 8
435 +       ret
436 +GLOBL( _sse_Attribute3f_end )
437 +
438 +
439 +/**
440 + * Generic handler for 2 float vector format data.  This can be used for
441 + * TexCoord2fv and possibly other functions.
442 + */
443 +
444 +GLOBL( _sse_Attribute2fv )
445 +       movl    4(%esp), %eax
446 +       movlps  (%eax), %xmm0
447 +       movlps  %xmm0, 0
448 +       ret
449 +GLOBL( _sse_Attribute2fv_end )
450 +
451 +
452 +/**
453 + * Generic handler for 2 float format data.  This can be used for
454 + * TexCoord2f and possibly other functions.
455 + */
456 +
457 +GLOBL( _sse_Attribute2f )
458 +       movlps  4(%esp), %xmm0
459 +       movlps  %xmm0, 0
460 +       ret
461 +GLOBL( _sse_Attribute2f_end )
462 +
463 +/*
464 +       MultiTexCoord2fv st0/st1
465 +*/
466 +GLOBL( _sse_MultiTexCoord2fv )
467 +       movl    4(%esp), %eax
468 +       movl    8(%esp), %ecx
469 +       and     $7, %eax
470 +       movlps  (%ecx), %xmm0
471 +       movlps  %xmm0, 0xdeadbeef(,%eax,8)
472 +       ret
473 +GLOBL( _sse_MultiTexCoord2fv_end )
474 +
475 +/*
476 +       MultiTexCoord2fv
477 +*/
478 +GLOBL( _sse_MultiTexCoord2fv_2 )
479 +       movl    4(%esp), %eax
480 +       movl    8(%esp), %ecx
481 +       and     $0x7, %eax
482 +       movl    0(,%eax,4), %edx
483 +       movlps  (%ecx), %xmm0
484 +       movlps  %xmm0, (%edx)
485 +       ret
486 +GLOBL( _sse_MultiTexCoord2fv_2_end )
487 +
488 +/*
489 +       MultiTexCoord2f st0/st1
490 +*/
491 +GLOBL( _sse_MultiTexCoord2f )
492 +       movl    4(%esp), %eax
493 +       and     $7, %eax
494 +       movlps  8(%esp), %xmm0
495 +       movlps  %xmm0, 0xdeadbeef(,%eax,8)
496 +       ret
497 +GLOBL( _sse_MultiTexCoord2f_end )
498 +
499 +/*
500 +       MultiTexCoord2f
501 +*/
502 +GLOBL( _sse_MultiTexCoord2f_2 )
503 +       movl    4(%esp), %eax
504 +       movlps  8(%esp), %xmm0
505 +       and     $7,%eax
506 +       movl    0(,%eax,4), %eax
507 +       movlps  %xmm0, (%eax)
508 +       ret
509 +GLOBL( _sse_MultiTexCoord2f_2_end )
510 +#endif
511 diff -urN Mesa-6.3.2.orig/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S Mesa-6.3.2/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S
512 --- Mesa-6.3.2.orig/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S     1969-12-31 16:00:00.000000000 -0800
513 +++ Mesa-6.3.2/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S  2004-04-26 03:10:23.000000000 -0700
514 @@ -0,0 +1,494 @@
515 +/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_vtxtmp_x86.S,v 1.1 2002/10/30 12:51:58 alanh Exp $ */
516 +/**************************************************************************
517 +
518 +Copyright 2002 Tungsten Graphics Inc., Cedar Park, Texas.
519 +
520 +All Rights Reserved.
521 +
522 +Permission is hereby granted, free of charge, to any person obtaining a
523 +copy of this software and associated documentation files (the "Software"),
524 +to deal in the Software without restriction, including without limitation
525 +on the rights to use, copy, modify, merge, publish, distribute, sub
526 +license, and/or sell copies of the Software, and to permit persons to whom
527 +the Software is furnished to do so, subject to the following conditions:
528 +
529 +The above copyright notice and this permission notice (including the next
530 +paragraph) shall be included in all copies or substantial portions of the
531 +Software.
532 +
533 +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
534 +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
535 +FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
536 +ATI, TUNGSTEN GRAPHICS AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM,
537 +DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
538 +OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
539 +USE OR OTHER DEALINGS IN THE SOFTWARE.
540 +
541 +**************************************************************************/
542 +
543 +#define GLOBL( x )     \
544 +.globl x;              \
545 +x:
546 +
547 +.data
548 +.align 4
549 +
550 +/*
551 +       vertex 3f vertex size 4
552 +*/
553 +       
554 +GLOBL ( _x86_Vertex3f_4 )
555 +       movl    (0), %ecx
556 +       movl    4(%esp), %eax
557 +       movl    8(%esp), %edx
558 +       movl    %eax, (%ecx)
559 +       movl    %edx, 4(%ecx)
560 +       movl    12(%esp), %eax
561 +       movl    (0), %edx
562 +       movl    %eax, 8(%ecx)
563 +       movl    %edx, 12(%ecx)
564 +       movl    (0), %eax
565 +       addl    $16, %ecx
566 +       dec     %eax
567 +       movl    %ecx, (0)
568 +       movl    %eax, (0)
569 +       je      .1 
570 +       ret
571 +.1:    jmp     *0
572 +       
573 +GLOBL ( _x86_Vertex3f_4_end )
574 +
575 +/*
576 +       vertex 3f vertex size 6
577 +*/
578 +GLOBL ( _x86_Vertex3f_6 )
579 +       push    %edi
580 +       movl    (0), %edi
581 +       movl    8(%esp), %eax
582 +       movl    12(%esp), %edx
583 +       movl    16(%esp), %ecx
584 +       movl    %eax, (%edi)
585 +       movl    %edx, 4(%edi)
586 +       movl    %ecx, 8(%edi)
587 +       movl    (0), %eax
588 +       movl    (0), %edx
589 +       movl    (0), %ecx
590 +       movl    %eax, 12(%edi)
591 +       movl    %edx, 16(%edi)
592 +       movl    %ecx, 20(%edi)
593 +       addl    $24, %edi
594 +       movl    (0), %eax
595 +       movl    %edi, (0)
596 +       dec     %eax
597 +       pop     %edi
598 +       movl    %eax, (0)
599 +       je      .2
600 +       ret
601 +.2:    jmp     *0
602 +GLOBL ( _x86_Vertex3f_6_end )
603 +/*
604 +       vertex 3f generic size
605 +*/
606 +GLOBL ( _x86_Vertex3f )
607 +       push    %edi
608 +       push    %esi
609 +       movl    $0, %esi
610 +       movl    (0), %edi
611 +       movl    12(%esp), %eax
612 +       movl    16(%esp), %edx
613 +       movl    20(%esp), %ecx
614 +       movl    %eax, (%edi)
615 +       movl    %edx, 4(%edi)
616 +       movl    %ecx, 8(%edi)
617 +       addl    $12, %edi
618 +       movl    $0, %ecx
619 +       repz
620 +       movsl %ds:(%esi), %es:(%edi)
621 +       movl    (0), %eax
622 +       movl    %edi, (0)
623 +       dec     %eax
624 +       movl    %eax, (0)
625 +       pop     %esi
626 +       pop     %edi
627 +       je      .3
628 +       ret
629 +.3:    jmp     *0
630 +
631 +GLOBL ( _x86_Vertex3f_end )
632 +
633 +/*
634 +       Vertex 3fv vertex size 6
635 +*/
636 +GLOBL ( _x86_Vertex3fv_6 )
637 +       movl    (0), %eax
638 +       movl    4(%esp), %ecx
639 +       movl    (%ecx), %edx
640 +       movl    %edx, (%eax)
641 +       movl    4(%ecx), %edx
642 +       movl    8(%ecx), %ecx
643 +       movl    %edx, 4(%eax)
644 +       movl    %ecx, 8(%eax)
645 +       movl    (28), %edx
646 +       movl    (32), %ecx
647 +       movl    %edx, 12(%eax)
648 +       movl    %ecx, 16(%eax)
649 +       movl    (36), %edx
650 +       movl    %edx, 20(%eax)
651 +       addl    $24, %eax
652 +       movl    %eax, 0
653 +       movl    4, %eax
654 +       dec     %eax
655 +       movl    %eax, 4
656 +       je      .4
657 +       ret
658 +.4:    jmp    *8
659 +       
660 +GLOBL ( _x86_Vertex3fv_6_end )
661 +
662 +/*
663 +       Vertex 3fv vertex size 8
664 +*/
665 +GLOBL ( _x86_Vertex3fv_8 )
666 +       movl    (0), %eax
667 +       movl    4(%esp), %ecx
668 +       movl    (%ecx), %edx
669 +       movl    %edx ,(%eax)
670 +       movl    4(%ecx) ,%edx
671 +       movl    8(%ecx) ,%ecx
672 +       movl    %edx, 4(%eax)
673 +       movl    %ecx, 8(%eax)
674 +       movl    (28), %edx
675 +       movl    (32), %ecx
676 +       movl    %edx, 12(%eax)
677 +       movl    %ecx, 16(%eax)
678 +       movl    (28), %edx
679 +       movl    (32), %ecx
680 +       movl    %edx, 20(%eax)
681 +       movl    %ecx, 24(%eax)
682 +       movl    (36), %edx
683 +       movl    %edx, 28(%eax)
684 +       addl    $32, %eax
685 +       movl    %eax, (0)
686 +       movl    4, %eax
687 +       dec     %eax
688 +       movl    %eax, (4)
689 +       je      .5
690 +       ret
691 +.5:    jmp    *8
692 +       
693 +GLOBL ( _x86_Vertex3fv_8_end )
694 +
695 +/*
696 +       Vertex 3fv generic vertex size
697 +*/
698 +GLOBL ( _x86_Vertex3fv )
699 +       movl    4(%esp), %edx
700 +       push    %edi
701 +       push    %esi
702 +       movl    (0x1010101), %edi
703 +       movl    (%edx), %eax
704 +       movl    4(%edx), %ecx
705 +       movl    8(%edx), %esi
706 +       movl    %eax, (%edi)
707 +       movl    %ecx, 4(%edi)
708 +       movl    %esi, 8(%edi)
709 +       addl    $12, %edi
710 +       movl    $6, %ecx
711 +       movl    $0x58, %esi
712 +       repz
713 +       movsl %ds:(%esi), %es:(%edi)
714 +       movl    %edi, (0x1010101)
715 +       movl    (0x2020202), %eax
716 +       pop     %esi
717 +       pop     %edi
718 +       dec     %eax
719 +       movl    %eax, (0x2020202)
720 +       je      .6
721 +       ret
722 +.6:    jmp    *0
723 +GLOBL ( _x86_Vertex3fv_end )
724 +
725 +
726 +/**
727 + * Generic handler for 2 float format data.  This can be used for
728 + * TexCoord2f and possibly other functions.
729 + */
730 +
731 +GLOBL ( _x86_Attribute2f )
732 +       movl    $0x0, %edx
733 +       movl    4(%esp), %eax
734 +       movl    8(%esp), %ecx
735 +       movl    %eax, (%edx)
736 +       movl    %ecx, 4(%edx)
737 +       ret
738 +GLOBL ( _x86_Attribute2f_end )
739 +
740 +
741 +/**
742 + * Generic handler for 2 float vector format data.  This can be used for
743 + * TexCoord2fv and possibly other functions.
744 + */
745 +
746 +GLOBL( _x86_Attribute2fv)
747 +       movl 4(%esp), %eax      /* load 'v' off stack */
748 +       movl (%eax), %ecx       /* load v[0] */
749 +       movl 4(%eax), %eax      /* load v[1] */
750 +       movl %ecx, 0            /* store v[0] to current vertex */
751 +       movl %eax, 4            /* store v[1] to current vertex */
752 +       ret
753 +GLOBL ( _x86_Attribute2fv_end )
754 +
755 +
756 +/**
757 + * Generic handler for 3 float format data.  This can be used for
758 + * Normal3f, Color3f (when the color target is also float), or
759 + * TexCoord3f.
760 + */
761 +
762 +GLOBL ( _x86_Attribute3f )
763 +       movl    4(%esp), %ecx
764 +       movl    8(%esp), %edx
765 +       movl    12(%esp), %eax
766 +       movl    %ecx, 0
767 +       movl    %edx, 4
768 +       movl    %eax, 8
769 +       ret
770 +GLOBL ( _x86_Attribute3f_end )
771 +
772 +/**
773 + * Generic handler for 3 float vector format data.  This can be used for
774 + * Normal3f, Color3f (when the color target is also float), or
775 + * TexCoord3f.
776 + */
777 +
778 +GLOBL( _x86_Attribute3fv)
779 +       movl 4(%esp), %eax      /* load 'v' off stack */
780 +       movl (%eax), %ecx       /* load v[0] */
781 +       movl 4(%eax), %edx      /* load v[1] */
782 +       movl 8(%eax), %eax      /* load v[2] */
783 +       movl %ecx, 0            /* store v[0] to current vertex */
784 +       movl %edx, 4            /* store v[1] to current vertex */
785 +       movl %eax, 8            /* store v[2] to current vertex */
786 +       ret
787 +GLOBL ( _x86_Attribute3fv_end )
788 +
789 +
790 +/*
791 +       Color 4ubv_ub
792 +*/
793 +GLOBL ( _x86_Color4ubv_ub )
794 +       movl 4(%esp), %eax
795 +       movl $0x12345678, %edx
796 +       movl (%eax), %eax
797 +       movl %eax, (%edx)
798 +       ret
799 +GLOBL ( _x86_Color4ubv_ub_end )
800 +
801 +/*
802 +       Color 4ubv 4f
803 +*/
804 +GLOBL ( _x86_Color4ubv_4f )
805 +       push    %ebx
806 +       movl    $0, %edx
807 +       xor     %eax, %eax
808 +       xor     %ecx, %ecx
809 +       movl    8(%esp), %ebx
810 +       movl    (%ebx), %ebx
811 +       mov     %bl, %al
812 +       mov     %bh, %cl
813 +       movl    (%edx,%eax,4),%eax
814 +       movl    (%edx,%ecx,4),%ecx
815 +       movl    %eax, (0xdeadbeaf)
816 +       movl    %ecx, (0xdeadbeaf)
817 +       xor     %eax, %eax
818 +       xor     %ecx, %ecx
819 +       shr     $16, %ebx
820 +       mov     %bl, %al
821 +       mov     %bh, %cl
822 +       movl    (%edx,%eax,4), %eax
823 +       movl    (%edx,%ecx,4), %ecx
824 +       movl    %eax, (0xdeadbeaf)
825 +       movl    %ecx, (0xdeadbeaf)
826 +       pop     %ebx
827 +       ret
828 +GLOBL ( _x86_Color4ubv_4f_end )
829 +
830 +/*
831 +
832 +       Color4ub_ub
833 +*/
834 +GLOBL( _x86_Color4ub_ub )
835 +       push    %ebx
836 +       movl    8(%esp), %eax
837 +       movl    12(%esp), %edx
838 +       movl    16(%esp), %ecx
839 +       movl    20(%esp), %ebx
840 +       mov     %al, (0)
841 +       mov     %dl, (0)
842 +       mov     %cl, (0)
843 +       mov     %bl, (0)
844 +       pop     %ebx
845 +       ret
846 +GLOBL( _x86_Color4ub_ub_end )
847 +
848 +
849 +/*
850 +       MultiTexCoord2fv st0/st1
851 +*/
852 +GLOBL( _x86_MultiTexCoord2fv )
853 +       movl    4(%esp), %eax
854 +       movl    8(%esp), %ecx
855 +       and     $1, %eax
856 +       movl    (%ecx), %edx
857 +       shl     $3, %eax
858 +       movl    4(%ecx), %ecx
859 +       movl    %edx, 0xdeadbeef(%eax)
860 +       movl    %ecx, 0xdeadbeef(%eax)
861 +       ret
862 +GLOBL( _x86_MultiTexCoord2fv_end )
863 +
864 +/*
865 +       MultiTexCoord2fv
866 +*/
867 +
868 +GLOBL( _x86_MultiTexCoord2fv_2 )
869 +       movl    4(%esp,1), %eax
870 +       movl    8(%esp,1), %ecx
871 +       and     $0x1, %eax
872 +       movl    0(,%eax,4), %edx
873 +       movl    (%ecx), %eax
874 +       movl    %eax, (%edx)
875 +       movl    4(%ecx), %eax
876 +       movl    %eax, 4(%edx)
877 +       ret
878 +GLOBL( _x86_MultiTexCoord2fv_2_end )
879 +
880 +/*
881 +       MultiTexCoord2f st0/st1
882 +*/
883 +GLOBL( _x86_MultiTexCoord2f )
884 +       movl    4(%esp), %eax
885 +       movl    8(%esp), %edx
886 +       movl    12(%esp), %ecx
887 +       and     $1, %eax
888 +       shl     $3, %eax
889 +       movl    %edx, 0xdeadbeef(%eax)
890 +       movl    %ecx, 0xdeadbeef(%eax)
891 +       ret
892 +GLOBL( _x86_MultiTexCoord2f_end )
893 +
894 +/*
895 +       MultiTexCoord2f
896 +*/
897 +GLOBL( _x86_MultiTexCoord2f_2 )
898 +       movl    4(%esp), %eax
899 +       movl    8(%esp), %edx
900 +       movl    12(%esp,1), %ecx
901 +       and     $1,%eax
902 +       movl    0(,%eax,4), %eax
903 +       movl    %edx, (%eax)
904 +       movl    %ecx, 4(%eax)
905 +       ret
906 +GLOBL( _x86_MultiTexCoord2f_2_end )
907 +
908 +#if defined(USE_SSE_ASM)
909 +/**
910 + * This can be used as a template for either Color3fv (when the color
911 + * target is also a 3f) or Normal3fv.
912 + */
913 +
914 +GLOBL( _sse_Attribute3fv )
915 +       movl    4(%esp), %eax
916 +       movlps  (%eax), %xmm0
917 +       movl    8(%eax), %eax
918 +       movlps  %xmm0, 0
919 +       movl    %eax, 8
920 +       ret
921 +GLOBL( _sse_Attribute3fv_end )
922 +
923 +/**
924 + * This can be used as a template for either Color3f (when the color
925 + * target is also a 3f) or Normal3f.
926 + */
927 +
928 +GLOBL( _sse_Attribute3f )
929 +       movlps  4(%esp), %xmm0
930 +       movl    12(%esp), %eax
931 +       movlps  %xmm0, 0
932 +       movl    %eax, 8
933 +       ret
934 +GLOBL( _sse_Attribute3f_end )
935 +
936 +
937 +/**
938 + * Generic handler for 2 float vector format data.  This can be used for
939 + * TexCoord2fv and possibly other functions.
940 + */
941 +
942 +GLOBL( _sse_Attribute2fv )
943 +       movl    4(%esp), %eax
944 +       movlps  (%eax), %xmm0
945 +       movlps  %xmm0, 0
946 +       ret
947 +GLOBL( _sse_Attribute2fv_end )
948 +
949 +
950 +/**
951 + * Generic handler for 2 float format data.  This can be used for
952 + * TexCoord2f and possibly other functions.
953 + */
954 +
955 +GLOBL( _sse_Attribute2f )
956 +       movlps  4(%esp), %xmm0
957 +       movlps  %xmm0, 0
958 +       ret
959 +GLOBL( _sse_Attribute2f_end )
960 +
961 +/*
962 +       MultiTexCoord2fv st0/st1
963 +*/
964 +GLOBL( _sse_MultiTexCoord2fv )
965 +       movl    4(%esp), %eax
966 +       movl    8(%esp), %ecx
967 +       and     $1, %eax
968 +       movlps  (%ecx), %xmm0
969 +       movlps  %xmm0, 0xdeadbeef(,%eax,8)
970 +       ret
971 +GLOBL( _sse_MultiTexCoord2fv_end )
972 +
973 +/*
974 +       MultiTexCoord2fv
975 +*/
976 +GLOBL( _sse_MultiTexCoord2fv_2 )
977 +       movl    4(%esp), %eax
978 +       movl    8(%esp), %ecx
979 +       and     $0x1, %eax
980 +       movl    0(,%eax,4), %edx
981 +       movlps  (%ecx), %xmm0
982 +       movlps  %xmm0, (%edx)
983 +       ret
984 +GLOBL( _sse_MultiTexCoord2fv_2_end )
985 +
986 +/*
987 +       MultiTexCoord2f st0/st1
988 +*/
989 +GLOBL( _sse_MultiTexCoord2f )
990 +       movl    4(%esp), %eax
991 +       and     $1, %eax
992 +       movlps  8(%esp), %xmm0
993 +       movlps  %xmm0, 0xdeadbeef(,%eax,8)
994 +       ret
995 +GLOBL( _sse_MultiTexCoord2f_end )
996 +
997 +/*
998 +       MultiTexCoord2f
999 +*/
1000 +GLOBL( _sse_MultiTexCoord2f_2 )
1001 +       movl    4(%esp), %eax
1002 +       movlps  8(%esp), %xmm0
1003 +       and     $1,%eax
1004 +       movl    0(,%eax,4), %eax
1005 +       movlps  %xmm0, (%eax)
1006 +       ret
1007 +GLOBL( _sse_MultiTexCoord2f_2_end )
1008 +#endif
This page took 0.136309 seconds and 3 git commands to generate.