亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? softfloat.c

?? QEMU 0.91 source code, supports ARM processor including S3C24xx series
?? C
?? 第 1 頁 / 共 5 頁
字號:
/*============================================================================This C source file is part of the SoftFloat IEC/IEEE Floating-point ArithmeticPackage, Release 2b.Written by John R. Hauser.  This work was made possible in part by theInternational Computer Science Institute, located at Suite 600, 1947 CenterStreet, Berkeley, California 94704.  Funding was partially provided by theNational Science Foundation under grant MIP-9311980.  The original versionof this code was written as part of a project to build a fixed-point vectorprocessor in collaboration with the University of California at Berkeley,overseen by Profs. Nelson Morgan and John Wawrzynek.  More informationis available through the Web page `http://www.cs.berkeley.edu/~jhauser/arithmetic/SoftFloat.html'.THIS SOFTWARE IS DISTRIBUTED AS IS, FOR FREE.  Although reasonable effort hasbeen made to avoid it, THIS SOFTWARE MAY CONTAIN FAULTS THAT WILL AT TIMESRESULT IN INCORRECT BEHAVIOR.  USE OF THIS SOFTWARE IS RESTRICTED TO PERSONSAND ORGANIZATIONS WHO CAN AND WILL TAKE FULL RESPONSIBILITY FOR ALL LOSSES,COSTS, OR OTHER PROBLEMS THEY INCUR DUE TO THE SOFTWARE, AND WHO FURTHERMOREEFFECTIVELY INDEMNIFY JOHN HAUSER AND THE INTERNATIONAL COMPUTER SCIENCEINSTITUTE (possibly via similar legal warning) AGAINST ALL LOSSES, COSTS, OROTHER PROBLEMS INCURRED BY THEIR CUSTOMERS AND CLIENTS DUE TO THE SOFTWARE.Derivative works are acceptable, even for commercial purposes, so long as(1) the source code for the derivative work includes prominent notice thatthe work is derivative, and (2) the source code includes prominent notice withthese four paragraphs for those parts of this code that are retained.=============================================================================*/#include "softfloat.h"/*----------------------------------------------------------------------------| Primitive arithmetic functions, including multi-word arithmetic, and| division and square root approximations.  (Can be specialized to target if| desired.)*----------------------------------------------------------------------------*/#include "softfloat-macros.h"/*----------------------------------------------------------------------------| Functions and definitions to determine:  (1) whether tininess for underflow| is detected before or after rounding by default, (2) what (if anything)| happens when exceptions are raised, (3) how signaling NaNs are distinguished| from quiet NaNs, (4) the default generated quiet NaNs, and (5) how NaNs| are propagated from function inputs to output.  These details are target-| specific.*----------------------------------------------------------------------------*/#include "softfloat-specialize.h"void set_float_rounding_mode(int val STATUS_PARAM){    STATUS(float_rounding_mode) = val;}void set_float_exception_flags(int val STATUS_PARAM){    STATUS(float_exception_flags) = val;}#ifdef FLOATX80void set_floatx80_rounding_precision(int val STATUS_PARAM){    STATUS(floatx80_rounding_precision) = val;}#endif/*----------------------------------------------------------------------------| Takes a 64-bit fixed-point value `absZ' with binary point between bits 6| and 7, and returns the properly rounded 32-bit integer corresponding to the| input.  If `zSign' is 1, the input is negated before being converted to an| integer.  Bit 63 of `absZ' must be zero.  Ordinarily, the fixed-point input| is simply rounded to an integer, with the inexact exception raised if the| input cannot be represented exactly as an integer.  However, if the fixed-| point input is too large, the invalid exception is raised and the largest| positive or negative integer is returned.*----------------------------------------------------------------------------*/static int32 roundAndPackInt32( flag zSign, bits64 absZ STATUS_PARAM){    int8 roundingMode;    flag roundNearestEven;    int8 roundIncrement, roundBits;    int32 z;    roundingMode = STATUS(float_rounding_mode);    roundNearestEven = ( roundingMode == float_round_nearest_even );    roundIncrement = 0x40;    if ( ! roundNearestEven ) {        if ( roundingMode == float_round_to_zero ) {            roundIncrement = 0;        }        else {            roundIncrement = 0x7F;            if ( zSign ) {                if ( roundingMode == float_round_up ) roundIncrement = 0;            }            else {                if ( roundingMode == float_round_down ) roundIncrement = 0;            }        }    }    roundBits = absZ & 0x7F;    absZ = ( absZ + roundIncrement )>>7;    absZ &= ~ ( ( ( roundBits ^ 0x40 ) == 0 ) & roundNearestEven );    z = absZ;    if ( zSign ) z = - z;    if ( ( absZ>>32 ) || ( z && ( ( z < 0 ) ^ zSign ) ) ) {        float_raise( float_flag_invalid STATUS_VAR);        return zSign ? (sbits32) 0x80000000 : 0x7FFFFFFF;    }    if ( roundBits ) STATUS(float_exception_flags) |= float_flag_inexact;    return z;}/*----------------------------------------------------------------------------| Takes the 128-bit fixed-point value formed by concatenating `absZ0' and| `absZ1', with binary point between bits 63 and 64 (between the input words),| and returns the properly rounded 64-bit integer corresponding to the input.| If `zSign' is 1, the input is negated before being converted to an integer.| Ordinarily, the fixed-point input is simply rounded to an integer, with| the inexact exception raised if the input cannot be represented exactly as| an integer.  However, if the fixed-point input is too large, the invalid| exception is raised and the largest positive or negative integer is| returned.*----------------------------------------------------------------------------*/static int64 roundAndPackInt64( flag zSign, bits64 absZ0, bits64 absZ1 STATUS_PARAM){    int8 roundingMode;    flag roundNearestEven, increment;    int64 z;    roundingMode = STATUS(float_rounding_mode);    roundNearestEven = ( roundingMode == float_round_nearest_even );    increment = ( (sbits64) absZ1 < 0 );    if ( ! roundNearestEven ) {        if ( roundingMode == float_round_to_zero ) {            increment = 0;        }        else {            if ( zSign ) {                increment = ( roundingMode == float_round_down ) && absZ1;            }            else {                increment = ( roundingMode == float_round_up ) && absZ1;            }        }    }    if ( increment ) {        ++absZ0;        if ( absZ0 == 0 ) goto overflow;        absZ0 &= ~ ( ( (bits64) ( absZ1<<1 ) == 0 ) & roundNearestEven );    }    z = absZ0;    if ( zSign ) z = - z;    if ( z && ( ( z < 0 ) ^ zSign ) ) { overflow:        float_raise( float_flag_invalid STATUS_VAR);        return              zSign ? (sbits64) LIT64( 0x8000000000000000 )            : LIT64( 0x7FFFFFFFFFFFFFFF );    }    if ( absZ1 ) STATUS(float_exception_flags) |= float_flag_inexact;    return z;}/*----------------------------------------------------------------------------| Returns the fraction bits of the single-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE bits32 extractFloat32Frac( float32 a ){    return float32_val(a) & 0x007FFFFF;}/*----------------------------------------------------------------------------| Returns the exponent bits of the single-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE int16 extractFloat32Exp( float32 a ){    return ( float32_val(a)>>23 ) & 0xFF;}/*----------------------------------------------------------------------------| Returns the sign bit of the single-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE flag extractFloat32Sign( float32 a ){    return float32_val(a)>>31;}/*----------------------------------------------------------------------------| Normalizes the subnormal single-precision floating-point value represented| by the denormalized significand `aSig'.  The normalized exponent and| significand are stored at the locations pointed to by `zExpPtr' and| `zSigPtr', respectively.*----------------------------------------------------------------------------*/static void normalizeFloat32Subnormal( bits32 aSig, int16 *zExpPtr, bits32 *zSigPtr ){    int8 shiftCount;    shiftCount = countLeadingZeros32( aSig ) - 8;    *zSigPtr = aSig<<shiftCount;    *zExpPtr = 1 - shiftCount;}/*----------------------------------------------------------------------------| Packs the sign `zSign', exponent `zExp', and significand `zSig' into a| single-precision floating-point value, returning the result.  After being| shifted into the proper positions, the three fields are simply added| together to form the result.  This means that any integer portion of `zSig'| will be added into the exponent.  Since a properly normalized significand| will have an integer portion equal to 1, the `zExp' input should be 1 less| than the desired result exponent whenever `zSig' is a complete, normalized| significand.*----------------------------------------------------------------------------*/INLINE float32 packFloat32( flag zSign, int16 zExp, bits32 zSig ){    return make_float32(          ( ( (bits32) zSign )<<31 ) + ( ( (bits32) zExp )<<23 ) + zSig);}/*----------------------------------------------------------------------------| Takes an abstract floating-point value having sign `zSign', exponent `zExp',| and significand `zSig', and returns the proper single-precision floating-| point value corresponding to the abstract input.  Ordinarily, the abstract| value is simply rounded and packed into the single-precision format, with| the inexact exception raised if the abstract input cannot be represented| exactly.  However, if the abstract value is too large, the overflow and| inexact exceptions are raised and an infinity or maximal finite value is| returned.  If the abstract value is too small, the input value is rounded to| a subnormal number, and the underflow and inexact exceptions are raised if| the abstract input cannot be represented exactly as a subnormal single-| precision floating-point number.|     The input significand `zSig' has its binary point between bits 30| and 29, which is 7 bits to the left of the usual location.  This shifted| significand must be normalized or smaller.  If `zSig' is not normalized,| `zExp' must be 0; in that case, the result returned is a subnormal number,| and it must not require rounding.  In the usual case that `zSig' is| normalized, `zExp' must be 1 less than the ``true'' floating-point exponent.| The handling of underflow and overflow follows the IEC/IEEE Standard for| Binary Floating-Point Arithmetic.*----------------------------------------------------------------------------*/static float32 roundAndPackFloat32( flag zSign, int16 zExp, bits32 zSig STATUS_PARAM){    int8 roundingMode;    flag roundNearestEven;    int8 roundIncrement, roundBits;    flag isTiny;    roundingMode = STATUS(float_rounding_mode);    roundNearestEven = ( roundingMode == float_round_nearest_even );    roundIncrement = 0x40;    if ( ! roundNearestEven ) {        if ( roundingMode == float_round_to_zero ) {            roundIncrement = 0;        }        else {            roundIncrement = 0x7F;            if ( zSign ) {                if ( roundingMode == float_round_up ) roundIncrement = 0;            }            else {                if ( roundingMode == float_round_down ) roundIncrement = 0;            }        }    }    roundBits = zSig & 0x7F;    if ( 0xFD <= (bits16) zExp ) {        if (    ( 0xFD < zExp )             || (    ( zExp == 0xFD )                  && ( (sbits32) ( zSig + roundIncrement ) < 0 ) )           ) {            float_raise( float_flag_overflow | float_flag_inexact STATUS_VAR);            return packFloat32( zSign, 0xFF, - ( roundIncrement == 0 ));        }        if ( zExp < 0 ) {            isTiny =                   ( STATUS(float_detect_tininess) == float_tininess_before_rounding )                || ( zExp < -1 )                || ( zSig + roundIncrement < 0x80000000 );            shift32RightJamming( zSig, - zExp, &zSig );            zExp = 0;            roundBits = zSig & 0x7F;            if ( isTiny && roundBits ) float_raise( float_flag_underflow STATUS_VAR);        }    }    if ( roundBits ) STATUS(float_exception_flags) |= float_flag_inexact;    zSig = ( zSig + roundIncrement )>>7;    zSig &= ~ ( ( ( roundBits ^ 0x40 ) == 0 ) & roundNearestEven );    if ( zSig == 0 ) zExp = 0;    return packFloat32( zSign, zExp, zSig );}/*----------------------------------------------------------------------------| Takes an abstract floating-point value having sign `zSign', exponent `zExp',| and significand `zSig', and returns the proper single-precision floating-| point value corresponding to the abstract input.  This routine is just like| `roundAndPackFloat32' except that `zSig' does not have to be normalized.| Bit 31 of `zSig' must be zero, and `zExp' must be 1 less than the ``true''| floating-point exponent.*----------------------------------------------------------------------------*/static float32 normalizeRoundAndPackFloat32( flag zSign, int16 zExp, bits32 zSig STATUS_PARAM){    int8 shiftCount;    shiftCount = countLeadingZeros32( zSig ) - 1;    return roundAndPackFloat32( zSign, zExp - shiftCount, zSig<<shiftCount STATUS_VAR);}/*----------------------------------------------------------------------------| Returns the fraction bits of the double-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE bits64 extractFloat64Frac( float64 a ){    return float64_val(a) & LIT64( 0x000FFFFFFFFFFFFF );}/*----------------------------------------------------------------------------| Returns the exponent bits of the double-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE int16 extractFloat64Exp( float64 a ){    return ( float64_val(a)>>52 ) & 0x7FF;}/*----------------------------------------------------------------------------| Returns the sign bit of the double-precision floating-point value `a'.*----------------------------------------------------------------------------*/INLINE flag extractFloat64Sign( float64 a ){

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
中文一区二区完整视频在线观看| 成人一区二区视频| 欧美日韩精品二区第二页| 亚洲精品中文在线| 91久久国产综合久久| 亚洲国产精品一区二区久久恐怖片 | 国产精品一区二区久久不卡| 欧美成人精品福利| 精品在线亚洲视频| 久久久国产综合精品女国产盗摄| 国产成人无遮挡在线视频| 国产精品天美传媒| 欧美最猛黑人xxxxx猛交| 亚洲成a人片综合在线| 日韩欧美在线综合网| 国产一区二区三区免费| 国产精品三级av在线播放| 99视频有精品| 午夜欧美大尺度福利影院在线看| 精品精品欲导航| 国产v日产∨综合v精品视频| 亚洲免费成人av| 欧美一级免费观看| 风间由美一区二区三区在线观看 | 亚洲综合成人在线视频| 欧美精品日韩一区| 国产成人午夜99999| 亚洲欧美国产毛片在线| 3d动漫精品啪啪一区二区竹菊 | 国产精品中文字幕日韩精品| 中文字幕制服丝袜一区二区三区 | 韩国v欧美v亚洲v日本v| 国产精品久久久久久久裸模 | 日韩国产高清影视| 国产婷婷精品av在线| 色婷婷久久久综合中文字幕| 美国毛片一区二区| 国产精品二三区| 5858s免费视频成人| www.久久精品| 奇米影视7777精品一区二区| 国产精品女上位| 日韩欧美卡一卡二| 欧美性大战xxxxx久久久| 国产成人精品午夜视频免费| 天天色图综合网| 亚洲欧洲成人自拍| 久久一区二区视频| 91麻豆精品国产91久久久久| av不卡在线观看| 寂寞少妇一区二区三区| 亚洲一二三四区不卡| 中文av一区二区| 久久亚洲一级片| 51午夜精品国产| 91久久精品网| 99久久精品久久久久久清纯| 韩国理伦片一区二区三区在线播放| 亚洲综合一区二区| 国产精品免费网站在线观看| 精品久久国产字幕高潮| 欧美一区二区三区视频免费播放 | 国内一区二区视频| 亚洲一二三专区| 亚洲欧洲综合另类在线| 国产欧美一二三区| 精品国产污污免费网站入口 | 91精品国产综合久久福利软件 | av综合在线播放| 国产一区福利在线| 蜜桃精品视频在线| 日韩专区中文字幕一区二区| 亚洲一区国产视频| 一区二区三区资源| 一区二区三区成人| 亚洲老妇xxxxxx| 亚洲欧美一区二区三区国产精品| 国产日韩视频一区二区三区| 国产婷婷色一区二区三区四区| 久久久久久久电影| 国产午夜精品福利| 久久久激情视频| 国产精品久久夜| 成人免费小视频| 亚洲日本va午夜在线影院| 亚洲天堂av一区| 亚洲欧美激情视频在线观看一区二区三区| |精品福利一区二区三区| 亚洲视频在线一区二区| 亚洲人成在线观看一区二区| 亚洲精品亚洲人成人网在线播放| 亚洲欧美日韩在线播放| 亚洲电影中文字幕在线观看| 图片区日韩欧美亚洲| 蜜桃在线一区二区三区| 久久国产精品99久久人人澡| 久久 天天综合| 丁香激情综合国产| 91在线视频网址| 欧美少妇一区二区| 欧美一区二区视频在线观看 | 欧美一区二区免费视频| 日韩欧美综合在线| 国产欧美一区二区精品仙草咪| 最新高清无码专区| 亚洲成av人影院在线观看网| 日韩精品一卡二卡三卡四卡无卡| 九九在线精品视频| www.成人网.com| 69久久99精品久久久久婷婷| 久久五月婷婷丁香社区| 国产精品久久免费看| 亚洲成人激情av| 久久精品国产77777蜜臀| 福利视频网站一区二区三区| 欧美日韩免费不卡视频一区二区三区 | 亚洲成人免费在线| 国产综合久久久久影院| 色综合久久久网| 欧美电影免费观看高清完整版在 | 欧美三级日本三级少妇99| 欧美成人一区二区三区| 国产精品女同一区二区三区| 日韩制服丝袜先锋影音| 懂色av中文一区二区三区| 欧美性大战xxxxx久久久| 久久久久青草大香线综合精品| 亚洲欧美日韩一区二区 | 5858s免费视频成人| 国产午夜精品在线观看| 性欧美大战久久久久久久久| 成人性生交大片免费| 91精品国产乱| 亚洲品质自拍视频| 高清国产一区二区三区| 日韩限制级电影在线观看| 亚洲码国产岛国毛片在线| 国产精品一区专区| 欧美美女黄视频| 亚洲欧美日本韩国| 国产精品系列在线观看| 日韩一二三区不卡| 婷婷激情综合网| 91在线你懂得| 国产视频在线观看一区二区三区| 日韩av高清在线观看| 日本道在线观看一区二区| 国产色产综合色产在线视频| 免费视频一区二区| 欧美日韩美少妇| 亚洲福利一二三区| 色丁香久综合在线久综合在线观看| 国产午夜亚洲精品不卡| 国产呦萝稀缺另类资源| 欧美成人激情免费网| 天堂成人免费av电影一区| 在线看日韩精品电影| 成人欧美一区二区三区白人 | 六月丁香综合在线视频| 欧美三级日韩在线| 亚洲一级在线观看| 欧美色综合久久| 亚洲综合色丁香婷婷六月图片| 成人午夜av电影| 国产精品嫩草影院av蜜臀| 国产成人午夜精品5599| 亚洲国产精华液网站w| 国产精品主播直播| 中文字幕欧美三区| 成人国产电影网| 国产精品丝袜一区| av资源站一区| 一区二区三区在线视频播放| 91福利在线导航| 亚洲va中文字幕| 日韩一级成人av| 国产精品一区久久久久| 久久久国际精品| av资源网一区| 亚洲国产一区二区a毛片| 欧美精品色综合| 麻豆精品久久久| 久久久精品综合| 91免费视频网| 亚洲国产va精品久久久不卡综合| 欧美日韩免费视频| 日韩成人午夜精品| 久久蜜桃av一区精品变态类天堂 | 91片黄在线观看| 亚洲va天堂va国产va久| 日韩欧美一级在线播放| 激情五月婷婷综合| 国产精品免费视频观看| 在线免费观看成人短视频| 天天做天天摸天天爽国产一区 | www.欧美精品一二区| 亚洲一区二区三区四区的 | 精品国产91乱码一区二区三区 | 国产成人自拍网| 国产精品久久久久久久裸模|