module GHC.CmmToAsm.PPC.Cond (
Cond(..),
condNegate,
condUnsigned,
)
where
import GHC.Prelude
import GHC.Utils.Panic
data Cond
= ALWAYS
| EQQ
| GE
| GEU
| GTT
| GU
| LE
| LEU
| LTT
| LU
| NE
deriving Cond -> Cond -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Cond -> Cond -> Bool
$c/= :: Cond -> Cond -> Bool
== :: Cond -> Cond -> Bool
$c== :: Cond -> Cond -> Bool
Eq
condNegate :: Cond -> Cond
condNegate :: Cond -> Cond
condNegate Cond
ALWAYS = forall a. String -> a
panic String
"condNegate: ALWAYS"
condNegate Cond
EQQ = Cond
NE
condNegate Cond
GE = Cond
LTT
condNegate Cond
GEU = Cond
LU
condNegate Cond
GTT = Cond
LE
condNegate Cond
GU = Cond
LEU
condNegate Cond
LE = Cond
GTT
condNegate Cond
LEU = Cond
GU
condNegate Cond
LTT = Cond
GE
condNegate Cond
LU = Cond
GEU
condNegate Cond
NE = Cond
EQQ
condUnsigned :: Cond -> Bool
condUnsigned :: Cond -> Bool
condUnsigned Cond
GU = Bool
True
condUnsigned Cond
LU = Bool
True
condUnsigned Cond
GEU = Bool
True
condUnsigned Cond
LEU = Bool
True
condUnsigned Cond
_ = Bool
False