Mercurial > mplayer.hg
changeset 15808:f03a8d54e5f9
fix asm constraints, tested on x86 and x86_64.
author | reimar |
---|---|
date | Thu, 23 Jun 2005 16:44:52 +0000 |
parents | 8df1067327f4 |
children | c4974449b18c |
files | mmx.h |
diffstat | 1 files changed, 20 insertions(+), 20 deletions(-) [+] |
line wrap: on
line diff
--- a/mmx.h Thu Jun 23 10:52:47 2005 +0000 +++ b/mmx.h Thu Jun 23 16:44:52 2005 +0000 @@ -246,15 +246,15 @@ printf(#op "_i2r(" #imm "=0x%08x%08x, ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ ("movq %%" #reg ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#reg "=0x%08x%08x) => ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ (#op " %0, %%" #reg \ : /* nothing */ \ - : "X" (imm)); \ + : "i" (imm)); \ __asm__ __volatile__ ("movq %%" #reg ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#reg "=0x%08x%08x\n", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -267,7 +267,7 @@ printf(#op "_m2r(" #mem "=0x%08x%08x, ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ ("movq %%" #reg ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#reg "=0x%08x%08x) => ", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -275,7 +275,7 @@ : /* nothing */ \ : "X" (mem)); \ __asm__ __volatile__ ("movq %%" #reg ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#reg "=0x%08x%08x\n", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -285,7 +285,7 @@ { \ mmx_t mmx_trace; \ __asm__ __volatile__ ("movq %%" #reg ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#op "_r2m(" #reg "=0x%08x%08x, ", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -293,7 +293,7 @@ printf(#mem "=0x%08x%08x) => ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ (#op " %%" #reg ", %0" \ - : "=X" (mem) \ + : "=m" (mem) \ : /* nothing */ ); \ mmx_trace = (mem); \ printf(#mem "=0x%08x%08x\n", \ @@ -304,18 +304,18 @@ { \ mmx_t mmx_trace; \ __asm__ __volatile__ ("movq %%" #regs ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#op "_r2r(" #regs "=0x%08x%08x, ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ ("movq %%" #regd ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#regd "=0x%08x%08x) => ", \ mmx_trace.d[1], mmx_trace.d[0]); \ __asm__ __volatile__ (#op " %" #regs ", %" #regd); \ __asm__ __volatile__ ("movq %%" #regd ", %0" \ - : "=X" (mmx_trace) \ + : "=m" (mmx_trace) \ : /* nothing */ ); \ printf(#regd "=0x%08x%08x\n", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -333,8 +333,8 @@ __asm__ __volatile__ ("movq %0, %%mm0\n\t" \ #op " %1, %%mm0\n\t" \ "movq %%mm0, %0" \ - : "=X" (memd) \ - : "X" (mems)); \ + : "=m" (memd) \ + : "m" (mems)); \ mmx_trace = (memd); \ printf(#memd "=0x%08x%08x\n", \ mmx_trace.d[1], mmx_trace.d[0]); \ @@ -348,7 +348,7 @@ #define mmx_i2r(op, imm, reg) \ __asm__ __volatile__ (#op " %0, %%" #reg \ : /* nothing */ \ - : "X" (imm) ) + : "i" (imm) ) #define mmx_m2r(op, mem, reg) \ __asm__ __volatile__ (#op " %0, %%" #reg \ @@ -357,7 +357,7 @@ #define mmx_r2m(op, reg, mem) \ __asm__ __volatile__ (#op " %%" #reg ", %0" \ - : "=X" (mem) \ + : "=m" (mem) \ : /* nothing */ ) #define mmx_r2r(op, regs, regd) \ @@ -367,8 +367,8 @@ __asm__ __volatile__ ("movq %0, %%mm0\n\t" \ #op " %1, %%mm0\n\t" \ "movq %%mm0, %0" \ - : "=X" (memd) \ - : "X" (mems)) + : "=m" (memd) \ + : "m" (mems)) #endif @@ -383,8 +383,8 @@ #define movq(vars, vard) \ __asm__ __volatile__ ("movq %1, %%mm0\n\t" \ "movq %%mm0, %0" \ - : "=X" (vard) \ - : "X" (vars)) + : "=m" (vard) \ + : "m" (vars)) /* 1x32 MOVe Doubleword @@ -398,8 +398,8 @@ #define movd(vars, vard) \ __asm__ __volatile__ ("movd %1, %%mm0\n\t" \ "movd %%mm0, %0" \ - : "=X" (vard) \ - : "X" (vars)) + : "=m" (vard) \ + : "m" (vars)) /* 2x32, 4x16, and 8x8 Parallel ADDs