Skip to content
Snippets Groups Projects
Commit be61e3ce authored by Henrik (Grubba) Grubbström's avatar Henrik (Grubba) Grubbström
Browse files

Added workaround for /bin/as's without clflush.

Rev: src/code/ia32.c:1.45
parent 09290355
Branches
Tags
No related merge requests found
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
|| This file is part of Pike. For copyright information see COPYRIGHT. || This file is part of Pike. For copyright information see COPYRIGHT.
|| Pike is distributed under GPL, LGPL and MPL. See the file COPYING || Pike is distributed under GPL, LGPL and MPL. See the file COPYING
|| for more information. || for more information.
|| $Id: ia32.c,v 1.44 2006/08/05 20:11:31 mast Exp $ || $Id: ia32.c,v 1.45 2006/08/09 09:58:29 grubba Exp $
*/ */
/* /*
...@@ -1040,7 +1040,14 @@ void ia32_flush_instruction_cache(void *start, size_t len) ...@@ -1040,7 +1040,14 @@ void ia32_flush_instruction_cache(void *start, size_t len)
clflush [eax]; clflush [eax];
} }
#else /* USE_GCC_IA32_ASM_STYLE */ #else /* USE_GCC_IA32_ASM_STYLE */
#ifdef HAVE_ASM_CLFLUSH
__asm__ __volatile__("clflush %0" :: "m" (*addr)); __asm__ __volatile__("clflush %0" :: "m" (*addr));
#else
/* clflush (%eax) */
__asm__ __volatile__(".byte 0x0f\n"
".byte 0xae\n"
".byte 0x38" :: "eax" (addr));
#endif
#endif #endif
addr += ia32_clflush_size; addr += ia32_clflush_size;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment