(write_barrier): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@120735
138bc75d-0d04-0410-961f-
82ee72b054a4
+2007-01-12 Kaz Kojima <kkojima@gcc.gnu.org>
+
+ * sysdep/sh/locks.h (read_barrier): New.
+ (write_barrier): Likewise.
+
2007-01-12 Andrew Haley <aph@redhat.com>
* include/i386-signal.h: Rewrite to use rt_sigaction.
2007-01-12 Andrew Haley <aph@redhat.com>
* include/i386-signal.h: Rewrite to use rt_sigaction.
// locks.h - Thread synchronization primitives. SuperH implementation.
// locks.h - Thread synchronization primitives. SuperH implementation.
-/* Copyright (C) 2002 Free Software Foundation
+/* Copyright (C) 2002, 2007 Free Software Foundation
This file is part of libgcj.
This file is part of libgcj.
return compare_and_swap (addr, old, new_val);
}
return compare_and_swap (addr, old, new_val);
}
+inline static void
+read_barrier()
+{
+ __asm__ __volatile__(" " : : : "memory");
+}
+
+inline static void
+write_barrier()
+{
+ __asm__ __volatile__(" " : : : "memory");
+}
+
#endif /* ! __SYSDEP_LOCKS_H__ */
#endif /* ! __SYSDEP_LOCKS_H__ */