Enum cranelift_codegen::ir::condcodes::FloatCC[][src]

pub enum FloatCC {
    Ordered,
    Unordered,
    Equal,
    NotEqual,
    OrderedNotEqual,
    UnorderedOrEqual,
    LessThan,
    LessThanOrEqual,
    GreaterThan,
    GreaterThanOrEqual,
    UnorderedOrLessThan,
    UnorderedOrLessThanOrEqual,
    UnorderedOrGreaterThan,
    UnorderedOrGreaterThanOrEqual,
}

Condition code for comparing floating point numbers.

This condition code is used by the fcmp instruction to compare floating point values. Two IEEE floating point values relate in exactly one of four ways:

  1. UN - unordered when either value is NaN.
  2. EQ - equal numerical value.
  3. LT - x is less than y.
  4. GT - x is greater than y.

Note that 0.0 and -0.0 relate as EQ because they both represent the number 0.

The condition codes described here are used to produce a single boolean value from the comparison. The 14 condition codes here cover every possible combination of the relation above except the impossible !UN & !EQ & !LT & !GT and the always true UN | EQ | LT | GT.

Variants

EQ | LT | GT

UN

EQ

The C '!=' operator is the inverse of '==': NotEqual. UN | LT | GT

LT | GT

UN | EQ

LT

LT | EQ

GT

GT | EQ

UN | LT

UN | LT | EQ

UN | GT

UN | GT | EQ

Trait Implementations

impl Clone for FloatCC
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Copy for FloatCC
[src]

impl PartialEq for FloatCC
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for FloatCC
[src]

impl Debug for FloatCC
[src]

Formats the value using the given formatter. Read more

impl Hash for FloatCC
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl CondCode for FloatCC
[src]

Get the inverse condition code of self. Read more

Get the reversed condition code for self. Read more

impl Display for FloatCC
[src]

Formats the value using the given formatter. Read more

impl FromStr for FloatCC
[src]

The associated error which can be returned from parsing.

Parses a string s to return a value of this type. Read more

Auto Trait Implementations

impl Send for FloatCC

impl Sync for FloatCC