bugmake - Bugs: bug #62100, [PATCH] Add '--shuffle' argument...


bug #62100: [PATCH] Add '--shuffle' argument support

Submitter:  Sergei Trofimovich <slyfox>
Submitted:  Wed 23 Feb 2022 07:51:47 AM UTC
Severity:  3 - Normal Item Group:  Enhancement
Status:  Fixed Privacy:  Public
Assigned to:  psmith Open/Closed:  Closed
Component Version:  None Operating System:  Any
Fixed Release:  4.4 Triage Status:  Medium Effort
* Mandatory Fields

Add a New Comment Rich Markup

Jump to the original submission

Sat 18 Jun 2022 08:58:21 PM UTC, comment #8: 

I applied this with a few cleanups.

Thanks for your work on this!

Paul D. Smith <psmith>
Group administrator
Mon 06 Jun 2022 07:59:18 AM UTC, comment #7: 

Thanks for v7. Hope that we will have this soon in make to help these packages: https://trofi.github.io/posts/230-when-make-j-nproc-fails.html :)

Fangrui Song <maskray>
Sun 22 May 2022 09:57:37 PM UTC, comment #6: 

Adding a v7-0001-Add-shuffle-argument-support.patch which 2 extra changes:
1. fixed 'if' indentation in src/main.c noticed by Fangrui Song
2. tweaked --help output to '--shuffle[={SEED|random|identity|reverse|none}]' noticed by Fangrui Song

Sergei Trofimovich <slyfox>
Sun 22 May 2022 09:18:15 PM UTC, comment #5: 

--shuffle has caught some brittle dependency issues in glibc:
https://sourceware.org/bugzilla/show_bug.cgi?id=29167 build failures with make --shuffle -j N

There is a coding style issue in v6. Left a comment on

It'd be nice to move forward with the patch. (I'd wish that bmake from NetBSD can add this as well. I've come across quite a few issues in FreeBSD.)

Fangrui Song <maskray>
Tue 03 May 2022 10:31:17 PM UTC, comment #4: 

Caught bugs in a few upstream projects. Two nice simple examples:
- vim: https://github.com/vim/vim/pull/9978
- groff: https://savannah.gnu.org/bugs/?62084

Sergei Trofimovich <slyfox>
Fri 11 Mar 2022 08:18:21 PM UTC, comment #3: 

Uploaded v6-0001-Add-shuffle-argument-support.patch. It's the rebased v5 against today's make.git where a small merge conflict is fixed around added option. Otherwise identical to v5.

Sergei Trofimovich <slyfox>
Sun 27 Feb 2022 11:32:47 PM UTC, comment #2: 

Thanks Sergei.  I'll add some code review comments here today or tomorrow.

Paul D. Smith <psmith>
Group administrator
Wed 23 Feb 2022 10:38:40 PM UTC, comment #1: 

Changes from v4: presence of `.NOTPARALLEL:` target disables shuffling as makefile is already known to be broken in target reorder caused by -j parallelism.

Example of real package is `netpbm`. Upstream does not plan to fix it.

Sergei Trofimovich <slyfox>
Wed 23 Feb 2022 07:51:47 AM UTC, original submission:  

The idea of the change is to introduce non-deterministic ordering
into goal and prerequisite traversal to imitate non-deterministic
ordering of 'make -j g1 g2 g3' mode.

Filing the bug to make sure it does not get lost.

The patch is against current git tree:

$ git describe

Sergei Trofimovich <slyfox>


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

Attach Files:


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by maskray (Posted a comment)
  • -email is unavailable- added by psmith (Updated the item)
  • -email is unavailable- added by slyfox (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.


    Follow 11 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-06-18 psmith StatusNone Fixed
        Assigned toNone psmith
        Open/ClosedOpen Closed
        Operating SystemNone Any
        Fixed ReleaseNone 4.4
        Triage StatusNone Medium Effort
    2022-05-22 slyfox Attached File- Added v7-0001-Add-shuffle-argument-support.patch, #53242
    2022-03-11 slyfox Attached File- Added v6-0001-Add-shuffle-argument-support.patch, #52979
    2022-02-27 psmith Item GroupNone Enhancement
    2022-02-23 slyfox Attached File- Added v5-0001-Add-shuffle-argument-support.patch, #52917
    2022-02-23 slyfox Attached File- Added v4-0001-Add-shuffle-argument-support.patch, #52908

    Back to the top

    Powered by Savane 3.12