b5b499b8c8
Move to folder with tcc. Part 1 git-svn-id: svn://kolibrios.org@8793 a494cfbc-eb01-0410-851d-a64ba20cac60
36 lines
501 B
ArmAsm
36 lines
501 B
ArmAsm
/* Copyright (C) 1994 DJ Delorie, see COPYING.DJ for details */
|
|
.text
|
|
|
|
.global modf;
|
|
|
|
modf:
|
|
pushl %ebp
|
|
movl %esp,%ebp
|
|
subl $16,%esp
|
|
pushl %ebx
|
|
fnstcw -4(%ebp)
|
|
fwait
|
|
movw -4(%ebp),%ax
|
|
orw $0x0c3f,%ax
|
|
movw %ax,-8(%ebp)
|
|
fldcw -8(%ebp)
|
|
fwait
|
|
fldl 8(%ebp)
|
|
frndint
|
|
fstpl -16(%ebp)
|
|
fwait
|
|
movl -16(%ebp),%edx
|
|
movl -12(%ebp),%ecx
|
|
movl 16(%ebp),%ebx
|
|
movl %edx,(%ebx)
|
|
movl %ecx,4(%ebx)
|
|
fldl 8(%ebp)
|
|
fsubl -16(%ebp)
|
|
leal -20(%ebp),%esp
|
|
fclex
|
|
fldcw -4(%ebp)
|
|
fwait
|
|
popl %ebx
|
|
leave
|
|
ret
|