Assmebler Error
uint64_t csae = 0; /* accummulators for difference */
58 uint64_t c1 = 0,*c;
59 uint8_t *ip, *rp; /* pointers to appropriate
rows */
asm("movq (%1), %%mm1 \n\t"
70 "psadbw (%2), %%mm1 \n\t"
71 "movq 8(%1), %%mm0 \n\t"
72 "psadbw 8(%2), %%mm0 \n\t"
73 "paddd %%mm0, %%mm1 \n\t" /* might
use paddd for 32-bit adding */
74 "movq 16(%1), %%mm0 \n\t"
75 "psadbw 16(%2), %%mm0 \n\t"
76 "paddd %%mm0, %%mm1 \n\t"
77 "movq 24(%1), %%mm0 \n\t"
78 "psadbw 24(%2), %%mm0 \n\t"
79 "paddd %%mm0, %%mm1 \n\t"
80 "movq %%mm1,%0 \n\t"
82 "emms \n\t"
83 : "=g" (c1)
84 : "r" (rp), "r" (ip)
85 );Well due to this module i am getting the following error
{standard input}: Assembler messages:
{standard input}:4126: Error: suffix or operands invalid for `movq'
{standard input}:4494: Error: suffix or operands invalid for `movq'
if somebody can help
thanks
ankit jain
________________________________________________________________________
Yahoo! Messenger - Communicate instantly..."Ping"
your friends today! Download Messenger Now
http://uk.messenger.yahoo.com/download/index.html
Quoted 30 lines · Ankit Jain
uint64_tcsae = 0; /* accummulators for difference */
58uint64_tc1 = 0,*c;
59uint8_t*ip, *rp; /* pointers to appropriate
rows */asm("movq (%1), %%mm1 \n\t" 70 "psadbw (%2), %%mm1 \n\t" 71 "movq 8(%1), %%mm0 \n\t" 72 "psadbw 8(%2), %%mm0 \n\t" 73 "paddd %%mm0, %%mm1 \n\t" /* might use paddd for 32-bit adding */ 74 "movq 16(%1), %%mm0 \n\t" 75 "psadbw 16(%2), %%mm0 \n\t" 76 "paddd %%mm0, %%mm1 \n\t" 77 "movq 24(%1), %%mm0 \n\t" 78 "psadbw 24(%2), %%mm0 \n\t" 79 "paddd %%mm0, %%mm1 \n\t" 80 "movq %%mm1,%0 \n\t" 82 "emms \n\t" 83 : "=g" (c1) 84 : "r" (rp), "r" (ip) 85 );Well due to this module i am getting the following error
{standard input}: Assembler messages:
{standard input}:4126: Error: suffix or operands invalid for `movq'
{standard input}:4494: Error: suffix or operands invalid for `movq'
Quoted 1 line
if somebody can help
must be a toolchain issue ... tried the following C file
---------------------
#include <stdint.h>
int main(void) {
uint64_t c1 = 0;
uint8_t *ip, *rp; /* pointers to appropriate rows */
asm("movq (%1), %%mm1 \n"
"psadbw (%2), %%mm1 \n"
"movq 8(%1), %%mm0 \n"
"psadbw 8(%2), %%mm0 \n"
"paddd %%mm0, %%mm1 \n"
"psadbw 16(%2), %%mm0 \n"
"paddd %%mm0, %%mm1 \n"
"movq 24(%1), %%mm0 \n"
"psadbw 24(%2), %%mm0 \n"
"paddd %%mm0, %%mm1 \n"
"movq %%mm1, %0 \n"
"emms \n"
: "=g" (c1)
: "r" (rp), "r" (ip)
);
return 0;
}------------
and it compiles correctly here (checked with objdump)
# gcc --version gcc (GCC) 3.3.4 (Mandrake Linux 8.2 3.3.4-1mdk) # as --version GNU assembler 2.15.90.0.3 20040415
HTH,
Herbert
Quoted 12 lines
thanks
ankit jain
________________________________________________________________________
Yahoo! Messenger - Communicate instantly..."Ping"
your friends today! Download Messenger Now
http://uk.messenger.yahoo.com/download/index.html
-
To unsubscribe from this list: send the line "unsubscribe linux-assembly" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html