bugGNU Parallel - Bugs: bug #65160, -j100% (default) uses only one...

 
 

bug #65160: -j100% (default) uses only one thread

Submitter:  Clément <thebigbadboy>
Submitted:  Sat 13 Jan 2024 09:24:12 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 08 Feb 2024 10:47:03 PM UTC, comment #1: 

This issue is now fixed in version 20240122.

Clément <thebigbadboy>
Sat 13 Jan 2024 09:24:12 PM UTC, original submission:  

Lately, with the update to version 20231222, parallel does not use more than one thread by default.
The default value for `-j` is 100% and as the man page says (for the flag `-j`):

>Run up to num jobs in parallel. Default is 100%.
>E.g. 100% means one job per CPU thread on each machine.


Here is an example of output and problem I have (after the version of parallel):
```sh
$ parallel --version
GNU parallel 20231222
Copyright (C) 2007-2023 Ole Tange, http://ole.tange.dk and Free Software
Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
GNU parallel comes with no warranty.

$ time parallel -j 100% sleep {} \; echo {%} ::: 1 1 1 1
1
1
1
1

real    0m4,373s
user    0m0,093s
sys     0m0,055s
$ time parallel -j 16 sleep {} \; echo {%} ::: 1 1 1 1
1
2
3
4

real    0m1,095s
user    0m0,101s
sys     0m0,048s
$ nproc
16
```
We can see that the default behavior takes 4 seconds to complete, while setting properly the `-j` flag it only takes one seconds (which should be the behavior of `-j 100%`).

I downgraded GNU parallel to version "20231122" (one month before the problematic one - 20231222), and the default behavior works (the above command will finish in ~1s with `-j 100%`).

Clément <thebigbadboy>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by thebigbadboy (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    No changes have been made to this item

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code