Skip to content

cksum: print file name for explicit - operand - #16031

Open
Logic769 wants to merge 2 commits into
uutils:mainfrom
Logic769:cksum-explicit-stdin-filename
Open

Logic769 wants to merge 2 commits into
uutils:mainfrom
Logic769:cksum-explicit-stdin-filename

Conversation

@Logic769

Copy link
Copy Markdown
Contributor

Problem

cksum - (an explicit - operand) printed the checksum without the file name, while GNU cksum prints - as the file name for an explicit operand. Only an implicit stdin (no operands) omits the name.

Change

Track whether the - operand was given explicitly on the command line and print the file name in that case. Added a regression test.

Closes #15984

@Logic769
Logic769 force-pushed the cksum-explicit-stdin-filename branch from 47a8a9b to 209f560 Compare October 30, 2026 13:02
@codspeed

codspeed Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Merging this PR will degrade performance by 4.54%

1 warning, 1 note

⚠️ 125 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

ℹ️ 1 benchmark has no flamegraph

The flamegraph wasn't generated: most of the time was spent in runtime internals, which would leave nothing useful to analyze.

See affected benchmarks

❌ 1 regressed benchmark
✅ 400 untouched benchmarks
⏩ 70 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
❌ CPU Simulation df_deep_directory 888.9 µs 931.1 µs -4.54%

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing Logic769:cksum-explicit-stdin-filename (5a67d7b) with main (8e267ce)2

Open in CodSpeed

Footnotes

  1. 70 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

  2. No successful run was found on main (19f6602) during the generation of this report, so 8e267ce was used instead as the comparison base. There might be some changes unrelated to this pull request in this report. ↩

@Logic769
Logic769 force-pushed the cksum-explicit-stdin-filename branch from 209f560 to b99cd58 Compare November 2, 2026 01:02
Comment thread tests/by-util/test_cksum.rs Resolved
Comment thread tests/by-util/test_cksum.rs Resolved
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/misc/usage_vs_getopt (fails in this run but passes in the 'main' branch)

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cksum: explicit - operand is not printed as file name

2 participants