diff options
author | Ian Lynagh <igloo@earth.li> | 2007-07-18 11:17:51 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2007-07-18 11:17:51 +0000 |
commit | 48fb2b521898998a17873ad6cf30610aa5ab6db3 (patch) | |
tree | d78c6e905dbfb9b41eea29b6421841696daef579 /compiler/codeGen/CgInfoTbls.hs | |
parent | 95e67967d9abbef73e8d355d0e168759b4ee0590 (diff) | |
download | haskell-48fb2b521898998a17873ad6cf30610aa5ab6db3.tar.gz |
Fixes for the unreg build
* Fix code output order when printing C so things are defined before
they are used.
* Generate _ret rather than _entry functions for INFO_TABLE_RET.
* Use "ASSIGN_BaseReg" rather than "BaseReg =".
Diffstat (limited to 'compiler/codeGen/CgInfoTbls.hs')
-rw-r--r-- | compiler/codeGen/CgInfoTbls.hs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/compiler/codeGen/CgInfoTbls.hs b/compiler/codeGen/CgInfoTbls.hs index f6277f1a71..4e38485455 100644 --- a/compiler/codeGen/CgInfoTbls.hs +++ b/compiler/codeGen/CgInfoTbls.hs @@ -60,7 +60,7 @@ emitClosureCodeAndInfoTable :: ClosureInfo -> CmmFormals -> CgStmts -> Code emitClosureCodeAndInfoTable cl_info args body = do { blks <- cgStmtsToBlocks body ; info <- mkCmmInfo cl_info - ; emitInfoTableAndCode info_lbl info args blks } + ; emitInfoTableAndCode (infoLblToEntryLbl info_lbl) info args blks } where info_lbl = infoTableLabelFromCI cl_info @@ -151,7 +151,7 @@ emitReturnTarget name stmts (ProfilingInfo zeroCLit zeroCLit) rET_SMALL -- cmmToRawCmm may convert it to rET_BIG (ContInfo frame srt_info)) - ; emitInfoTableAndCode info_lbl info args blks + ; emitInfoTableAndCode (infoLblToEntryLbl info_lbl) info args blks ; return info_lbl } where args = {- trace "emitReturnTarget: missing args" -} [] @@ -401,16 +401,14 @@ funInfoTable info_ptr -- put the info table next to the code emitInfoTableAndCode - :: CLabel -- Label of info table + :: CLabel -- Label of entry or ret -> CmmInfo -- ...the info table -> CmmFormals -- ...args -> [CmmBasicBlock] -- ...and body -> Code -emitInfoTableAndCode info_lbl info args blocks - = emitProc info entry_lbl args blocks - where - entry_lbl = infoLblToEntryLbl info_lbl +emitInfoTableAndCode entry_ret_lbl info args blocks + = emitProc info entry_ret_lbl args blocks ------------------------------------------------------------------------- -- |