mirror of
https://github.com/reactos/reactos.git
synced 2026-09-12 20:59:19 +08:00
Implement asm stubs for alldiv, atan, ceil, cos, fabs, floor, log, pow, sin, sqrt, tan, _chkstk, _alloca_probe to libcntpr. Now we can build ntdll.
svn path=/branches/ros-amd64-bringup/; revision=38127
This commit is contained in:
@@ -1,22 +1,31 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
* PURPOSE: Stack checker
|
||||
* FILE: lib/ntdll/rtl/i386/chkstk.s
|
||||
* PROGRAMER:
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of _chkstk and _alloca_probe
|
||||
* FILE: lib/sdk/crt/math/amd64/chkstk_asm.s
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
.globl _chkstk
|
||||
.globl _alloca_probe
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
/*
|
||||
_chkstk() is called by all stack allocations of more than 4 KB. It grows the
|
||||
stack in areas of 4 KB each, trying to access each area. This ensures that the
|
||||
guard page for the stack is hit, and the stack growing triggered
|
||||
*/
|
||||
_chkstk:
|
||||
_alloca_probe:
|
||||
/* return */
|
||||
ret
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
.global _MsgUnimplemented
|
||||
_MsgUnimplemented:
|
||||
.asciz "WARNING: %s at %s:%d is UNIMPLEMENTED!\n"
|
||||
|
||||
|
||||
.proc _chkstk
|
||||
UNIMPLEMENTED chkstk
|
||||
ret
|
||||
.endproc
|
||||
|
||||
.proc _alloca_probe
|
||||
UNIMPLEMENTED alloca_probe
|
||||
ret
|
||||
.endproc
|
||||
|
||||
/* EOF */
|
||||
|
||||
@@ -20,6 +20,12 @@
|
||||
<file>seh.s</file>
|
||||
</directory>
|
||||
</if>
|
||||
<if property="ARCH" value="amd64">
|
||||
<directory name="amd64">
|
||||
<file>chkstk_asm.s</file>
|
||||
<file>seh.s</file>
|
||||
</directory>
|
||||
</if>
|
||||
<if property="ARCH" value="powerpc">
|
||||
<directory name="powerpc">
|
||||
<file>chkstk_asm.s</file>
|
||||
@@ -54,6 +60,21 @@
|
||||
<file>tan_asm.s</file>
|
||||
</directory>
|
||||
</if>
|
||||
<if property="ARCH" value="amd64">
|
||||
<directory name="amd64">
|
||||
<file>alldiv.S</file>
|
||||
<file>atan.S</file>
|
||||
<file>ceil.S</file>
|
||||
<file>cos.S</file>
|
||||
<file>fabs.S</file>
|
||||
<file>floor.S</file>
|
||||
<file>log.S</file>
|
||||
<file>pow.S</file>
|
||||
<file>sin.S</file>
|
||||
<file>sqrt.S</file>
|
||||
<file>tan.S</file>
|
||||
</directory>
|
||||
</if>
|
||||
<file>abs.c</file>
|
||||
<file>div.c</file>
|
||||
<file>labs.c</file>
|
||||
|
||||
28
reactos/lib/sdk/crt/math/amd64/alldiv.S
Normal file
28
reactos/lib/sdk/crt/math/amd64/alldiv.S
Normal file
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of alldiv
|
||||
* FILE: lib/sdk/crt/math/amd64/alldiv.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
/* DATA *********************************************************************/
|
||||
|
||||
.globl __fltused
|
||||
__fltused:
|
||||
.long 0x9875
|
||||
|
||||
/* FUNCTIONS ****************************************************************/
|
||||
|
||||
.proc alldiv
|
||||
UNIMPLEMENTED alldiv
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/atan.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/atan.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of atan
|
||||
* FILE: lib/sdk/crt/math/amd64/atan.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc atan
|
||||
UNIMPLEMENTED atan
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/ceil.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/ceil.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of ceil
|
||||
* FILE: lib/sdk/crt/math/amd64/ceil.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc ceil
|
||||
UNIMPLEMENTED ceil
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/cos.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/cos.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of cos
|
||||
* FILE: lib/sdk/crt/math/amd64/cos.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc cos
|
||||
UNIMPLEMENTED cos
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/fabs.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/fabs.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of fabs
|
||||
* FILE: lib/sdk/crt/math/amd64/fabs.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc fabs
|
||||
UNIMPLEMENTED fabs
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/floor.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/floor.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of floor
|
||||
* FILE: lib/sdk/crt/math/amd64/floor.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc floor
|
||||
UNIMPLEMENTED floor
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/log.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/log.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of log
|
||||
* FILE: lib/sdk/crt/math/amd64/log.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc log
|
||||
UNIMPLEMENTED log
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/pow.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/pow.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of pow
|
||||
* FILE: lib/sdk/crt/math/amd64/pow.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc pow
|
||||
UNIMPLEMENTED pow
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/sin.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/sin.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of sin
|
||||
* FILE: lib/sdk/crt/math/amd64/sin.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc sin
|
||||
UNIMPLEMENTED sin
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/sqrt.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/sqrt.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of sqrt
|
||||
* FILE: lib/sdk/crt/math/amd64/sqrt.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc sqrt
|
||||
UNIMPLEMENTED sqrt
|
||||
ret
|
||||
|
||||
.endproc
|
||||
21
reactos/lib/sdk/crt/math/amd64/tan.S
Normal file
21
reactos/lib/sdk/crt/math/amd64/tan.S
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* PURPOSE: Implementation of tan
|
||||
* FILE: lib/sdk/crt/math/amd64/tan.S
|
||||
* PROGRAMMER: Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include <ndk/amd64/asm.h>
|
||||
#include <ndk/amd64/asmmacro.S>
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
|
||||
.proc tan
|
||||
UNIMPLEMENTED tan
|
||||
ret
|
||||
|
||||
.endproc
|
||||
Reference in New Issue
Block a user