summaryrefslogtreecommitdiff
path: root/includes/rts
diff options
context:
space:
mode:
authorBartosz Nitka <niteria@gmail.com>2018-05-17 08:06:33 -0700
committerBartosz Nitka <niteria@gmail.com>2018-05-17 08:06:34 -0700
commit5d3b15ecbf17b7747c2f7313a981c60a2d22904d (patch)
tree64709fa322560091b7339614e36833a20f364f34 /includes/rts
parentf27e4f624fe1270e8027ff0a14f03514f5be31b7 (diff)
downloadhaskell-5d3b15ecbf17b7747c2f7313a981c60a2d22904d.tar.gz
Fix unwinding of C -> Haskell FFI calls with -threaded (2nd try)
Summary: See the new note. This should fix cb5c2fe875965b7aedbc189012803fc62e48fb3f enough to unbreak Windows and OS X builds. Test Plan: manual testing with patched gdb Reviewers: bgamari, simonmar, erikd Reviewed By: bgamari Subscribers: rwbarton, thomie, carter Differential Revision: https://phabricator.haskell.org/D4694
Diffstat (limited to 'includes/rts')
-rw-r--r--includes/rts/Constants.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/includes/rts/Constants.h b/includes/rts/Constants.h
index 5774bd7a0e..2f0ee5b10d 100644
--- a/includes/rts/Constants.h
+++ b/includes/rts/Constants.h
@@ -127,6 +127,19 @@
# endif
#endif
+/* -----------------------------------------------------------------------------
+ StgRun related labels shared between StgCRun.c and StgStartup.cmm.
+ -------------------------------------------------------------------------- */
+
+#if defined(LEADING_UNDERSCORE)
+#define STG_RUN "_StgRun"
+#define STG_RUN_JMP _StgRunJmp
+#define STG_RETURN "_StgReturn"
+#else
+#define STG_RUN "StgRun"
+#define STG_RUN_JMP StgRunJmp
+#define STG_RETURN "StgReturn"
+#endif
/* -----------------------------------------------------------------------------
How much Haskell stack space to reserve for the saving of registers