ruby: Fix RubySystem warm-up and cool-down scope
Review Request #2738 - Created April 15, 2015 and submitted
| Information | |
|---|---|
| Joel Hestness | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 10832:e1ce7cc2abbd --------------------------- ruby: Fix RubySystem warm-up and cool-down scope The processes of warming up and cooling down Ruby caches are simulation-wide processes, not just RubySystem instance-specific processes. Thus, the warm-up and cool-down variables should be globally visible to any Ruby components participating in either process. Make these variables static members and track the warm-up and cool-down processes as appropriate. This patch also has two side benefits: 1) It removes references to the RubySystem g_system_ptr, which are problematic for allowing multiple RubySystem instances in a single simulation. Warmup and cooldown variables being static (global) reduces the need for instance-specific dereferences through the RubySystem. 2) From the AbstractController, it removes local RubySystem pointers, which are used inconsistently with other uses of the RubySystem: 11 other uses reference the RubySystem with the g_system_ptr. Only sequencers have local pointers.
1) Patience when hearing statements of the form "if you'd like something done (an easy and better way), do it yourself". The review process is meant to avoid making other people fix your changes.
2) Regressions pass
3) Checkpoint restore into Ruby works with all memory controllers (used MI_example and MOESI_hammer)
Posted (May 17, 2015, 1:46 a.m.)
Would it make sense to declare the two variables: warmup and cooldown as global instead of having them a static members of RubySystem? If we want to move towards having multiple ruby systems, I would prefer all static variables in ruby system be simply made global.
-
src/mem/ruby/system/System.hh (Diff revision 1) -
You are returning the same variable from both the functions.
Review request changed
Updated (May 18, 2015, 8:49 a.m.)
Description: |
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+24 -19) |
Ship It!
