[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
FPU problem on i386ex board
- Date: 2 Jul 1999 14:47:43 -0000
- From: biguo at 263.net (biguo at 263.net)
- Subject: FPU problem on i386ex board
Hello,everyone!recently I am builting a cross GNAT/RTEMS on i386ex board.Because there aren't fpu 80387 on my board,I comment some fpu instruction in cpu.c.I doubt whether it will cause some unpredicatable error.The content look like as the follows:
void _CPU_Initialize(
rtems_cpu_table *cpu_table,
void (*thread_dispatch) /* ignored on this CPU */)
{ register unsigned16 fp_status asm ("ax");
register void *fp_context;
_CPU_Table = *cpu_table;
/*
* The following code saves a NULL i387 context which is given
* to each task at start and restart time. The following code
* is based upon that provided in the i386 Programmer's
* Manual and should work on any coprocessor greater than
* the i80287.
*
* NOTE: The NO RTEMS_WAIT form of the coprocessor instructions
* MUST be used in case there is not a coprocessor
* to wait for.
*/
/* fp_status = 0xa5a5;
asm volatile( "fninit" );
asm volatile( "fnstsw %0" : "=a" (fp_status) : "0" (fp_status) );
if ( fp_status == 0 ) {
fp_context = &_CPU_Null_fp_context;
asm volatile( "fsave (%0)" : "=r" (fp_context)
: "0" (fp_context)
);
}*/
}
If there are some problem,how can I solve FPU problem?Thanks in advance for any help.
_____________________________________________
????????--???????????????????? http://www.263.net
???????? ???????? ???????? ???????? ??????????
???????? ???????? ???????? ???????? ????????
???????? ???????? ???????? ???????? ????????