mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 01:24:38 +00:00
replaced by interlck.c
svn path=/trunk/; revision=298
This commit is contained in:
parent
3276df883d
commit
9d1624980f
1 changed files with 0 additions and 61 deletions
|
@ -1,61 +0,0 @@
|
|||
bits 32
|
||||
section .text
|
||||
|
||||
DECLARE_GLOBAL_SYMBOL InterlockedIncrement
|
||||
push ebp
|
||||
mov ebp,esp
|
||||
|
||||
push eax
|
||||
push ebx
|
||||
|
||||
mov eax,1
|
||||
mov ebx,[ebp+8]
|
||||
xadd [ebx],eax
|
||||
|
||||
pop ebx
|
||||
pop eax
|
||||
|
||||
mov esp,ebp
|
||||
pop ebp
|
||||
|
||||
ret
|
||||
|
||||
|
||||
DECLARE_GLOBAL_SYMBOL InterlockedDecrement
|
||||
mov eax,0xffffffff
|
||||
mov ebx,[esp+4]
|
||||
xadd [ebx],eax
|
||||
dec eax
|
||||
ret
|
||||
|
||||
DECLARE_GLOBAL_SYMBOL InterlockedExchange
|
||||
push ebp
|
||||
mov ebp,esp
|
||||
|
||||
push eax
|
||||
push ebx
|
||||
|
||||
mov eax,[ebp+12]
|
||||
mov ebx,[ebp+8]
|
||||
xchg [ebx],eax
|
||||
|
||||
pop ebx
|
||||
pop eax
|
||||
|
||||
mov esp,ebp
|
||||
pop ebp
|
||||
ret
|
||||
|
||||
DECLARE_GLOBAL_SYMBOL InterlockedExchangeAdd
|
||||
mov eax,[esp+8]
|
||||
mov ebx,[esp+4]
|
||||
xadd [ebx],eax
|
||||
ret
|
||||
|
||||
DECLARE_GLOBAL_SYMBOL InterlockedCompareExchange
|
||||
mov eax,[esp+12]
|
||||
mov edx,[esp+8]
|
||||
mov ebx,[esp+4]
|
||||
cmpxchg [ebx],edx
|
||||
mov eax,edx
|
||||
ret
|
Loading…
Reference in a new issue