Pádraig Brady <[email protected]> writes: > With -n4 only 1 process would be started. > Could you repeat with -n1 please for comparison. > One would only need to increase -n for large numbers of files.
Sprry the mistake. In this case results are equal. $ time ./sha1sum --threads=2 /tmp/test_files/* a91f3339c20255db34c8489440dcc43c004d41cb /tmp/test_files/a 89b1e89850b377e74b027777c7cb15e480ba6311 /tmp/test_files/b a54bc57f943632adb9982f492b145a61229c2721 /tmp/test_files/c e1a9de5dc7f97cc18cade55d04ea0b3dd52ac4f0 /tmp/test_files/d real 0m1.821s $ time find /tmp/test_files/* | xargs -n2 -P2 ./sha1sum a54bc57f943632adb9982f492b145a61229c2721 /tmp/test_files/c e1a9de5dc7f97cc18cade55d04ea0b3dd52ac4f0 /tmp/test_files/d a91f3339c20255db34c8489440dcc43c004d41cb /tmp/test_files/a 89b1e89850b377e74b027777c7cb15e480ba6311 /tmp/test_files/b real 0m3.389s $ time ls /tmp/test_files/* | xargs -n1 -P2 ./sha1sum 89b1e89850b377e74b027777c7cb15e480ba6311 /tmp/test_files/b a54bc57f943632adb9982f492b145a61229c2721 /tmp/test_files/c e1a9de5dc7f97cc18cade55d04ea0b3dd52ac4f0 /tmp/test_files/d a91f3339c20255db34c8489440dcc43c004d41cb /tmp/test_files/a real 0m1.844s Giuseppe
