Skip to content

Commit ed3a5ad

Browse files
committed
rt: Remove running_on flag. Does nothing
1 parent 57cad61 commit ed3a5ad

File tree

3 files changed

+1
-9
lines changed

3 files changed

+1
-9
lines changed

src/rt/rust_scheduler.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -282,9 +282,7 @@ rust_scheduler::start_main_loop() {
282282
DLOG(this, task,
283283
"Running task %p on worker %d",
284284
scheduled_task, id);
285-
scheduled_task->running_on = id;
286285
activate(scheduled_task);
287-
scheduled_task->running_on = -1;
288286

289287
DLOG(this, task,
290288
"returned from task %s @0x%" PRIxPTR

src/rt/rust_task.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,6 @@ rust_task::rust_task(rust_scheduler *sched, rust_task_list *state,
244244
list_index(-1),
245245
next_port_id(0),
246246
rendezvous_ptr(0),
247-
running_on(-1),
248247
local_region(&sched->srv->local_region),
249248
boxed(&local_region),
250249
unwinding(false),
@@ -626,8 +625,7 @@ rust_task::backtrace() {
626625

627626
bool rust_task::can_schedule(int id)
628627
{
629-
return
630-
running_on == -1;
628+
return true;
631629
}
632630

633631
void *

src/rt/rust_task.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,10 +98,6 @@ rust_task : public kernel_owned<rust_task>, rust_cond
9898
// that location before waking us up.
9999
uintptr_t* rendezvous_ptr;
100100

101-
// This flag indicates that a worker is either currently running the task
102-
// or is about to run this task.
103-
int running_on;
104-
105101
memory_region local_region;
106102
boxed_region boxed;
107103

0 commit comments

Comments
 (0)