|
@@ -20,8 +20,8 @@
|
|
|
|
|
|
function InterLockedDecrement (var Target: longint) : longint; assembler;
|
|
function InterLockedDecrement (var Target: longint) : longint; assembler;
|
|
asm
|
|
asm
|
|
- movl %rdi,%rax
|
|
|
|
- movl $-1,%edx
|
|
|
|
|
|
+ movq %rdi,%rax
|
|
|
|
+ movl $-1,%edx
|
|
xchgq %rdx,%rax
|
|
xchgq %rdx,%rax
|
|
lock
|
|
lock
|
|
xaddl %eax, (%rdx)
|
|
xaddl %eax, (%rdx)
|
|
@@ -31,7 +31,7 @@ end;
|
|
|
|
|
|
function InterLockedIncrement (var Target: longint) : longint; assembler;
|
|
function InterLockedIncrement (var Target: longint) : longint; assembler;
|
|
asm
|
|
asm
|
|
- movl %rdi,%rax
|
|
|
|
|
|
+ movq %rdi,%rax
|
|
movl $1,%edx
|
|
movl $1,%edx
|
|
xchgq %rdx,%rax
|
|
xchgq %rdx,%rax
|
|
lock
|
|
lock
|
|
@@ -42,8 +42,8 @@ end;
|
|
|
|
|
|
function InterLockedExchange (var Target: longint;Source : longint) : longint; assembler;
|
|
function InterLockedExchange (var Target: longint;Source : longint) : longint; assembler;
|
|
asm
|
|
asm
|
|
- xchgl (%rdi),%rsi
|
|
|
|
- movl %rsi,%eax
|
|
|
|
|
|
+ xchgl (%rdi),%esi
|
|
|
|
+ movl %esi,%eax
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
@@ -51,13 +51,17 @@ function InterLockedExchangeAdd (var Target: longint;Source : longint) : longint
|
|
asm
|
|
asm
|
|
xchgq %rdi,%rsi
|
|
xchgq %rdi,%rsi
|
|
lock
|
|
lock
|
|
- xaddl %rdi, (%rsi)
|
|
|
|
|
|
+ xaddl %edi, (%rsi)
|
|
|
|
+ movl %edi,%eax
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
{
|
|
{
|
|
$Log$
|
|
$Log$
|
|
- Revision 1.4 2004-11-01 20:31:35 florian
|
|
|
|
|
|
+ Revision 1.5 2004-11-01 20:37:49 florian
|
|
|
|
+ * fixed some x86-64 multithreading stuff
|
|
|
|
+
|
|
|
|
+ Revision 1.4 2004/11/01 20:31:35 florian
|
|
* another fix for locked reference counting
|
|
* another fix for locked reference counting
|
|
|
|
|
|
Revision 1.2 2004/03/05 12:17:50 marco
|
|
Revision 1.2 2004/03/05 12:17:50 marco
|
|
@@ -66,4 +70,4 @@ end;
|
|
Revision 1.1 2004/02/20 22:15:16 florian
|
|
Revision 1.1 2004/02/20 22:15:16 florian
|
|
+ x86_64 dependend sysutils part added
|
|
+ x86_64 dependend sysutils part added
|
|
* some 64 bit adaptions
|
|
* some 64 bit adaptions
|
|
-}
|
|
|
|
|
|
+}
|