taskmanager gets very busy when many processes are created/destroyed in short time period
After running the last script below, the taskmanager gui freezes for a few seconds and the process is 100% busy on one core.
#setup
$ mkdir pipes
$ mkfifo pipes/pipe{1..10000}
save this script as runchain
.
#!/bin/sh
# runchain
#how many processes should be launched?
NUM=10000
NUM=5000
NUM=3000 # I start to notice taskmanager lags with 3000
# NUM=2000
echo using $NUM pipes.
for N in $(seq $((NUM-1))); do
cat <pipes/pipe$N >pipes/pipe$((N+1)) &
done
echo aligned cats.
time { printf "1" >pipes/pipe1;
read OUT <pipes/pipe$NUM; }
Then start taskmanager and run $ sh runchain
. The gui freezes for a while.
Increase NUM to see, that taskmanager is busy even after the other processes exited and got cleaned up.
It's not the whole system or the scheduler that's creating the lagging.
I'm using version 1.4.2. I think a taskmanager should not freeze in this situation.