sim: Add support for notifying Drainable objects of a fork
authorAndreas Sandberg <andreas@sandberg.pp.se>
Thu, 26 Nov 2015 10:03:43 +0000 (10:03 +0000)
committerAndreas Sandberg <andreas@sandberg.pp.se>
Thu, 26 Nov 2015 10:03:43 +0000 (10:03 +0000)
commit738d71f6a93e2da9ef5bb1490f2b94f9541735e3
treecb51f78224317fc4724af5dd6ec7890850b367b5
parent5383e1ada49b59daf4ff8703076923d4ccb6207d
sim: Add support for notifying Drainable objects of a fork

When forking a gem5 process, some objects need to clean up resources
(mainly file descriptions) shared between the child and the parent of
the fork. This changeset adds the notifyFork() method to Drainable,
which is called in the child process.

Signed-off-by: Andreas Sandberg <andreas@sandberg.pp.se>
[sascha.bischoff@arm.com: Rebased patches onto a newer gem5 version]
Signed-off-by: Sascha Bischoff <sascha.bischoff@arm.com>
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
src/python/m5/simulate.py
src/sim/drain.hh