xref: /reactos/sdk/lib/crt/math/i386/log10_asm.s (revision 1734f297)
1
2 /*
3 * COPYRIGHT:         See COPYING in the top level directory
4 * PROJECT:           ReactOS kernel
5 * PURPOSE:
6 * FILE:              lib/sdk/crt/math/i386/log10_asm.s
7 * PROGRAMER:         Magnus Olsen (magnus@greatlord.com)
8 *
9 */
10
11#include <asm.inc>
12
13PUBLIC _log10
14
15/* FUNCTIONS ***************************************************************/
16.code
17
18_log10:
19
20    push    ebp
21    mov     ebp,esp
22    fld     qword ptr [ebp+8]       // Load real from stack
23    fldlg2                          // Load log base 10 of 2
24    fxch    st(1)                   // Exchange st, st(1)
25    fyl2x                           // Compute the log base 10(x)
26    pop     ebp
27    ret
28
29END
30