Speed up compilation of profiling stubs
authorBen Gamari <bgamari.foss@gmail.com>
Wed, 16 Aug 2017 23:01:05 +0000 (19:01 -0400)
committerBen Gamari <ben@smart-cactus.org>
Wed, 16 Aug 2017 23:02:28 +0000 (19:02 -0400)
commita8da0de27e600211f04601ac737c329d6603c700
tree26d759439b11dab3925d9c4723a5c76054f1dacc
parent6e9c8eb9885f894eed7e01a074ee7d83b251b1b1
Speed up compilation of profiling stubs

Here we encode the cost centre list as static data. This means that the
initialization stubs are small functions which should be easy for GCC to
compile, even with optimization.

Fixes #7960.

Test Plan: Test profiling

Reviewers: austin, erikd, simonmar

Reviewed By: simonmar

Subscribers: rwbarton, thomie

GHC Trac Issues: #7960

Differential Revision: https://phabricator.haskell.org/D3853
compiler/profiling/ProfInit.hs
includes/Rts.h
includes/rts/Profiling.h [new file with mode: 0644]
rts/Profiling.c