From ccba9fd074941571a888dafb2f15c7ac3a3e1cc9 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Fri, 14 Nov 2003 20:21:22 +0000 Subject: [PATCH] Date: Mon, 10 Nov 2003 19:57:56 +0100 From: Stephane Marchesin Subject: [SDL] SDL and gcc >= 3.3.1 fix Lately, I upgraded my gcc compiler and could trigger the error described in this thread : http://www.libsdl.org/pipermail/sdl/2003-September/056163.html SDL_RLEaccel.c: In function `RLEClipBlit': SDL_RLEaccel.c:845: error: invalid `asm': invalid expression as operand SDL_RLEaccel.c:845: error: invalid `asm': invalid expression as operand SDL_RLEaccel.c:845: error: invalid `asm': invalid expression as operand The attached patch fixes this issue, and is smaller than the previous one, as I was able to trigger the issue, so I could narrow it. --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%40739 --- src/video/mmx.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/mmx.h b/src/video/mmx.h index 2f2093d18..e8fdcaf6a 100644 --- a/src/video/mmx.h +++ b/src/video/mmx.h @@ -353,7 +353,7 @@ mmx_ok(void) #define mmx_m2r(op, mem, reg) \ __asm__ __volatile__ (#op " %0, %%" #reg \ : /* nothing */ \ - : "X" (mem)) + : "m" (mem)) #define mmx_r2m(op, reg, mem) \ __asm__ __volatile__ (#op " %%" #reg ", %0" \