Skip to content

pow%doc: document the opt-level for debug builds - #139

Merged
PastaPastaPasta merged 1 commit into
dashpay:developfrom
ZocoLini:docs/pow-debug-builds
Nov 19, 2026
Merged

PastaPastaPasta merged 1 commit into
dashpay:developfrom
ZocoLini:docs/pow-debug-builds

Conversation

@ZocoLini

@ZocoLini ZocoLini commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Motivation

Unoptimized, the SIMD code of the X11 hash runs tens of times slower than in release, because each vector operation becomes function calls and stack copies. Cargo ignores the profiles of dependencies, so downstream debug builds get the slow path.

Closes #134.

Additional Information

This adds a Debug Builds section to the dash-pow README that tells workspaces to set opt-level = 3 for dash-pow in their root Cargo.toml.

Checklist

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional tests
  • I have made corresponding changes to the documentation
  • I did not use agentic assistance (i.e. LLMs, AI) except as disclosed and can answer questions,
    comments and concerns without said assistance. I assume authorship of the code submitted.
  • I have assigned this pull request to a milestone (for repository code-owners and collaborators only)

Agent disclosure

May be assisted by Opus 5.5, medium effort.

@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@github-actions

Copy link
Copy Markdown

Note

This pull request has no conflicts! 🎊 🎉 🎊

@thepastaclaw

thepastaclaw commented Nov 18, 2026 •

Copy link
Copy Markdown

✅ Final review complete — Phase 1 only — no blockers (commit 7404a26) · triage: trivial

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Preliminary review — Phase 1 blocker gate

The README change is accurate and the build, test, documentation, and platform checks passed. However, the required Lint check fails because the commit and PR title use the unsupported docs type instead of doc, and the commit body contains a line exceeding the repository's 73-column limit; these metadata issues must be corrected before merge.

Validated blockers were found by the Phase-1 review and confirmed by a fresh verifier. Phase 2 is deferred until a fresh same-head revalidation clears the blocker gate.

🔴 1 blocking

Review provenance

Source: reviewer 1: glm-5.3-flash (agent: phase1-reviewer, role: general); final verifier: gpt-6.2-sol (agent: sol-gate-verifier, role: verifier)

  • Triage: trivial by gpt-6.2-sol (effort low) — This is a documentation-only README addition with no code, configuration, or behavioral changes, so a second review round adds nothing.
  • Phase 1 reviewers: glm-5.3-flash — general (completed, effort high); agent phase1-reviewer
  • Phase 1 model: glm-5.3-flash — zai quota: 5h 99% left, weekly 92% left; passed over gemini-3.8-flash-high (antigravity quota lookup failed)
  • Fresh verifier: gpt-6.2-sol — verifier; agent sol-gate-verifier
  • Phase 2 reviewers: not run (deferred by blocker gate)
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `pkgs/pow/README.md`:
- [BLOCKING] pkgs/pow/README.md:55-63: Commit and PR title fail the repository commit lint
  The Lint check fails for this change because commit `f49ac1d4` and the PR title use `pow%docs:`, but `maint/commit.toml` permits `doc`, not `docs`. The commit body also contains a 252-character line, exceeding the configured 73-column maximum. Rename the subject and PR title to `pow%doc: document the opt-level for debug builds`, and reflow the body to fit the repository's width limit. The README content itself is valid; this finding concerns the metadata required for the changed file to pass the repository gate.

Comment thread pkgs/pow/README.md Resolved
@kwvg kwvg added this to the 0.2 milestone Nov 18, 2026
@kwvg kwvg moved this to Crypto in base-sdk v0.2 Nov 18, 2026
Unoptimized, the X11 SIMD code runs tens of times slower. Cargo ignores
dependency profiles, so the README tells downstream workspaces to
optimize `dash-pow` themselves.
@ZocoLini
ZocoLini force-pushed the docs/pow-debug-builds branch from f49ac1d to 7404a26 Compare November 18, 2026 13:40
@ZocoLini ZocoLini changed the title pow%docs: document the opt-level for debug builds pow%doc: document the opt-level for debug builds Nov 18, 2026
@github-actions github-actions Bot added the topic:Crypto Pull requests that primarily concern the dash-{pkc,pow} crate. label Nov 18, 2026
@PastaPastaPasta

Copy link
Copy Markdown
Member

The Lint failure is the old title. The title check read pow%docs: from the event that started the run, and editing the title does not start a new run. The current title, pow%doc:, passes the check. The check will clear on your next push, so there's nothing to fix.

The maintainer is away, so the review of this PR will come from the steward (#131).


🤖 Posted autonomously by Claude (claude-opus-5-5) on behalf of pasta.

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Re-review — Final review — Phase 1 only (trivial change)

The change is a focused documentation-only update that accurately explains the debug-build performance issue and provides the correct root-workspace Cargo profile override for dash-pow. CI passed for build and test jobs; the remaining lint failure was caused by the superseded pow%docs: title rather than the current commit or documentation.

🔴 0 blocking | 🟡 0 suggestion(s) | 💬 0 nitpick(s)

Review provenance

Source: reviewer 1: glm-5.3-flash (agent: phase1-reviewer, role: general); final verifier: gpt-6.2-sol (agent: sol-gate-verifier, role: final-verifier)

  • Triage: trivial by gpt-6.2-sol (effort low) — This is a documentation-only README addition with no code or behavior changes, so a second review round adds nothing.
  • Phase 1 reviewers: glm-5.3-flash — general (completed, effort high); agent phase1-reviewer
  • Phase 1 model: glm-5.3-flash — zai quota: 5h 98% left, weekly 91% left; passed over gemini-3.8-flash-high (antigravity quota lookup failed)
  • Fresh verifier: gpt-6.2-sol — final-verifier; agent sol-gate-verifier
  • Phase 2 reviewers: not run (triage rated this change trivial); this review comments and never approves
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review. Verify the current code and confirm that no unresolved issues remain.

No unresolved findings remain from the prior review on this head.

@PastaPastaPasta PastaPastaPasta left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Steward review at 7404a26: the description only, then I merge. The maintainer is away, and the steward reviews and merges in his place (#131).

The text is right. An independent review measured it with an X11 probe crate, counting instructions:

  • a debug build of dash-pow costs 33 times a release build;
  • the documented [profile.dev.package.dash-pow] opt-level = 3 brings it to within 1.7 times;
  • raising wide alone barely helps.

The section sits outside the sysinfo markers and before omit, so it appears on the site's pow page and not in the top-level hardware notes. Closing #134 with documentation is fine, since that is what you proposed there.

Change: the description goes into the merge commit, so it uses the repository's template: Motivation, Additional Information, Breaking Changes, How Has This Been Tested?, the checklist, and the Agent disclosure section if any AI tool was used. A description edit needs no push.

Checks: I am closing and reopening this PR once. That starts a run that reads the corrected title, because the title check does not re-run on an edit. I am also re-running the two jobs that were cancelled while being set up. Nothing for you to do there.


🤖 Posted autonomously by Claude (claude-opus-5-5) on behalf of pasta.

@github-actions github-actions Bot added the status:behind This pull request can be rebased on the base branch. label Nov 18, 2026
@ZocoLini

Copy link
Copy Markdown
Contributor Author

@thepastaclaw how do i get this merged??

@thepastaclaw

Copy link
Copy Markdown

@ZocoLini on it — I've queued this as job cj-20261119-095806-e98e and will reply here or link a PR when there's something to look at.

@PastaPastaPasta

PastaPastaPasta commented Nov 19, 2026 •

Copy link
Copy Markdown
Member

@ZocoLini One step is left, and it is yours: edit the PR description into the repository's template. Everything else is done. All 37 checks pass on 7404a26 and the README text is approved, so no push and no other review is needed. I merge as soon as the description is in place.

The description becomes the merge commit's message, which is why it has to follow the template. Here is your text arranged that way. Fill in the testing line and the disclosure, which only you can answer. Tick the agentic-assistance box if its statement is true of you, which it is if you used no AI tool or disclosed the ones you used. Delete the disclosure section if you used none:

## Motivation

Unoptimized, the SIMD code of the X11 hash runs tens of times slower than in release, because each vector operation becomes function calls and stack copies. Cargo ignores the profiles of dependencies, so downstream debug builds get the slow path.

Closes #134.

## Additional Information

This adds a Debug Builds section to the `dash-pow` README that tells workspaces to set `opt-level = 3` for `dash-pow` in their root `Cargo.toml`.

## How Has This Been Tested?

<how you checked the slowdown and the fix>

## Checklist

- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional tests
- [x] I have made corresponding changes to the documentation
- [ ] I did not use agentic assistance (i.e. LLMs, AI) except as [disclosed](#agent-disclosure) and can answer questions,
      comments and concerns without said assistance. I assume authorship of the code submitted.
- [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_

### Agent disclosure

<model name, version, tool and effort, e.g. "Code generated with Claude Code using Sonnet 4.6, high effort.">

Breaking Changes is left out because the template says to omit sections that do not apply.


🤖 Posted autonomously by Claude (claude-opus-5-5) on behalf of pasta.

@thepastaclaw

Copy link
Copy Markdown

@ZocoLini Your code and README are already approved, and all checks are passing. The only remaining step is to edit the PR description to match the repository template: keep the Motivation and Additional Information, omit Breaking Changes since it does not apply, fill in How Has This Been Tested? with what you actually ran/measured, and complete the checklist. If you used an AI tool, leave the Agent disclosure section and state the model/tool/effort; otherwise remove that section and leave the AI checkbox unticked. Once the description is updated, the steward can merge it—no code push is needed.

@ZocoLini

Copy link
Copy Markdown
Contributor Author

@thepastaclaw and now??

@PastaPastaPasta
PastaPastaPasta merged commit bd2970c into dashpay:develop Nov 19, 2026
71 of 77 checks passed
@thepastaclaw

Copy link
Copy Markdown

@ZocoLini on it — I've queued this as job cj-20261119-103006-6f73 and will reply here or link a PR when there's something to look at.

@PastaPastaPasta

Copy link
Copy Markdown
Member

@ZocoLini Merged into develop as bd2970c. The description was the last step; nothing else is needed from you.


🤖 Posted autonomously by Claude (claude-opus-5-5) on behalf of pasta.

@thepastaclaw

Copy link
Copy Markdown

@ZocoLini It is merged now: PR #139 landed in develop as commit bd2970cb. No further action is needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:behind This pull request can be rebased on the base branch. topic:Crypto Pull requests that primarily concern the dash-{pkc,pow} crate.

Projects

Status: Crypto

Development

Successfully merging this pull request may close these issues.

perf(dash-pow): X11 slow in unoptimized builds

4 participants