/* gcc -W -Wall -fPIC -c test1.c -o test1.o */ #include static void f(uint8_t *q, uint8_t *p, int y, int x) { asm volatile( "movd %4, %%mm0 \n\t" "movd %5, %%mm1 \n\t" "movd %6, %%mm2 \n\t" "movd %7, %%mm3 \n\t" "# Lots of stuff going on here \n\t" "movd %%mm0, %0 \n\t" "movd %%mm1, %1 \n\t" "movd %%mm2, %2 \n\t" "movd %%mm3, %3 \n\t" : "=m" (*(uint32_t*)(q + 0*y)), "=m" (*(uint32_t*)(q + 1*y)), "=m" (*(uint32_t*)(q + 2*y)), "=m" (*(uint32_t*)(q + 3*y)) : "m" (*(uint32_t*)(p + 0*x)), "m" (*(uint32_t*)(p + 1*x)), "m" (*(uint32_t*)(p + 2*x)), "m" (*(uint32_t*)(p + 3*x)) ); }