summaryrefslogtreecommitdiff
path: root/concurrency.c
diff options
context:
space:
mode:
authorglenda <glenda@cirno>2022-09-13 15:37:47 +0000
committerglenda <glenda@cirno>2022-09-13 15:37:47 +0000
commitcb3dbf22c21ef2d4ad43f718dd9360b7f4008cc8 (patch)
tree34d571936c269573efe93b1fe2b611f9d352499b /concurrency.c
parented5a7271655be2d846d8d1ef37b7f51dd24c8ad9 (diff)
Call it threads, not tasks
Diffstat (limited to 'concurrency.c')
-rw-r--r--concurrency.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/concurrency.c b/concurrency.c
index f35f329..28cea35 100644
--- a/concurrency.c
+++ b/concurrency.c
@@ -244,19 +244,19 @@ newthreaddata(Array *name)
}
Array *
-runningtasks(void)
+runningthreads(void)
{
lock(&threadlock);
- Array *tasks = allocarray(AtypeInt, 1, nthreads);
- tasks->shape[0] = nthreads;
+ Array *t = allocarray(AtypeInt, 1, nthreads);
+ t->shape[0] = nthreads;
for(int i = 0; i < nthreads; i++)
- tasks->intdata[i] = threads[i]->id;
+ t->intdata[i] = threads[i]->id;
unlock(&threadlock);
- return tasks;
+ return t;
}
Array *
-taskproperty(vlong t, vlong p)
+threadproperty(vlong t, vlong p)
{
ThreadData *td = nil;
Array *res = nil;
@@ -290,7 +290,7 @@ taskproperty(vlong t, vlong p)
break;
default:
unlock(&threadlock);
- throwerror(L"Invalid task property", EDomain);
+ throwerror(L"Invalid thread property", EDomain);
break;
}