rts/itimer/pthread: Stop timer when ticker is stopped
authorBen Gamari <bgamari.foss@gmail.com>
Sun, 1 May 2016 15:41:05 +0000 (17:41 +0200)
committerBen Gamari <ben@smart-cactus.org>
Sun, 1 May 2016 21:29:49 +0000 (23:29 +0200)
commit999c464da36e925bd4ffea34c94d3a7b3ab0135c
tree976d71ceaceb4a72ee40840c1ea7b170e6579a4d
parent55f4009ed610ed236f306bff0c33b0efc5a99e48
rts/itimer/pthread: Stop timer when ticker is stopped

This reworks the pthread-based itimer implementation to disarm the timer
when events aren't needed. Thanks to hsyl20 for the nice design.

Test Plan: Validate

Reviewers: hsyl20, simonmar, austin

Reviewed By: simonmar

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D2131

GHC Trac Issues: #1623, #11965
rts/RtsStartup.c
rts/posix/itimer/Pthread.c