diff options
author | Ben Gamari <bgamari.foss@gmail.com> | 2017-02-01 23:39:52 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2017-02-02 00:18:58 -0500 |
commit | eedb3df0c1c28a7abc43705d614239c1c6199a1f (patch) | |
tree | 32045d426c9ecd4b07d74871d65d3e605842672d /libraries/ghci/GHCi/Run.hs | |
parent | b16239a95b730dd2d6fc0dbb18c8430669f2c187 (diff) | |
download | haskell-eedb3df0c1c28a7abc43705d614239c1c6199a1f.tar.gz |
Add support for StaticPointers in GHCi
Here we add support to GHCi for StaticPointers. This process begins by
adding remote GHCi messages for adding entries to the static pointer
table. We then collect binders needing SPT entries after linking and
send the interpreter a message adding entries with the appropriate
fingerprints.
Test Plan: `make test TEST=StaticPtr`
Reviewers: facundominguez, mboes, simonpj, simonmar, goldfire, austin,
hvr, erikd
Reviewed By: simonpj, simonmar
Subscribers: RyanGlScott, simonpj, thomie
Differential Revision: https://phabricator.haskell.org/D2504
GHC Trac Issues: #12356
Diffstat (limited to 'libraries/ghci/GHCi/Run.hs')
-rw-r--r-- | libraries/ghci/GHCi/Run.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libraries/ghci/GHCi/Run.hs b/libraries/ghci/GHCi/Run.hs index 858b247f65..eecafa1f75 100644 --- a/libraries/ghci/GHCi/Run.hs +++ b/libraries/ghci/GHCi/Run.hs @@ -20,6 +20,7 @@ import GHCi.ObjLink import GHCi.RemoteTypes import GHCi.TH import GHCi.BreakArray +import GHCi.StaticPtrTable import Control.Concurrent import Control.DeepSeq @@ -56,6 +57,7 @@ run m = case m of FindSystemLibrary str -> findSystemLibrary str CreateBCOs bcos -> createBCOs (concatMap (runGet get) bcos) FreeHValueRefs rs -> mapM_ freeRemoteRef rs + AddSptEntry fpr r -> localRef r >>= sptAddEntry fpr EvalStmt opts r -> evalStmt opts r ResumeStmt opts r -> resumeStmt opts r AbandonStmt r -> abandonStmt r |