Move barrier inline to compiler.h

上级 c366d4db
...@@ -115,12 +115,6 @@ rep_nop(void) ...@@ -115,12 +115,6 @@ rep_nop(void)
} }
static inline void static inline void
barrier(void)
{
__asm volatile("" ::: "memory");
}
static inline void
lidt(void *p) lidt(void *p)
{ {
__asm volatile("lidt (%0)" : : "r" (p) : "memory"); __asm volatile("lidt (%0)" : : "r" (p) : "memory");
......
#define __padout__ char __padout[0] __attribute__((aligned(CACHELINE))) #define __padout__ char __padout[0] __attribute__((aligned(CACHELINE)))
#define __mpalign__ __attribute__((aligned(CACHELINE))) #define __mpalign__ __attribute__((aligned(CACHELINE)))
#define __noret__ __attribute__((noreturn)) #define __noret__ __attribute__((noreturn))
static inline void
barrier(void)
{
__asm volatile("" ::: "memory");
}
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论