debug: remove #ifdef's and use dumb logger
[mate.git] / Mate / RegisterAllocation.hs
index 9fc43ae51d5a4deeb6de6e3ba994e70ae8cfa7dc..8c4e040371868adc20c6324408226e872b26a0fe 100644 (file)
@@ -23,9 +23,10 @@ edgeEq (from,to) (from',to') = from == from' && to == to'
 -- TODO: find combinator do match try semantics here
 -- Solution: use list because list is MonadPlus instance
 -- other solution add maybe monadplus implementation
-conflicts (IGraph xs) (label,anotherLabel) = let comparison  = edgeEq (label,anotherLabel)
-                                                 comparison' = edgeEq (anotherLabel,label) 
-                                             in isJust (find comparison xs) || isJust (find comparison' xs) 
+conflicts (IGraph xs) (label,anotherLabel) =
+  let comparison  = edgeEq (label,anotherLabel)
+      comparison' = edgeEq (anotherLabel,label)
+  in isJust (find comparison xs) || isJust (find comparison' xs)
 
 
 isParticipiant label (from,to) = from == label || to == label
@@ -35,7 +36,7 @@ count p = length . filter p
 degree g@(IGraph xs) label = count (isParticipiant label) xs
 
 
-doChaitin81 :: (Eq a) => IArchitecture -> (IGraph a) -> [Assignment a]
+doChaitin81 :: (Eq a) => IArchitecture -> IGraph a -> [Assignment a]
 doChaitin81 numberOfRegisters graph = []
 
 type IState a = ([a],IGraph a)