Skip to content

bench: add factory benchmarks to random/base PRNGs#11563

Merged
kgryte merged 4 commits intodevelopfrom
philipp/drift-random-base-2026-04-19
Apr 19, 2026
Merged

bench: add factory benchmarks to random/base PRNGs#11563
kgryte merged 4 commits intodevelopfrom
philipp/drift-random-base-2026-04-19

Conversation

@Planeshifter
Copy link
Copy Markdown
Member

@Planeshifter Planeshifter commented Apr 19, 2026

Description

What is the purpose of this pull request?

This pull request:

  • adds benchmark/benchmark.factory.js to @stdlib/random/base/gamma
  • adds benchmark/benchmark.factory.js to @stdlib/random/base/randi
  • adds benchmark/benchmark.factory.js to @stdlib/random/base/randn
  • adds benchmark/benchmark.factory.js to @stdlib/random/base/randu

These were missing even though factory methods are present for the respective PRNGs.

Related Issues

Does this pull request have any related issues?

No related issues.

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

No.

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

If you answered "yes" to using AI assistance, please provide a short disclosure indicating how you used AI assistance. This helps reviewers determine how much scrutiny to apply when reviewing your contribution. Example disclosures: "This PR was written primarily by Claude Code." or "I consulted ChatGPT to understand the codebase, but the proposed changes were fully authored manually by myself.".

This PR was written primarily by Claude Code.


@stdlib-js/reviewers

@stdlib-bot
Copy link
Copy Markdown
Contributor

stdlib-bot commented Apr 19, 2026

Coverage Report

Package Statements Branches Functions Lines
random/base/gamma $\color{green}623/623$
$\color{green}+0.00%$
$\color{green}93/93$
$\color{green}+0.00%$
$\color{green}13/13$
$\color{green}+0.00%$
$\color{green}623/623$
$\color{green}+0.00%$
random/base/randi $\color{green}381/381$
$\color{green}+0.00%$
$\color{green}34/34$
$\color{green}+0.00%$
$\color{green}9/9$
$\color{green}+0.00%$
$\color{green}381/381$
$\color{green}+0.00%$
random/base/randn $\color{green}402/402$
$\color{green}+0.00%$
$\color{green}42/42$
$\color{green}+0.00%$
$\color{green}9/9$
$\color{green}+0.00%$
$\color{green}402/402$
$\color{green}+0.00%$
random/base/randu $\color{green}381/381$
$\color{green}+0.00%$
$\color{green}34/34$
$\color{green}+0.00%$
$\color{green}9/9$
$\color{green}+0.00%$
$\color{green}381/381$
$\color{green}+0.00%$

The above coverage report was generated for the changes in this PR.

@stdlib-js stdlib-js deleted a comment from stdlib-bot Apr 19, 2026
claude added 4 commits April 19, 2026 04:54
Adds the conventional `:factory`, `:factory:seed=<integer>`, and
`:factory:seed=<array>` benchmarks for `@stdlib/random/base/gamma.factory`.
Adds the conventional `:factory`, `:factory:seed=<integer>`, and
`:factory:seed=<array>` benchmarks for `@stdlib/random/base/randi.factory`.
Adds the conventional `:factory`, `:factory:seed=<integer>`, and
`:factory:seed=<array>` benchmarks for `@stdlib/random/base/randn.factory`.
Adds the conventional `:factory`, `:factory:seed=<integer>`, and
`:factory:seed=<array>` benchmarks for `@stdlib/random/base/randu.factory`.
@Planeshifter Planeshifter force-pushed the philipp/drift-random-base-2026-04-19 branch from 872b867 to ad702dc Compare April 19, 2026 04:56
@Planeshifter Planeshifter changed the title style: align outliers in random/base with namespace majority patterns bench: add factory benchmarks to random/base PRNGs Apr 19, 2026
@Planeshifter Planeshifter marked this pull request as ready for review April 19, 2026 05:03
@Planeshifter Planeshifter requested review from a team and kgryte April 19, 2026 05:03
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label Apr 19, 2026
@kgryte kgryte added Benchmarks Pull requests adding or improving benchmarks for measuring performance. review: 5 and removed Needs Review A pull request which needs code review. labels Apr 19, 2026
Copy link
Copy Markdown
Member

@kgryte kgryte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kgryte
Copy link
Copy Markdown
Member

kgryte commented Apr 19, 2026

As the CI failure is not due to changes introduced in this PR, I'll go ahead and merge.

@kgryte kgryte merged commit 4574e32 into develop Apr 19, 2026
80 of 81 checks passed
@kgryte kgryte deleted the philipp/drift-random-base-2026-04-19 branch April 19, 2026 07:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Benchmarks Pull requests adding or improving benchmarks for measuring performance. review: 5

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants