[commit: ghc] master: Eliminate zero_static_objects_list() (b949c96)
git at git.haskell.org
git at git.haskell.org
Wed Jul 22 16:33:56 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/b949c96b4960168a3b399fe14485b24a2167b982/ghc
>---------------------------------------------------------------
commit b949c96b4960168a3b399fe14485b24a2167b982
Author: Simon Marlow <marlowsd at gmail.com>
Date: Thu Jul 16 15:01:49 2015 +0100
Eliminate zero_static_objects_list()
Summary:
In a workload with a large amount of code, zero_static_objects_list()
takes a significant amount of time, and furthermore it is in the
single-threaded part of the GC.
This patch uses a slightly fiddly scheme for marking objects on the
static object lists, using a flag in the low 2 bits that flips between
two states to indicate whether an object has been visited during this
GC or not. We also have to take into account objects that have not
been visited yet, which might appear at any time due to runtime linking.
Test Plan: validate
Reviewers: austin, bgamari, ezyang, rwbarton
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D1076
>---------------------------------------------------------------
b949c96b4960168a3b399fe14485b24a2167b982
compiler/codeGen/StgCmmHeap.hs | 5 ++-
rts/CheckUnload.c | 6 ++-
rts/RetainerProfile.c | 2 +-
rts/sm/Compact.c | 4 +-
rts/sm/Evac.c | 95 ++++++++++++++++--------------------------
rts/sm/GC.c | 48 ++++++---------------
rts/sm/GCAux.c | 10 +++--
rts/sm/GCThread.h | 7 +++-
rts/sm/Sanity.c | 3 +-
rts/sm/Scav.c | 11 ++---
rts/sm/Storage.c | 10 ++---
rts/sm/Storage.h | 57 +++++++++++++++++++++++--
12 files changed, 137 insertions(+), 121 deletions(-)
Diff suppressed because of size. To see it, use:
git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc b949c96b4960168a3b399fe14485b24a2167b982
More information about the ghc-commits
mailing list