mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-19 03:24:09 +00:00
[lib/Fuzzer] guess the right number of workers if -jobs=N is given but -workers=M is not. Update the docs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237163 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -61,4 +61,12 @@ void SetTimer(int Seconds) {
|
||||
assert(Res == 0);
|
||||
}
|
||||
|
||||
int NumberOfCpuCores() {
|
||||
FILE *F = popen("nproc", "r");
|
||||
int N = 0;
|
||||
fscanf(F, "%d", &N);
|
||||
fclose(F);
|
||||
return N;
|
||||
}
|
||||
|
||||
} // namespace fuzzer
|
||||
|
Reference in New Issue
Block a user