diff options
| author | Eric Holk <eholk@mozilla.com> | 2011-06-29 18:56:34 -0700 |
|---|---|---|
| committer | Eric Holk <eholk@mozilla.com> | 2011-06-29 18:56:34 -0700 |
| commit | b3e5b5bd05fabf9b68ef350632254aa696d74b89 (patch) | |
| tree | 5f768053ca7c3e3fcdb4d88286bd1d9dd5dc8d71 /src/rt/rust_task.cpp | |
| parent | 63dcd325b909051f53682dc6ddb2d6768ffbbba3 (diff) | |
| download | rust-b3e5b5bd05fabf9b68ef350632254aa696d74b89.tar.gz rust-b3e5b5bd05fabf9b68ef350632254aa696d74b89.zip | |
Added inheritance for task pinning. Closes #598 for real.
Diffstat (limited to 'src/rt/rust_task.cpp')
| -rw-r--r-- | src/rt/rust_task.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/rt/rust_task.cpp b/src/rt/rust_task.cpp index 46c9aebe6cf..b2a60dc92bc 100644 --- a/src/rt/rust_task.cpp +++ b/src/rt/rust_task.cpp @@ -528,9 +528,15 @@ rust_task::free(void *mem, memory_region::memory_region_type type) { } void rust_task::pin() { + I(this->sched, running_on != -1); pinned_on = running_on; } +void rust_task::pin(int id) { + I(this->sched, running_on == -1); + pinned_on = id; +} + void rust_task::unpin() { pinned_on = -1; } |
