X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fcmm%2FCmmCommonBlockElimZ.hs;h=97ec31d4bb0a90cb1a87be894b56768a62a90098;hp=06e283164790123c829eae17d9f2528afb366eb2;hb=0d80489c9b9f2421f65d8dd86c1e50c6bb429715;hpb=25628e2771424cae1b3366322e8ce6f8a85440f9 diff --git a/compiler/cmm/CmmCommonBlockElimZ.hs b/compiler/cmm/CmmCommonBlockElimZ.hs index 06e2831..97ec31d 100644 --- a/compiler/cmm/CmmCommonBlockElimZ.hs +++ b/compiler/cmm/CmmCommonBlockElimZ.hs @@ -4,6 +4,7 @@ module CmmCommonBlockElimZ where +import BlockId import Cmm hiding (blockId) import CmmExpr import Prelude hiding (iterate, zip, unzip) @@ -89,13 +90,13 @@ hash_block (Block _ t) = hash_tail t 0 hash_mid (CopyOut _ as) = hash_as as hash_reg (CmmLocal l) = hash_local l hash_reg (CmmGlobal _) = 19 - hash_reg (CmmStack _) = 13 hash_local (LocalReg _ _ _) = 117 hash_e (CmmLit l) = hash_lit l hash_e (CmmLoad e _) = 67 + hash_e e hash_e (CmmReg r) = hash_reg r hash_e (CmmMachOp _ es) = hash_lst hash_e es -- pessimal - no operator check hash_e (CmmRegOff r i) = hash_reg r + i + hash_e (CmmStackSlot _ _) = 13 hash_lit (CmmInt i _) = fromInteger i hash_lit (CmmFloat r _) = truncate r hash_lit (CmmLabel _) = 119 -- ugh