summaryrefslogtreecommitdiff
path: root/rts/StgStartup.cmm
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2008-07-28 15:56:21 +0000
committerSimon Marlow <marlowsd@gmail.com>2008-07-28 15:56:21 +0000
commit02620e7c705ac946db43e61988ca3781af3f2447 (patch)
tree4a65b034fdda5ed683d951a786b56383b1300e77 /rts/StgStartup.cmm
parent4ddcff11bae7e4c66c3c895b277eb8b2230aea67 (diff)
downloadhaskell-02620e7c705ac946db43e61988ca3781af3f2447.tar.gz
Change the calling conventions for unboxed tuples slightly
When returning an unboxed tuple with a single non-void component, we now use the same calling convention as for returning a value of the same type as that component. This means that the return convention for IO now doesn't vary depending on the platform, which make some parts of the RTS simpler, and fixes a problem I was having with making the FFI work in unregisterised GHCi (the byte-code compiler makes some assumptions about calling conventions to keep things simple).
Diffstat (limited to 'rts/StgStartup.cmm')
-rw-r--r--rts/StgStartup.cmm16
1 files changed, 0 insertions, 16 deletions
diff --git a/rts/StgStartup.cmm b/rts/StgStartup.cmm
index b5a5cdcb2f..16e5c62801 100644
--- a/rts/StgStartup.cmm
+++ b/rts/StgStartup.cmm
@@ -147,18 +147,10 @@ stg_threadFinished
INFO_TABLE_RET( stg_forceIO, RET_SMALL)
-#ifdef REG_R1
{
Sp_adj(1);
ENTER();
}
-#else
-{
- R1 = Sp(0);
- Sp_adj(2);
- ENTER();
-}
-#endif
/* -----------------------------------------------------------------------------
Non-strict IO application.
@@ -171,18 +163,10 @@ INFO_TABLE_RET( stg_forceIO, RET_SMALL)
INFO_TABLE_RET( stg_noforceIO, RET_SMALL )
-#ifdef REG_R1
{
Sp_adj(1);
jump %ENTRY_CODE(Sp(0));
}
-#else
-{
- R1 = Sp(0);
- Sp_adj(2);
- jump %ENTRY_CODE(Sp(0));
-}
-#endif
/* -----------------------------------------------------------------------------
Special STG entry points for module registration.