Quellcodebibliothek Statistik Leitseite products/sources/formale Sprachen/C/Linux/arch/x86/math-emu/   (Open Source Betriebssystem Version 6.17.9©)  Datei vom 24.10.2025 mit Größe 1 kB image not shown  

Quelle  reg_convert.c   Sprache: C

 
// SPDX-License-Identifier: GPL-2.0
/*---------------------------------------------------------------------------+
 |  reg_convert.c                                                            |
 |                                                                           |
 |  Convert register representation.                                         |
 |                                                                           |
 | Copyright (C) 1992,1993,1994,1996,1997                                    |
 |                  W. Metzenthen, 22 Parker St, Ormond, Vic 3163, Australia |
 |                  E-mail   billm@suburbia.net                              |
 |                                                                           |
 |                                                                           |
 +---------------------------------------------------------------------------*/


#include "exception.h"
#include "fpu_emu.h"

int FPU_to_exp16(FPU_REG const *a, FPU_REG *x)
{
 int sign = getsign(a);

 *(long long *)&(x->sigl) = *(const long long *)&(a->sigl);

 /* Set up the exponent as a 16 bit quantity. */
 setexponent16(x, exponent(a));

 if (exponent16(x) == EXP_UNDER) {
  /* The number is a de-normal or pseudodenormal. */
  /* We only deal with the significand and exponent. */

  if (x->sigh & 0x80000000) {
   /* Is a pseudodenormal. */
   /* This is non-80486 behaviour because the number
   loses its 'denormal' identity. */

   addexponent(x, 1);
  } else {
   /* Is a denormal. */
   addexponent(x, 1);
   FPU_normalize_nuo(x);
  }
 }

 if (!(x->sigh & 0x80000000)) {
  EXCEPTION(EX_INTERNAL | 0x180);
 }

 return sign;
}

Messung V0.5
C=86 H=96 G=90

¤ Dauer der Verarbeitung: 0.0 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.