mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 17:56:06 +00:00
[CRT]
- Make all x86assembly ML compatible - Remove memcpy, it was duplicated from memmove, copy the label instead - Guard some code against compilation on msvc, as these functions are intrinsics on MSVC and cannot be implemented - Fix some x64 assembly (don't modify stack below rsp) svn path=/branches/cmake-bringup/; revision=49421
This commit is contained in:
parent
0d7a1c46a0
commit
a3623f23de
49 changed files with 912 additions and 918 deletions
|
@ -2,41 +2,44 @@
|
|||
*/
|
||||
|
||||
#include "tchar.h"
|
||||
#include <reactos/asm.h>
|
||||
|
||||
.globl _tcsncat
|
||||
PUBLIC _tcsncat
|
||||
.code
|
||||
|
||||
_tcsncat:
|
||||
push %esi
|
||||
push %edi
|
||||
mov 0x0C(%esp), %edi
|
||||
mov 0x10(%esp), %esi
|
||||
cld
|
||||
push esi
|
||||
push edi
|
||||
mov edi, [esp + 12]
|
||||
mov esi, [esp + 16]
|
||||
cld
|
||||
|
||||
xor %eax, %eax
|
||||
mov $-1, %ecx
|
||||
repne _tscas
|
||||
_tdec(%edi)
|
||||
xor eax, eax
|
||||
mov ecx, -1
|
||||
repne _tscas
|
||||
_tdec(edi)
|
||||
|
||||
mov 0x14(%esp),%ecx
|
||||
mov ecx, [esp + 20]
|
||||
|
||||
.L1:
|
||||
dec %ecx
|
||||
js .L2
|
||||
_tlods
|
||||
_tstos
|
||||
test %_treg(a), %_treg(a)
|
||||
jne .L1
|
||||
jmp .L3
|
||||
dec ecx
|
||||
js .L2
|
||||
_tlods
|
||||
_tstos
|
||||
test _treg(a), _treg(a)
|
||||
jne .L1
|
||||
jmp .L3
|
||||
|
||||
.L2:
|
||||
xor %eax, %eax
|
||||
_tstos
|
||||
xor eax, eax
|
||||
_tstos
|
||||
|
||||
.L3:
|
||||
mov 0x0C(%esp), %eax
|
||||
pop %edi
|
||||
pop %esi
|
||||
mov eax, [esp + 12]
|
||||
pop edi
|
||||
pop esi
|
||||
|
||||
ret
|
||||
ret
|
||||
|
||||
END
|
||||
/* EOF */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue