microsoft / microsoft/STL

<algorithm>: Shuffle algorithms can save registers

Open
#1,163 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

performance
Dominant language
C++
Stars
11.1k
Forks
1.7k
Avg merge
4d 15h
Merged PRs (30d)
22

Description

This is a replayed old report VSO-278082 from @CaseyCarter that came up last time we touched std::shuffle to fix an integer overflow bug. Internally we had marked it 'vNext' because it would change the shuffle order which we considered 'quasi-ABI', but https://github.com/microsoft/STL/issues/178 suggests that we are willing to make changes to the output of distributions.

The original report:
image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the original report image and the std::shuffle implementation, then read the distribution-output compatibility discussion in issue 178. The issue does not name files, tests, or a precise acceptance criterion; done would require identifying and validating a register-saving change without an unacceptable shuffle-order compatibility impact.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.