repo.or.cz
/
dragonfly.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
drm/linux: Implement some spin_lock_irq* functions
[dragonfly.git]
/
test
/
cpuperf
/
cpu_cmpexg.S
blob
eb7b7fc56f711acf765a99ce5de3a393fbeac18d
1
/* $DragonFly: src/test/cpuperf/cpu_cmpexg.S,v 1.1 2004/02/09 18:08:54 dillon Exp $ */
2
3
.globl test_dummy
4
.globl test_load
5
.globl test_str
6
7
.p2align 5
8
test_dummy:
9
movl 4(%esp),%ecx
10
movl $0,%edx
11
movl $1,%eax
12
movl %ebx,%edx
13
movl $0,(%ecx)
14
addl $3,%eax
15
ret
16
17
.p2align 5
18
test_load:
19
movl 4(%esp),%ecx
20
movl $0,%edx
21
movl $1,%eax
22
cmpxchgl %edx,(%ecx) /* instruction under test */
23
movl %ebx,%edx
24
movl $0,(%ecx)
25
addl $3,%eax
26
ret
27
28
.p2align 5
29
test_str:
30
.asciz "non-locked cmpxchgl (successful exchange) in pipeline"
31