aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2005-08-29 00:41:34 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2005-08-29 00:41:34 +0000
commit2d0339094592d202dc97e00f0524c03bdab9b81a (patch)
tree8991fa3a9d78a9a20447384aad781db9c62992f7 /src
parent46a0eee3006b11a15b73426c8146ed5ab32e1d62 (diff)
downloadpostgresql-2d0339094592d202dc97e00f0524c03bdab9b81a.tar.gz
postgresql-2d0339094592d202dc97e00f0524c03bdab9b81a.zip
Sigh, looks like you need '.set mips2' before you can access MIPS
SYNC instruction.
Diffstat (limited to 'src')
-rw-r--r--src/include/storage/s_lock.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/include/storage/s_lock.h b/src/include/storage/s_lock.h
index b4e2ab202e5..aaad9ad5571 100644
--- a/src/include/storage/s_lock.h
+++ b/src/include/storage/s_lock.h
@@ -66,7 +66,7 @@
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.139 2005/08/28 18:26:01 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.140 2005/08/29 00:41:34 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -490,8 +490,14 @@ tas(volatile slock_t *lock)
/* MIPS S_UNLOCK is almost standard but requires a "sync" instruction */
#define S_UNLOCK(lock) \
do \
-{\
- __asm__ __volatile__ (" sync \n"); \
+{ \
+ __asm__ __volatile__( \
+ " .set push \n" \
+ " .set mips2 \n" \
+ " .set noreorder \n" \
+ " .set nomacro \n" \
+ " sync \n" \
+ " .set pop "); \
*((volatile slock_t *) (lock)) = 0; \
} while (0)