projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[project @ 2001-08-21 12:56:05 by simonpj]
[ghc-hetmet.git]
/
ghc
/
compiler
/
nativeGen
/
StixMacro.lhs
diff --git
a/ghc/compiler/nativeGen/StixMacro.lhs
b/ghc/compiler/nativeGen/StixMacro.lhs
index
415d7c8
..
6f4a5d1
100644
(file)
--- a/
ghc/compiler/nativeGen/StixMacro.lhs
+++ b/
ghc/compiler/nativeGen/StixMacro.lhs
@@
-11,10
+11,10
@@
module StixMacro ( macroCode, checkCode ) where
import {-# SOURCE #-} StixPrim ( amodeToStix )
import MachRegs
import {-# SOURCE #-} StixPrim ( amodeToStix )
import MachRegs
-import AbsCSyn ( CStmtMacro(..), MagicId(..), CAddrMode, tagreg,
+import AbsCSyn ( CStmtMacro(..), CAddrMode, tagreg,
CCheckMacro(..) )
CCheckMacro(..) )
-import Constants ( uF_RET, uF_SU, uF_UPDATEE, uF_SIZE, sEQ_FRAME_SIZE )
-import CallConv ( cCallConv )
+import Constants ( uF_RET, uF_SU, uF_UPDATEE, uF_SIZE )
+import ForeignCall ( CCallConv(..) )
import PrimOp ( PrimOp(..) )
import PrimRep ( PrimRep(..) )
import Stix
import PrimOp ( PrimOp(..) )
import PrimRep ( PrimRep(..) )
import Stix
@@
-72,13
+72,13
@@
adding an indirection.
macroCode UPD_CAF args
= let
[cafptr,bhptr] = map amodeToStix args
macroCode UPD_CAF args
= let
[cafptr,bhptr] = map amodeToStix args
+ new_caf = StCall SLIT("newCAF") CCallConv VoidRep [cafptr]
w0 = StInd PtrRep cafptr
w1 = StInd PtrRep (StIndex PtrRep cafptr fixedHS)
w0 = StInd PtrRep cafptr
w1 = StInd PtrRep (StIndex PtrRep cafptr fixedHS)
- a1 = StAssign PtrRep w0 ind_static_info
- a2 = StAssign PtrRep w1 bhptr
- a3 = StCall SLIT("newCAF") cCallConv VoidRep [cafptr]
+ a1 = StAssign PtrRep w1 bhptr
+ a2 = StAssign PtrRep w0 ind_static_info
in
in
- returnUs (\xs -> a1 : a2 : a3 : xs)
+ returnUs (\xs -> new_caf : a1 : a2 : xs)
\end{code}
-----------------------------------------------------------------------------
\end{code}
-----------------------------------------------------------------------------
@@
-180,7
+180,7
@@
macroCode REGISTER_IMPORT [arg]
macroCode REGISTER_FOREIGN_EXPORT [arg]
= returnUs (
macroCode REGISTER_FOREIGN_EXPORT [arg]
= returnUs (
- \xs -> StCall SLIT("getStablePtr") cCallConv VoidRep [amodeToStix arg]
+ \xs -> StCall SLIT("getStablePtr") CCallConv VoidRep [amodeToStix arg]
: xs
)
: xs
)
@@
-212,8
+212,8
@@
stg_update_PAP = StCLbl mkStgUpdatePAPLabel
updatePAP, stackOverflow :: StixTree
updatePAP, stackOverflow :: StixTree
-updatePAP = StJump stg_update_PAP
-stackOverflow = StCall SLIT("StackOverflow") cCallConv VoidRep []
+updatePAP = StJump NoDestInfo stg_update_PAP
+stackOverflow = StCall SLIT("StackOverflow") CCallConv VoidRep []
\end{code}
-----------------------------------------------------------------------------
\end{code}
-----------------------------------------------------------------------------
@@
-338,7
+338,7
@@
checkCode macro args assts
mkStJump_to_GCentry :: String -> StixTree
mkStJump_to_GCentry gcname
-- | opt_Static
mkStJump_to_GCentry :: String -> StixTree
mkStJump_to_GCentry gcname
-- | opt_Static
- = StJump (StCLbl (mkRtsGCEntryLabel gcname))
+ = StJump NoDestInfo (StCLbl (mkRtsGCEntryLabel gcname))
-- | otherwise -- it's in a different DLL
-- = StJump (StInd PtrRep (StLitLbl True sdoc))
-- | otherwise -- it's in a different DLL
-- = StJump (StInd PtrRep (StLitLbl True sdoc))