VirtualBox

Ignore:
Timestamp:
Apr 11, 2022 12:51:14 AM (3 years ago)
Author:
vboxsync
Message:

libs/softfloat-3e: GCC build fixes for the ring-0 library version. bugref:9898

Location:
trunk/src/libs/softfloat-3e/source
Files:
27 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/softfloat-3e/source/extF80_roundToInt.c

    r94480 r94548  
    4141#include "specialize.h"
    4242#include "softfloat.h"
     43#include <iprt/cdefs.h> /* VBox: for RT_FALL_THROUGH */
    4344
    4445extFloat80_t
     
    9798         case softfloat_round_near_even:
    9899            if ( !(sigA & UINT64_C( 0x7FFFFFFFFFFFFFFF )) ) break;
     100            RT_FALL_THROUGH(); /* VBox */
    99101         case softfloat_round_near_maxMag:
    100102            if ( exp == 0x3FFE ) goto mag1;
  • trunk/src/libs/softfloat-3e/source/f128_roundToInt.c

    r94480 r94548  
    4141#include "specialize.h"
    4242#include "softfloat.h"
     43#include <iprt/cdefs.h> /* VBox: for RT_FALL_THROUGH */
    4344
    4445float128_t
     
    116117             case softfloat_round_near_even:
    117118                if ( !(fracF128UI64( uiA64 ) | uiA0) ) break;
     119                RT_FALL_THROUGH(); /* VBox */
    118120             case softfloat_round_near_maxMag:
    119121                if ( exp == 0x3FFE ) uiZ.v64 |= packToF128UI64( 0, 0x3FFF, 0 );
  • trunk/src/libs/softfloat-3e/source/f16_roundToInt.c

    r94480 r94548  
    4141#include "specialize.h"
    4242#include "softfloat.h"
     43#include <iprt/cdefs.h> /* VBox: for RT_FALL_THROUGH */
    4344
    4445float16_t f16_roundToInt( float16_t a, uint_fast8_t roundingMode, bool exact )
     
    6465         case softfloat_round_near_even:
    6566            if ( !fracF16UI( uiA ) ) break;
     67            RT_FALL_THROUGH(); /* VBox */
    6668         case softfloat_round_near_maxMag:
    6769            if ( exp == 0xE ) uiZ |= packToF16UI( 0, 0xF, 0 );
  • trunk/src/libs/softfloat-3e/source/f32_roundToInt.c

    r94480 r94548  
    4141#include "specialize.h"
    4242#include "softfloat.h"
     43#include <iprt/cdefs.h> /* VBox: for RT_FALL_THROUGH */
    4344
    4445float32_t f32_roundToInt( float32_t a, uint_fast8_t roundingMode, bool exact )
     
    6465         case softfloat_round_near_even:
    6566            if ( !fracF32UI( uiA ) ) break;
     67            RT_FALL_THROUGH(); /* VBox */
    6668         case softfloat_round_near_maxMag:
    6769            if ( exp == 0x7E ) uiZ |= packToF32UI( 0, 0x7F, 0 );
  • trunk/src/libs/softfloat-3e/source/f64_roundToInt.c

    r94480 r94548  
    4141#include "specialize.h"
    4242#include "softfloat.h"
     43#include <iprt/cdefs.h> /* VBox: for RT_FALL_THROUGH */
    4344
    4445float64_t f64_roundToInt( float64_t a, uint_fast8_t roundingMode, bool exact )
     
    6465         case softfloat_round_near_even:
    6566            if ( !fracF64UI( uiA ) ) break;
     67            RT_FALL_THROUGH(); /* VBox */
    6668         case softfloat_round_near_maxMag:
    6769            if ( exp == 0x3FE ) uiZ |= packToF64UI( 0, 0x3FF, 0 );
  • trunk/src/libs/softfloat-3e/source/include/opts-GCC.h

    r94480 r94548  
    6161#ifdef SOFTFLOAT_INTRINSIC_INT128
    6262
     63#include <iprt/cdefs.h> /* VBox: shut up pedantic warnings */
     64RT_GCC_EXTENSION typedef unsigned __int128  softfloat_int128_t;
     65
    6366INLINE struct uint128 softfloat_mul64ByShifted32To128( uint64_t a, uint32_t b )
    6467{
    65     union { unsigned __int128 ui; struct uint128 s; } uZ;
    66     uZ.ui = (unsigned __int128) a * ((uint_fast64_t) b<<32);
     68    union { softfloat_int128_t ui; struct uint128 s; } uZ;
     69    uZ.ui = (softfloat_int128_t) a * ((uint_fast64_t) b<<32);
    6770    return uZ.s;
    6871}
     
    7174INLINE struct uint128 softfloat_mul64To128( uint64_t a, uint64_t b )
    7275{
    73     union { unsigned __int128 ui; struct uint128 s; } uZ;
    74     uZ.ui = (unsigned __int128) a * b;
     76    union { softfloat_int128_t ui; struct uint128 s; } uZ;
     77    uZ.ui = (softfloat_int128_t) a * b;
    7578    return uZ.s;
    7679}
     
    8083struct uint128 softfloat_mul128By32( uint64_t a64, uint64_t a0, uint32_t b )
    8184{
    82     union { unsigned __int128 ui; struct uint128 s; } uZ;
    83     uZ.ui = ((unsigned __int128) a64<<64 | a0) * b;
     85    union { softfloat_int128_t ui; struct uint128 s; } uZ;
     86    uZ.ui = ((softfloat_int128_t) a64<<64 | a0) * b;
    8487    return uZ.s;
    8588}
     
    9194     uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0, uint64_t *zPtr )
    9295{
    93     unsigned __int128 z0, mid1, mid, z128;
    94     z0 = (unsigned __int128) a0 * b0;
    95     mid1 = (unsigned __int128) a64 * b0;
    96     mid = mid1 + (unsigned __int128) a0 * b64;
    97     z128 = (unsigned __int128) a64 * b64;
    98     z128 += (unsigned __int128) (mid < mid1)<<64 | mid>>64;
     96    softfloat_int128_t z0, mid1, mid, z128;
     97    z0 = (softfloat_int128_t) a0 * b0;
     98    mid1 = (softfloat_int128_t) a64 * b0;
     99    mid = mid1 + (softfloat_int128_t) a0 * b64;
     100    z128 = (softfloat_int128_t) a64 * b64;
     101    z128 += (softfloat_int128_t) (mid < mid1)<<64 | mid>>64;
    99102    mid <<= 64;
    100103    z0 += mid;
  • trunk/src/libs/softfloat-3e/source/s_add128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_add128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_add256M.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_add256M
     42# include "primitives.h" /* VBox: Missing prototype */
    4243
    4344void
  • trunk/src/libs/softfloat-3e/source/s_approxRecip32_1.c

    r94480 r94548  
    3939
    4040#ifndef softfloat_approxRecip32_1
     41uint32_t softfloat_approxRecip32_1( uint32_t a ); /* VBox: Missing prototype */
    4142
    4243extern const uint16_t softfloat_approxRecip_1k0s[16];
  • trunk/src/libs/softfloat-3e/source/s_approxRecipSqrt32_1.c

    r94480 r94548  
    3939
    4040#ifndef softfloat_approxRecipSqrt32_1
     41# undef INLINE_LEVEL     /* VBox: Missing prototype */
     42# include "primitives.h" /* VBox: Missing prototype */
    4143
    4244extern const uint16_t softfloat_approxRecipSqrt_1k0s[];
  • trunk/src/libs/softfloat-3e/source/s_eq128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_eq128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345bool softfloat_eq128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
  • trunk/src/libs/softfloat-3e/source/s_le128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_le128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345bool softfloat_le128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
  • trunk/src/libs/softfloat-3e/source/s_lt128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_lt128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345bool softfloat_lt128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shiftRightJam128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam128Extra.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shiftRightJam128Extra
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128_extra
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam256M.c

    r94492 r94548  
    4040
    4141#ifndef softfloat_shiftRightJam256M
     42# include "primitives.h" /* VBox: Missing prototype */
    4243
    4344static
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam32.c

    r94480 r94548  
    3939
    4040#ifndef softfloat_shiftRightJam32
     41# undef INLINE_LEVEL     /* VBox: Missing prototype */
     42# include "primitives.h" /* VBox: Missing prototype */
    4143
    4244uint32_t softfloat_shiftRightJam32( uint32_t a, uint_fast16_t dist )
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam64.c

    r94480 r94548  
    3939
    4040#ifndef softfloat_shiftRightJam64
     41# undef INLINE_LEVEL     /* VBox: Missing prototype */
     42# include "primitives.h" /* VBox: Missing prototype */
    4143
    4244uint64_t softfloat_shiftRightJam64( uint64_t a, uint_fast32_t dist )
  • trunk/src/libs/softfloat-3e/source/s_shiftRightJam64Extra.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shiftRightJam64Extra
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint64_extra
  • trunk/src/libs/softfloat-3e/source/s_shortShiftLeft128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shortShiftLeft128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_shortShiftRight128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shortShiftRight128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_shortShiftRightJam128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shortShiftRightJam128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_shortShiftRightJam128Extra.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shortShiftRightJam128Extra
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128_extra
  • trunk/src/libs/softfloat-3e/source/s_shortShiftRightJam64.c

    r94480 r94548  
    3939
    4040#ifndef softfloat_shortShiftRightJam64
     41# undef INLINE_LEVEL     /* VBox: Missing prototype */
     42# include "primitives.h" /* VBox: Missing prototype */
    4143
    4244uint64_t softfloat_shortShiftRightJam64( uint64_t a, uint_fast8_t dist )
  • trunk/src/libs/softfloat-3e/source/s_shortShiftRightJam64Extra.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_shortShiftRightJam64Extra
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint64_extra
  • trunk/src/libs/softfloat-3e/source/s_sub128.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_sub128
     42# undef INLINE_LEVEL     /* VBox: Missing prototype */
     43# include "primitives.h" /* VBox: Missing prototype */
    4244
    4345struct uint128
  • trunk/src/libs/softfloat-3e/source/s_sub256M.c

    r94480 r94548  
    4040
    4141#ifndef softfloat_sub256M
     42# include "primitives.h" /* VBox: Missing prototype */
    4243
    4344void
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette