]> git.pld-linux.org Git - packages/libreoffice.git/blame - openoffice-asm.patch
- up
[packages/libreoffice.git] / openoffice-asm.patch
CommitLineData
bd1b588a
PG
1--- oo_1.0_src/sal/osl/unx/interlck.c.jj Wed May 2 17:03:13 2001
2+++ oo_1.0_src/sal/osl/unx/interlck.c Thu May 30 10:45:19 2002
3@@ -83,9 +83,11 @@ oslInterlockedCount SAL_CALL osl_increme
4 "lock\n\t"
5 "xadd %0, %2\n\t"
6 "incl %0"
7- : "=a" (nCount), "=m" (*pCount)
8+ : "=&r" (nCount), "=m" (*pCount)
9 : "m" (*pCount)
10 : "memory");
11+
12+ return nCount;
13 }
14
15 oslInterlockedCount SAL_CALL osl_decrementInterlockedCount(oslInterlockedCount* pCount)
16@@ -97,9 +99,11 @@ oslInterlockedCount SAL_CALL osl_decreme
17 "lock\n\t"
18 "xadd %0, %2\n\t"
19 "decl %0"
20- : "=a" (nCount), "=m" (*pCount)
21+ : "=&r" (nCount), "=m" (*pCount)
22 : "m" (*pCount)
23 : "memory");
24+
25+ return nCount;
26 }
27
28 #elif defined ( GCC ) && defined ( POWERPC )
29@@ -117,7 +121,7 @@ oslInterlockedCount SAL_CALL osl_increme
30 " addi %0,%0,1\n\t"
31 " stwcx. %0,0,%2\n\t"
32 " bne- 1b"
33- : "=r" (nCount), "=m" (*pCount)
34+ : "=&r" (nCount), "=m" (*pCount)
35 : "r" (pCount)
36 : "r4", "memory");
37
38@@ -134,7 +138,7 @@ oslInterlockedCount SAL_CALL osl_decreme
39 " subi %0,%0,1\n\t"
40 " stwcx. %0,0,%2\n\t"
41 " bne- 1b"
42- : "=r" (nCount), "=m" (*pCount)
43+ : "=&r" (nCount), "=m" (*pCount)
44 : "r" (pCount)
45 : "r4", "memory");
46
47--- oo_1.0_src/bridges/source/c_uno/intelx86.cxx.jj Wed Apr 18 13:05:48 2001
48+++ oo_1.0_src/bridges/source/c_uno/intelx86.cxx Thu May 30 11:37:26 2002
49@@ -95,24 +95,21 @@ Lcopy: sub eax, 4
50 add esp, eax
51 }
52 #elif GCC
53+ int ecx, edx;
54+
55 __asm__
56 (
57- "mov %2, %%eax\n\t"
58- "mov %%eax, %%ecx\n\t"
59- "shl $2, %%eax\n\t"
60- "add %1, %%eax\n"
61- "Lcopy:\n\t"
62- "sub $4, %%eax\n\t"
63- "pushl (%%eax)\n\t"
64- "dec %%ecx\n\t"
65- "jne Lcopy\n\t"
66- "mov %0, %%eax\n\t"
67- "call *%%eax\n\t"
68- "mov %%eax, %3\n"
69- "mov %2, %%eax\n\t"
70- "shl $2, %%eax\n\t"
71- "add %%eax, %%esp\n\t"
72- : : "m"(fptr), "m"(pParams), "m"(nParams), "m"(retVal)
73+ "1:\n\t"
74+ "subl $4, %0\n\t"
75+ "pushl (%0)\n\t"
76+ "decl %1\n\t"
77+ "jne 1b\n\t"
78+ "call *%2\n\t"
79+ "leal 0(%%esp,%3,4), %%esp\n\t"
80+ : "=a"(retVal), "=c"(ecx), "=d"(edx)
81+ : "S"(nParams),
82+ "0" (((int *) pParams) + nParams), "1" (nParams), "2"(fptr)
83+ : "memory", "cc"
84 );
85 #else
86 #error "### unsupported x86 compiler!"
This page took 0.07935 seconds and 4 git commands to generate.