diff options
author | Bruce Momjian <bruce@momjian.us> | 2002-11-10 00:33:43 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2002-11-10 00:33:43 +0000 |
commit | ceb4f5ea9c2c6c2bd44d4799ff4a62c40a038894 (patch) | |
tree | a6f1fe29c6d2b2ede8cef05f21c1771a9681346f /src/backend | |
parent | 50e726a2c34523c120486a7c679c2b6d49233973 (diff) | |
download | postgresql-ceb4f5ea9c2c6c2bd44d4799ff4a62c40a038894.tar.gz postgresql-ceb4f5ea9c2c6c2bd44d4799ff4a62c40a038894.zip |
> > I'll re-check that with the ppc architecture guy here.
>
> ... he is now about to write an inlined version that can go into
> s_lock.h . I'll send the new patch later on...
OK, here it comes:
An inlined version of tas(), that works for both, powerpc and
powerpc64. The patch is against 7.3b5 and passes the test suite on
both architectures.
Reinhard Max
Diffstat (limited to 'src/backend')
-rw-r--r-- | src/backend/storage/lmgr/s_lock.c | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/src/backend/storage/lmgr/s_lock.c b/src/backend/storage/lmgr/s_lock.c index 0d30203a5f3..f767863b2a2 100644 --- a/src/backend/storage/lmgr/s_lock.c +++ b/src/backend/storage/lmgr/s_lock.c @@ -9,7 +9,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/s_lock.c,v 1.9 2002/09/21 00:14:05 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/s_lock.c,v 1.10 2002/11/10 00:33:43 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -144,31 +144,6 @@ success: \n\ } #endif /* __APPLE__ && __ppc__ */ -#if defined(__powerpc__) -/* Note: need a nice gcc constrained asm version so it can be inlined */ -static void -tas_dummy() -{ - __asm__ __volatile__( - "\ -.global tas \n\ -tas: \n\ - lwarx 5,0,3 \n\ - cmpwi 5,0 \n\ - bne fail \n\ - addi 5,5,1 \n\ - stwcx. 5,0,3 \n\ - beq success \n\ -fail: li 3,1 \n\ - blr \n\ -success: \n\ - isync \n\ - li 3,0 \n\ - blr \n\ -"); -} -#endif /* __powerpc__ */ - #if defined(__mips__) && !defined(__sgi) static void tas_dummy() |