diff options
author | diego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-10-16 20:17:56 +0000 |
---|---|---|
committer | diego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-10-16 20:17:56 +0000 |
commit | 26b29f4f2d4284fb81647a00b81530f280881303 (patch) | |
tree | 2ab0a30362d6cdf878efc039236befa860e28ae3 /loader | |
parent | 2195547220674940ef20e9ea38bb3610541d04b3 (diff) |
Replace all occurrences of '__volatile__' and '__volatile' by plain 'volatile'.
We were using an inconsistent mix of the three variants and 'volatile' should
be the most correct and portable variant.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27791 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'loader')
-rw-r--r-- | loader/drv.c | 8 | ||||
-rw-r--r-- | loader/ldt_keeper.c | 6 | ||||
-rw-r--r-- | loader/qtx/qtxload.c | 4 | ||||
-rw-r--r-- | loader/win32.c | 26 | ||||
-rw-r--r-- | loader/wine/windef.h | 2 |
5 files changed, 23 insertions, 23 deletions
diff --git a/loader/drv.c b/loader/drv.c index 5d4f0dcb93..b8fecf7467 100644 --- a/loader/drv.c +++ b/loader/drv.c @@ -52,7 +52,7 @@ extern char* def_path; #else // this asm code is no longer needed #define STORE_ALL \ - __asm__ __volatile__ ( \ + __asm__ volatile ( \ "push %%ebx\n\t" \ "push %%ecx\n\t" \ "push %%edx\n\t" \ @@ -60,7 +60,7 @@ extern char* def_path; "push %%edi\n\t"::) #define REST_ALL \ - __asm__ __volatile__ ( \ + __asm__ volatile ( \ "pop %%edi\n\t" \ "pop %%esi\n\t" \ "pop %%edx\n\t" \ @@ -98,7 +98,7 @@ LRESULT WINAPI SendDriverMessage(HDRVR hDriver, UINT message, #endif if (!module || !module->hDriverModule || !module->DriverProc) return -1; #ifndef __svr4__ - __asm__ __volatile__ ("fsave (%0)\n\t": :"r"(&qw)); + __asm__ volatile ("fsave (%0)\n\t": :"r"(&qw)); #endif #ifdef WIN32_LOADER @@ -110,7 +110,7 @@ LRESULT WINAPI SendDriverMessage(HDRVR hDriver, UINT message, REST_ALL; #ifndef __svr4__ - __asm__ __volatile__ ("frstor (%0)\n\t": :"r"(&qw)); + __asm__ volatile ("frstor (%0)\n\t": :"r"(&qw)); #endif #ifdef DETAILED_OUT diff --git a/loader/ldt_keeper.c b/loader/ldt_keeper.c index ef9386435e..e0d4447e60 100644 --- a/loader/ldt_keeper.c +++ b/loader/ldt_keeper.c @@ -138,7 +138,7 @@ void Setup_FS_Segment(void) { unsigned int ldt_desc = LDT_SEL(fs_ldt); - __asm__ __volatile__( + __asm__ volatile( "movl %0,%%eax; movw %%ax, %%fs" : : "r" (ldt_desc) :"eax" ); @@ -154,7 +154,7 @@ static int LDT_Modify( int func, struct modify_ldt_ldt_s *ptr, { int res; #ifdef __PIC__ - __asm__ __volatile__( "pushl %%ebx\n\t" + __asm__ volatile( "pushl %%ebx\n\t" "movl %2,%%ebx\n\t" "int $0x80\n\t" "popl %%ebx" @@ -165,7 +165,7 @@ static int LDT_Modify( int func, struct modify_ldt_ldt_s *ptr, "d"(16)//sizeof(*ptr) from kernel point of view :"esi" ); #else - __asm__ __volatile__("int $0x80" + __asm__ volatile("int $0x80" : "=a" (res) : "0" (__NR_modify_ldt), "b" (func), diff --git a/loader/qtx/qtxload.c b/loader/qtx/qtxload.c index 772ee5b0c5..38e0decda2 100644 --- a/loader/qtx/qtxload.c +++ b/loader/qtx/qtxload.c @@ -104,7 +104,7 @@ int main(int argc, char *argv[]){ printf("params: flags: %d, paramSize: %d, what: %d, params[0] = %x\n", params->flags, params->paramSize, params->what, params->params[0]); -// __asm__ __volatile__ ("movl %%esp, %0\n\t" : "=a" (esp) :: "memory" ); +// __asm__ volatile ("movl %%esp, %0\n\t" : "=a" (esp) :: "memory" ); // printf("ESP=%p\n",esp); *((void**)0x62b7d640) = &x_table[0]; //malloc(0x00001837 * 4); // ugly hack? @@ -113,7 +113,7 @@ int main(int argc, char *argv[]){ ret = dispatcher(params, &globals); -// __asm__ __volatile__ ("movl %%esp, %0\n\t" : "=a" (esp) :: "memory" ); +// __asm__ volatile ("movl %%esp, %0\n\t" : "=a" (esp) :: "memory" ); // printf("ESP=%p\n",esp); printf("!!! CDComponentDispatch() => %d glob=%p\n",ret,globals); diff --git a/loader/win32.c b/loader/win32.c index b3b157bb5d..576e3bd945 100644 --- a/loader/win32.c +++ b/loader/win32.c @@ -79,7 +79,7 @@ char* def_path = WIN32_PATH; static void do_cpuid(unsigned int ax, unsigned int *regs) { - __asm__ __volatile__ + __asm__ volatile ( "pushl %%ebx; pushl %%ecx; pushl %%edx;" ".byte 0x0f, 0xa2;" @@ -95,7 +95,7 @@ static void do_cpuid(unsigned int ax, unsigned int *regs) static unsigned int c_localcount_tsc() { int a; - __asm__ __volatile__ + __asm__ volatile ( "rdtsc\n\t" :"=a"(a) @@ -106,7 +106,7 @@ static unsigned int c_localcount_tsc() } static void c_longcount_tsc(long long* z) { - __asm__ __volatile__ + __asm__ volatile ( "pushl %%ebx\n\t" "movl %%eax, %%ebx\n\t" @@ -2867,7 +2867,7 @@ static int WINAPI expIsBadStringPtrA(const char* string, int nchars) static long WINAPI expInterlockedExchangeAdd( long* dest, long incr ) { long ret; - __asm__ __volatile__ + __asm__ volatile ( "lock; xaddl %0,(%1)" : "=r" (ret) @@ -4006,7 +4006,7 @@ static int exp_initterm(INITTERMFUNC *start, INITTERMFUNC *end) // ok this trick with push/pop is necessary as otherwice // edi/esi registers are being trashed void* p = *start; - __asm__ __volatile__ + __asm__ volatile ( "pushl %%ebx \n\t" "pushl %%ecx \n\t" @@ -4272,7 +4272,7 @@ static double expcos(double x) static void explog10(void) { - __asm__ __volatile__ + __asm__ volatile ( "fldl 8(%esp) \n\t" "fldln2 \n\t" @@ -4283,7 +4283,7 @@ static void explog10(void) static void expcos(void) { - __asm__ __volatile__ + __asm__ volatile ( "fldl 8(%esp) \n\t" "fcos \n\t" @@ -4300,7 +4300,7 @@ static void expcos(void) static void exp_ftol(void) { - __asm__ __volatile__ + __asm__ volatile ( "sub $12, %esp \n\t" "fstcw -2(%ebp) \n\t" @@ -4319,8 +4319,8 @@ static void exp_ftol(void) } #define FPU_DOUBLES(var1,var2) double var1,var2; \ - __asm__ __volatile__( "fstpl %0;fwait" : "=m" (var2) : ); \ - __asm__ __volatile__( "fstpl %0;fwait" : "=m" (var1) : ) + __asm__ volatile( "fstpl %0;fwait" : "=m" (var2) : ); \ + __asm__ volatile( "fstpl %0;fwait" : "=m" (var1) : ) static double exp_CIpow(void) { @@ -4361,7 +4361,7 @@ static int exp_setjmp3(void* jmpbuf, int x) { //dbgprintf("!!!!UNIMPLEMENTED: setjmp3(%p, %d) => 0\n", jmpbuf, x); //return 0; - __asm__ __volatile__ + __asm__ volatile ( //"mov 4(%%esp), %%edx \n\t" "mov (%%esp), %%eax \n\t" @@ -4383,7 +4383,7 @@ static int exp_setjmp3(void* jmpbuf, int x) : "eax" ); #if 1 - __asm__ __volatile__ + __asm__ volatile ( "mov %%fs:0, %%eax \n\t" // unsure "mov %%eax, 24(%%edx) \n\t" @@ -4762,7 +4762,7 @@ static double expfloor(double x) } #define FPU_DOUBLE(var) double var; \ - __asm__ __volatile__( "fstpl %0;fwait" : "=m" (var) : ) + __asm__ volatile( "fstpl %0;fwait" : "=m" (var) : ) static double exp_CIcos(void) { diff --git a/loader/wine/windef.h b/loader/wine/windef.h index 7b836e12a4..9d90a42257 100644 --- a/loader/wine/windef.h +++ b/loader/wine/windef.h @@ -94,7 +94,7 @@ extern "C" { # ifndef _EGCS_ #define __stdcall __attribute__((__stdcall__)) #define __cdecl __attribute__((__cdecl__)) -# define RESTORE_ES __asm__ __volatile__("pushl %ds\n\tpopl %es") +# define RESTORE_ES __asm__ volatile("pushl %ds\n\tpopl %es") # endif # else // # error You need gcc >= 2.7 to build Wine on a 386 |