mirror of
https://github.com/bootandy/dust.git
synced 2026-06-08 11:29:05 +03:00
[GH-ISSUE #52] dust hangs on a single-core computer #23
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @tavianator on GitHub (Jan 15, 2020).
Original GitHub issue: https://github.com/bootandy/dust/issues/52
Even on an empty directory, dust hangs:
It works fine if I specify the number of threads:
It works fine on all my other boxes, so I'm guessing it's the fact that this one has only 1 core that is to blame. Here's a stack trace:
@tavianator commented on GitHub (Jan 16, 2020):
It works if I set
RAYON_NUM_THREADS=2, so I think it's ajwalkbug assuming the pool has at least two threads.@bootandy commented on GitHub (Jan 16, 2020):
Hmm, that sucks.
Good find.
I can reproduce this by setting
RAYON_NUM_THREADS=1I wonder if I can hack round this problem for now.
Thanks.
@bootandy commented on GitHub (Jan 17, 2020):
I've looked at the jwalk code and I'm sure there's a multithreading edgecase bug in there but I can't see it.
I think I'll use the
num_cpuslibrary to look for 1 CPU and force the threads=1 if it isn't set to something else. It's an ugly solution but I can't think of anything else,What do you think @tavianator ?
@bootandy commented on GitHub (Jan 19, 2020):
Fixed in new version.
@tavianator commented on GitHub (Jan 21, 2020):
Yeah I think that workaround makes sense. It would have been fine to use 1 thread I think, rather than 2, since
-t1explicitly works fine.