| Index: src/mips/constants-mips.h
|
| diff --git a/src/mips/constants-mips.h b/src/mips/constants-mips.h
|
| index 2943a492e7f31a39b376019ceb750262e542a442..81f755b32006f47324513bbbfcd782e1b5dfe962 100644
|
| --- a/src/mips/constants-mips.h
|
| +++ b/src/mips/constants-mips.h
|
| @@ -555,9 +555,9 @@ enum SecondaryField {
|
|
|
|
|
| // ----- Emulated conditions.
|
| -// On MIPS we use this enum to abstract from conditionnal branch instructions.
|
| +// On MIPS we use this enum to abstract from conditional branch instructions.
|
| // The 'U' prefix is used to specify unsigned comparisons.
|
| -// Oppposite conditions must be paired as odd/even numbers
|
| +// Opposite conditions must be paired as odd/even numbers
|
| // because 'NegateCondition' function flips LSB to negate condition.
|
| enum Condition {
|
| // Any value < 0 is considered no_condition.
|
| @@ -566,10 +566,10 @@ enum Condition {
|
| no_overflow = 1,
|
| Uless = 2,
|
| Ugreater_equal = 3,
|
| - equal = 4,
|
| - not_equal = 5,
|
| - Uless_equal = 6,
|
| - Ugreater = 7,
|
| + Uless_equal = 4,
|
| + Ugreater = 5,
|
| + equal = 6,
|
| + not_equal = 7, // Unordered or Not Equal.
|
| negative = 8,
|
| positive = 9,
|
| parity_even = 10,
|
| @@ -579,7 +579,7 @@ enum Condition {
|
| less_equal = 14,
|
| greater = 15,
|
| ueq = 16, // Unordered or Equal.
|
| - nue = 17, // Not (Unordered or Equal).
|
| + ogl = 17, // Ordered and Not Equal.
|
| cc_always = 18,
|
|
|
| // Aliases.
|
| @@ -603,6 +603,10 @@ enum Condition {
|
| hs = Ugreater_equal,
|
| lo = Uless,
|
| al = cc_always,
|
| + ult = Uless,
|
| + uge = Ugreater_equal,
|
| + ule = Uless_equal,
|
| + ugt = Ugreater,
|
| cc_default = kNoCondition
|
| };
|
|
|
| @@ -617,6 +621,39 @@ inline Condition NegateCondition(Condition cc) {
|
| }
|
|
|
|
|
| +inline Condition NegateFpuCondition(Condition cc) {
|
| + DCHECK(cc != cc_always);
|
| + switch (cc) {
|
| + case ult:
|
| + return ge;
|
| + case ugt:
|
| + return le;
|
| + case uge:
|
| + return lt;
|
| + case ule:
|
| + return gt;
|
| + case lt:
|
| + return uge;
|
| + case gt:
|
| + return ule;
|
| + case ge:
|
| + return ult;
|
| + case le:
|
| + return ugt;
|
| + case eq:
|
| + return ne;
|
| + case ne:
|
| + return eq;
|
| + case ueq:
|
| + return ogl;
|
| + case ogl:
|
| + return ueq;
|
| + default:
|
| + return cc;
|
| + }
|
| +}
|
| +
|
| +
|
| // Commute a condition such that {a cond b == b cond' a}.
|
| inline Condition CommuteCondition(Condition cc) {
|
| switch (cc) {
|
|
|