Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
postgres-lambda-diff
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakob Huber
postgres-lambda-diff
Commits
846319db
Commit
846319db
authored
Aug 26, 2005
by
Tom Lane
Browse files
Options
Downloads
Patches
Plain Diff
Another try at the inlined MIPS spinlock code. Can't test this myself,
but for sure it's not any more broken than the prior version.
parent
f9244df7
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/include/storage/s_lock.h
+12
-12
12 additions, 12 deletions
src/include/storage/s_lock.h
with
12 additions
and
12 deletions
src/include/storage/s_lock.h
+
12
−
12
View file @
846319db
...
@@ -66,7 +66,7 @@
...
@@ -66,7 +66,7 @@
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.13
6
2005/08/26
14:47:35
tgl Exp $
* $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.13
7
2005/08/26
22:04:42
tgl Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -464,25 +464,25 @@ typedef unsigned int slock_t;
...
@@ -464,25 +464,25 @@ typedef unsigned int slock_t;
static
__inline__
int
static
__inline__
int
tas
(
volatile
slock_t
*
lock
)
tas
(
volatile
slock_t
*
lock
)
{
{
register
volatile
slock_t
*
__l
=
lock
;
register
volatile
slock_t
*
_l
=
lock
;
register
int
__r
;
register
int
_res
;
register
int
_tmp
;
__asm__
__volatile__
(
__asm__
__volatile__
(
" .set push
\n
"
" .set push
\n
"
" .set mips2
\n
"
" .set mips2
\n
"
" .set noreorder
\n
"
" .set noreorder
\n
"
" .set nomacro
\n
"
" .set nomacro
\n
"
"1: ll %0, %1
\n
"
" ll %0, %2
\n
"
" bne %0, $0, 1f
\n
"
" or %1, %0, $1
\n
"
" xori %0, 1
\n
"
" sc %1, %2
\n
"
" sc %0, %1
\n
"
" xori %1, $1
\n
"
" beq %0, $0, 1b
\n
"
" or %0, %0, %1
\n
"
" sync
\n
"
"1: .set pop "
"1: .set pop "
:
"=&r"
(
_
_
r
),
"+R"
(
*
_
_
l
)
:
"=&r"
(
_r
es
),
"=&r"
(
_tmp
),
"+R"
(
*
_l
)
:
:
:
"memory"
,
"cc"
);
:
"memory"
);
return
_
_
r
;
return
_r
es
;
}
}
#endif
/* __mips__ && !__sgi */
#endif
/* __mips__ && !__sgi */
...
...
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment