C++ style commets // not valid in pure C

This commit is contained in:
Stanislav Shwartsman 2003-05-15 16:19:39 +00:00
parent 337bb3cfae
commit d596a6eb97
6 changed files with 19 additions and 21 deletions

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| fpu_aux.c |
| $Id: fpu_aux.c,v 1.2 2001-10-06 03:53:46 bdenney Exp $
| $Id: fpu_aux.c,v 1.3 2003-05-15 16:19:38 sshwarts Exp $
| |
| Code to implement some of the FPU auxiliary instructions. |
| |
@ -67,7 +67,7 @@ void finit_()
static void fstsw_ax(void)
{
SET_AX(status_word()); // KPL
SET_AX(status_word());
no_ip_update = 1;
}

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| fpu_entry.c |
| $Id: fpu_entry.c,v 1.8 2003-04-22 20:21:33 sshwarts Exp $
| $Id: fpu_entry.c,v 1.9 2003-05-15 16:19:38 sshwarts Exp $
| |
| The entry functions for wm-FPU-emu |
| |
@ -145,10 +145,10 @@ math_emulate(fpu_addr_modes addr_modes,
u_char loaded_tag, st0_tag;
// assuming byte is 0xd8..0xdf or 0xdb==FWAIT
/* assuming byte is 0xd8..0xdf or 0xdb==FWAIT */
// lock is not a valid prefix for FPU instructions, +++
// let the cpu handle it to generate a SIGILL.
/* lock is not a valid prefix for FPU instructions, +++
let the cpu handle it to generate a SIGILL. */
no_ip_update = 0;
@ -217,7 +217,7 @@ do_the_FPU_interrupt:
unmasked &= ~0xff;
break;
case 1:
loaded_tag = FPU_load_int32((s32 *)data_address, &loaded_data); // bbd: was (u32 *)
loaded_tag = FPU_load_int32((s32 *)data_address, &loaded_data);
break;
case 2:
unmasked = FPU_load_double((double *)data_address,
@ -311,8 +311,8 @@ do_the_FPU_interrupt:
FPU_compare_st_data(&loaded_data, loaded_tag);
break;
case 3: /* fcomp */
// bbd: used to typecase to int first, but this corrupted the
// pointer on 64 bit machines.
/* bbd: used to typecase to int first, but this corrupted the
pointer on 64 bit machines. */
if ( !FPU_compare_st_data(&loaded_data, loaded_tag)
&& !unmasked )
FPU_pop();

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| fpu_trig.c |
| $Id: fpu_trig.c,v 1.5 2002-07-03 20:13:31 vruppert Exp $
| $Id: fpu_trig.c,v 1.6 2003-05-15 16:19:39 sshwarts Exp $
| |
| Implementation of the FPU "transcendental" functions. |
| |
@ -76,7 +76,7 @@ static int trig_arg(FPU_REG *st0_ptr, int flags)
if ( ((flags & FCOS) && !(q & 1)) || (!(flags & FCOS) && (q & 1)) )
{
st0_tag = FPU_sub(REV|LOADED|TAG_Valid, &CONST_PI2, FULL_PRECISION); //bbd: arg2 used to typecast to (int)
st0_tag = FPU_sub(REV|LOADED|TAG_Valid, &CONST_PI2, FULL_PRECISION);
#ifdef BETTER_THAN_486
/* So far, the results are exact but based upon a 64 bit

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| poly_tan.c |
| $Id: poly_tan.c,v 1.4 2001-10-06 03:53:46 bdenney Exp $
| $Id: poly_tan.c,v 1.5 2003-05-15 16:19:39 sshwarts Exp $
| |
| Compute the tan of a FPU_REG, using a polynomial approximation. |
| |
@ -18,8 +18,6 @@
#include "control_w.h"
#include "poly.h"
//#define DEBUG_POLY_TAN // ***********
#define HiPOWERop 3 /* odd poly, positive terms */
static const u64 oddplterm[HiPOWERop] =
{

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| reg_constant.c |
| $Id: reg_constant.c,v 1.3 2001-10-06 03:53:46 bdenney Exp $
| $Id: reg_constant.c,v 1.4 2003-05-15 16:19:39 sshwarts Exp $
| |
| All of the constant FPU_REGs |
| |
@ -25,9 +25,9 @@ FPU_REG const CONST_HALF = MAKE_REG(POS, -1, 0x00000000, 0x80000000);
FPU_REG const CONST_L2T = MAKE_REG(POS, 1, 0xcd1b8afe, 0xd49a784b);
FPU_REG const CONST_L2E = MAKE_REG(POS, 0, 0x5c17f0bc, 0xb8aa3b29);
FPU_REG const CONST_PI = MAKE_REG(POS, 1, 0x2168c235, 0xc90fdaa2);
// bbd: make CONST_PI2 non-const so that you can write "&CONST_PI2" when
// calling a function. Otherwise you get const warnings. Surely there's
// a better way.
/* bbd: make CONST_PI2 non-const so that you can write "&CONST_PI2" when
calling a function. Otherwise you get const warnings. Surely there's
a better way. */
FPU_REG CONST_PI2 = MAKE_REG(POS, 0, 0x2168c235, 0xc90fdaa2);
FPU_REG const CONST_PI4 = MAKE_REG(POS, -1, 0x2168c235, 0xc90fdaa2);
FPU_REG const CONST_LG2 = MAKE_REG(POS, -2, 0xfbcff799, 0x9a209a84);

View File

@ -1,6 +1,6 @@
/*---------------------------------------------------------------------------+
| reg_ld_str.c |
| $Id: reg_ld_str.c,v 1.11 2003-05-15 16:11:29 sshwarts Exp $
| $Id: reg_ld_str.c,v 1.12 2003-05-15 16:19:39 sshwarts Exp $
| |
| All of the functions which transfer data between user memory and FPU_REGs.|
| |
@ -558,7 +558,7 @@ FPU_store_double(FPU_REG *st0_ptr, u_char st0_tag, double *dfloat)
l[0] = 0xFFFFFFFF; /* 8 byte real indefinite encoding */
l[1] = 0x7FEFFFFF;
}
else // rc == RC_RND
else /* rc == RC_RND */
{
l[0] = 0x00000000; /* Set to */
l[1] = 0x7ff00000; /* + INF */
@ -787,7 +787,7 @@ FPU_store_single(FPU_REG *st0_ptr, u_char st0_tag, float *single)
templ = 0x7F7FFFFF; /* 4 byte real indefinite encoding */
else if (rc == RC_UP && !signpositive(&tmp))
templ = 0x7F7FFFFF; /* 4 byte real indefinite encoding */
else // rc == RC_RND
else /* rc == RC_RND */
templ = 0x7f800000; /* Set to +INF */
}
else