volatile signed int *sum, size_t dst_step,
size_t src_step, size_t sum_step)
{
+ unsigned int old_ebx;
+
/*
* ESI - src
* EDI - dst
__asm__ __volatile__ (
"\n"
- "\tpush %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %%ebx, %7\n" /* ebx is GOT pointer (-fPIC) */
/*
* initialization, load ESI, EDI, EBX registers
*/
"\tjnz 1b\n"
"7:"
- "\tpop %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %7, %%ebx\n" /* ebx is GOT pointer (-fPIC) */
: /* no output regs */
- : "m" (size), "m" (dst), "m" (src), "m" (sum), "m" (dst_step), "m" (src_step), "m" (sum_step)
+ : "m" (size), "m" (dst), "m" (src),
+ "m" (sum), "m" (dst_step), "m" (src_step),
+ "m" (sum_step), "m" (old_ebx)
: "esi", "edi", "edx", "ecx", "eax"
);
}
volatile signed int *sum, size_t dst_step,
size_t src_step, size_t sum_step)
{
+ unsigned int old_ebx;
+
/*
* ESI - src
* EDI - dst
__asm__ __volatile__ (
"\n"
- "\tpush %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %%ebx, %7\n" /* ebx is GOT pointer (-fPIC) */
/*
* initialization, load ESI, EDI, EBX registers
*/
"\tjnz 1b\n"
"\temms\n"
"5:"
- "\tpop %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %7, %%ebx\n" /* ebx is GOT pointer (-fPIC) */
: /* no output regs */
- : "m" (size), "m" (dst), "m" (src), "m" (sum), "m" (dst_step), "m" (src_step), "m" (sum_step)
+ : "m" (size), "m" (dst), "m" (src),
+ "m" (sum), "m" (dst_step), "m" (src_step),
+ "m" (sum_step), "m" (old_ebx)
: "esi", "edi", "edx", "ecx", "eax"
);
}
volatile signed int *sum, size_t dst_step,
size_t src_step, size_t sum_step)
{
+ unsigned int old_ebx;
+
/*
* ESI - src
* EDI - dst
__asm__ __volatile__ (
"\n"
- "\tpush %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %%ebx, %7\n" /* ebx is GOT pointer (-fPIC) */
/*
* initialization, load ESI, EDI, EBX registers
*/
"\tjmp 1b\n"
"6:"
- "\tpop %%ebx\n" /* ebx is GOT pointer (-fPIC) */
+ "\tmovl %7, %%ebx\n" /* ebx is GOT pointer (-fPIC) */
: /* no output regs */
- : "m" (size), "m" (dst), "m" (src), "m" (sum), "m" (dst_step), "m" (src_step), "m" (sum_step)
+ : "m" (size), "m" (dst), "m" (src),
+ "m" (sum), "m" (dst_step), "m" (src_step),
+ "m" (sum_step), "m" (old_ebx)
: "esi", "edi", "edx", "ecx", "eax"
);
}