From: simonmar Date: Mon, 9 Jan 2006 10:31:14 +0000 (+0000) Subject: [project @ 2006-01-09 10:31:14 by simonmar] X-Git-Tag: final_switch_to_darcs,_this_repo_is_now_live~59 X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=e1001abdb4f7ff4d703fc3dc0d587f861e11740c [project @ 2006-01-09 10:31:14 by simonmar] ord# and chr# should be no-ops, not conversions between wordRep and I32. --- diff --git a/ghc/compiler/codeGen/CgPrimOp.hs b/ghc/compiler/codeGen/CgPrimOp.hs index ccb252b..e59aafd 100644 --- a/ghc/compiler/codeGen/CgPrimOp.hs +++ b/ghc/compiler/codeGen/CgPrimOp.hs @@ -330,6 +330,8 @@ nopOp Int2WordOp = True nopOp Word2IntOp = True nopOp Int2AddrOp = True nopOp Addr2IntOp = True +nopOp ChrOp = True -- Int# and Char# are rep'd the same +nopOp OrdOp = True nopOp _ = False -- These PrimOps turn into double casts @@ -451,9 +453,6 @@ translateOp Float2IntOp = Just (MO_S_Conv F32 wordRep) translateOp Float2DoubleOp = Just (MO_S_Conv F32 F64) translateOp Double2FloatOp = Just (MO_S_Conv F64 F32) -translateOp OrdOp = Just (MO_U_Conv I32 wordRep) -translateOp ChrOp = Just (MO_U_Conv wordRep I32) - -- Word comparisons masquerading as more exotic things. translateOp SameMutVarOp = Just mo_wordEq