summaryrefslogtreecommitdiff
path: root/src/sim/process.hh
diff options
context:
space:
mode:
authorBrandon Potter <brandon.potter@amd.com>2016-11-09 14:27:41 -0600
committerBrandon Potter <brandon.potter@amd.com>2016-11-09 14:27:41 -0600
commitea8461885ffffa0933cedeb9143a9b01be4c70f0 (patch)
treeeae67294034a6c3f2e1fdfb53de8108386c24f1d /src/sim/process.hh
parentb792e9e43c855cdb2fbf71084ee8e60eb4878741 (diff)
downloadgem5-ea8461885ffffa0933cedeb9143a9b01be4c70f0.tar.xz
syscall_emul: [patch 7/22] remove numCpus method
The numCpus method is misleading in that it's not really a measure of how many CPUs might be executing a process, but how many thread contexts are assigned to the process at any given point in time. It's nice to highlight this distinction because thread contexts are never reused in the same way that a CPU can be reused for multiple processes. The reason that there is no reuse is that there is no CPU scheduler for SE. The tru64 code intends to use this method and the accompanying contextIDs field to support SMT and track the number of threads with some system calls. With the up coming clone and exec patches, this paradigm must change. There needs to be a 1:1 mapping between the thread contexts and processes so that the process state between threads is allowed to vary when needed by Linux. This should not break SMT for tru64 if the Process class is refactored so that multiple Processes can share state between themselves. The following patches will do the refactoring incrementally as features are added.
Diffstat (limited to 'src/sim/process.hh')
-rw-r--r--src/sim/process.hh3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/sim/process.hh b/src/sim/process.hh
index 5d6835c21..f3d0f1b62 100644
--- a/src/sim/process.hh
+++ b/src/sim/process.hh
@@ -79,9 +79,6 @@ class Process : public SimObject
// thread contexts associated with this process
std::vector<ContextID> contextIds;
- // number of CPUs (esxec contexts, really) assigned to this process.
- unsigned int numCpus() { return contextIds.size(); }
-
// record of blocked context
struct WaitRec
{