Commit 652a316b authored by nr@eecs.harvard.edu's avatar nr@eecs.harvard.edu

replace hints with kinds in parser as well

parent b71b86cf
......@@ -472,10 +472,10 @@ cmm_kind_exprs :: { [ExtFCode CmmActual] }
| cmm_kind_expr ',' cmm_kind_exprs { $1 : $3 }
cmm_kind_expr :: { ExtFCode CmmActual }
: expr { do e <- $1; return (CmmHinted e (inferCmmKind e)) }
: expr { do e <- $1; return (CmmKinded e (inferCmmKind e)) }
| expr STRING {% do h <- parseCmmKind $2;
return $ do
e <- $1; return (CmmHinted e h) }
e <- $1; return (CmmKinded e h) }
exprs0 :: { [ExtFCode CmmExpr] }
: {- empty -} { [] }
......@@ -499,10 +499,10 @@ cmm_formals :: { [ExtFCode CmmFormal] }
| cmm_formal ',' cmm_formals { $1 : $3 }
cmm_formal :: { ExtFCode CmmFormal }
: local_lreg { do e <- $1; return (CmmHinted e (inferCmmKind (CmmReg (CmmLocal e)))) }
: local_lreg { do e <- $1; return (CmmKinded e (inferCmmKind (CmmReg (CmmLocal e)))) }
| STRING local_lreg {% do h <- parseCmmKind $1;
return $ do
e <- $2; return (CmmHinted e h) }
e <- $2; return (CmmKinded e h) }
local_lreg :: { ExtFCode LocalReg }
: NAME { do e <- lookupName $1;
......@@ -924,13 +924,13 @@ foreignCall conv_string results_code expr_code args_code vols safety ret
(CmmCallee expr' convention) args vols NoC_SRT ret) where
unused = panic "not used by emitForeignCall'"
adjCallTarget :: CCallConv -> CmmExpr -> [CmmHinted CmmExpr] -> CmmExpr
adjCallTarget :: CCallConv -> CmmExpr -> [CmmKinded CmmExpr] -> CmmExpr
#ifdef mingw32_TARGET_OS
-- On Windows, we have to add the '@N' suffix to the label when making
-- a call with the stdcall calling convention.
adjCallTarget StdCallConv (CmmLit (CmmLabel lbl)) args
= CmmLit (CmmLabel (addLabelSize lbl (sum (map size args))))
where size (CmmHinted e _) = max wORD_SIZE (machRepByteWidth (cmmExprRep e))
where size (CmmKinded e _) = max wORD_SIZE (machRepByteWidth (cmmExprRep e))
-- c.f. CgForeignCall.emitForeignCall
#endif
adjCallTarget _ expr _
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment