zoukankan      html  css  js  c++  java
  • public static float CompareExchange(ref float location1,float value,float comparand)

    https://msdn.microsoft.com/en-us/library/k9hz8w9t(v=vs.110).aspx

    Compares two single-precision floating point numbers for equality and, if they are equal, replaces the first value.

            /// <summary>
            /// 比较location1和comparand的值,如果它们的值相等,就用value的值替换location1的值
            /// </summary>
            /// <param name="location1">The destination, whose value is compared with comparand and possibly replaced.</param>
            /// <param name="value">The value that replaces the destination value if the comparison results in equality.</param>
            /// <param name="comparand">The value that is compared to the value at location1.</param>
            /// <returns>The original value in location1.</returns>
            public static float CompareExchange(ref float location1, float value, float comparand)

    Remarks

    If comparand and the value in location1 are equal, then value is stored in location1.

    Otherwise, no operation is performed.

    The compare and exchange operations are performed as an atomic operation.

    The return value of CompareExchange is the original value in location1, whether or not the exchange takes place.//不管exchange是否发生,返回值,都是location1原有的值

  • 相关阅读:
    scan design rules
    scan cell
    DFT basics
    测试性分析
    DFT设计绪论
    clock gate cell
    Linux命令
    Multi-voltage和power gating的实现
    Power Gating的设计(架构)
    Power Gating的设计(模块二)
  • 原文地址:https://www.cnblogs.com/chucklu/p/5442774.html
Copyright © 2011-2022 走看看