The industry standard for honest USB benchmarking with Direct I/O. Bypasses OS cache to give you the real flash speed โ not RAM speed.
ๅ จ็้ฆไธช็ป่ฟ OS ็ผๅญ็ U ็ / ็งปๅจๅบๆ็กฌ็่ทๅ่กไธๆ ๅใ่ฏๅซๆฉๅฎนๅ็ใๆต้็ๅฎ้ๅบฆใๅฏนๆ CrystalDiskMark / AS SSD Benchmarkใ
Keywords: USB benchmark ยท USB speed test ยท CrystalDiskMark alternative ยท AS SSD Benchmark ยท fake USB detection ยท portable SSD test ยท 4K random IOPS ยท Direct I/O ยท NO_BUFFERING ยท U็่ทๅ ยท U็ๆต้ ยท ๅU็ๆฃๆต ยท ๆฉๅฎน็่ฏๅซ ยท ็งปๅจๅบๆๆต่ฏ ยท ่กไธๆ ๅ
Every existing USB drive benchmark โ CrystalDiskMark, ATTO, HD Tune โ is lying to you.
They show your USB flash drive doing 5,000 MB/s reads and 120,000 IOPS because they measure the OS file cache (RAM speed), not the actual flash. The numbers are physically impossible: USB 2.0 tops out at 35 MB/s, USB 3.2 Gen 2 at 1.2 GB/s.
UBench bypasses the OS cache entirely (using FILE_FLAG_NO_BUFFERING on Windows, F_NOCACHE on macOS โ the same technique Microsoft DiskSpd uses) and reports the real speed your drive can deliver.
Same drive, same machine, same minute:
| Tool | SEQ1M Read | RND4K Read | What it actually measured |
|---|---|---|---|
| Naive benchmark | 5,610 MB/s | 120,169 IOPS | RAM speed (OS cache) |
| UBench | 467 MB/s | 359 IOPS | The actual USB flash chip |
The naive number was inflated 335ร for 4K random reads. That's why your "fast USB 3.0 drive" feels like garbage when you put 10,000 small files on it.
git clone https://github.com/dongsheng123132/ubench
cd ubench
cargo build --release
# Binary at: target/release/ubenchRequires Rust 1.70+.
# Quick profile (~1 minute, 4 core tests)
ubench bench E:\ --quick
# Full profile (~10 minutes, 6 tests including SLC-cache exhaustion + cold-start latency)
ubench bench E:\ --full
# Save signed JSON report (uploadable to udiskbench.org)
ubench bench E:\ --quick --out my-drive.json
# JSON output to stdout (for AI tools / CI)
ubench bench E:\ --quick --jsonโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ UBench v1.0.0 โ ่กไธๆ ๅ U็่ทๅ โ
โ ็ป่ฟ OS ็ผๅญ็็ๅฎ้ๅบฆๆต้ (Direct I/O) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
็ฎๆ ็ : E:\
ๆต่ฏๆจกๅผ : QUICK (~1 ๅ้,4 ้กน)
โโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโฌโโโโโโโโโฌโโโโโโโโโฌโโโโโโโโโ
โ ๆต่ฏ้กน โ ไธญไฝๆฐ โ ๆๅฐ โ ๆๅคง โ ็จณๅฎๆง โ
โโโโโโโโโโโโโโโโโโโโชโโโโโโโโโโโโโโชโโโโโโโโโชโโโโโโโโโชโโโโโโโโโก
โ SEQ1M Q1T1 Write โ 426.6 MB/s โ 423.5 โ 426.6 โ 0.4% โ
โ SEQ1M Q1T1 Read โ 478.5 MB/s โ 467.4 โ 478.5 โ 1.2% โ
โ RND4K Q1T1 Write โ 4630.4 IOPS โ 4297.4 โ 4630.4 โ 3.7% โ
โ RND4K Q1T1 Read โ 4214.8 IOPS โ 4157.6 โ 4214.8 โ 0.7% โ
โโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโดโโโโโโโโโดโโโโโโโโโดโโโโโโโโโ
โถโถ UBench Score (UBS): 88 / 100
โถโถ Grade : A (Excellent)
็ญพๅ: sha256:e8971c0e0e2307edf151281a0df2586f
| UBench | CrystalDiskMark | ATTO | Naive Tools | |
|---|---|---|---|---|
| Bypasses OS cache | โ Direct I/O | โ (DiskSpd) | โ | โ |
| Detects fake capacity | โ | โ | โ | โ |
| Tests SLC cache exhaustion | โ 60s sustained | โ | โ | โ |
| USB-tuned workload (Q1) | โ | โ tests Q32 | partial | โ |
| Reproducible across runs | โ seeded PRNG | โ | โ | |
| Cryptographically signed | โ SHA-256 | โ | โ | โ |
| CLI / scriptable | โ
--json |
โ GUI only | โ GUI only | mixed |
| Open spec | โ SPEC.md | partial | โ | โ |
| License | MIT | freeware | freeware | various |
A single 0-100 number summarizing the drive. See SPEC.md ยง4 for the full formula.
| UBS | Grade | Verdict |
|---|---|---|
| 85-100 | A Excellent | Premium drive, suitable for OS / heavy workload |
| 70-84 | B Good | Daily driver |
| 50-69 | C Acceptable | Document storage only |
| 25-49 | D Poor | Painful for many small files |
| 0-24 | F Garbage | Likely fake or damaged |
Weights (RND4K Read carries the most weight โ 35% โ because that's what determines whether your drive feels fast or slow in real life):
RND4K Read 35% โ The bottleneck for "many small files" workloads
RND4K Write 25%
SEQ1M Write 15%
SEQ1M Read 10%
Sustained60s 10% (Full profile only)
ColdStartRead 5% (Full profile only)
UBench v1.0 is open and free for anyone to implement. The full specification is in SPEC.md.
If you build a competing implementation that follows the spec, your scores will be directly comparable to ours. That's the entire point.
The signed JSON report format is stable across UBench v1.x. We're building udiskbench.org (coming soon) for crowd-sourced drive rankings.
Pure Rust CLI, no GUI dependencies, single binary.
src/
โโโ main.rs # Entry: tokio runtime + Ctrl+C handler
โโโ lib.rs # Module declarations + STOP_FLAG
โโโ direct_io.rs # โ
The core: Win32 NO_BUFFERING + macOS F_NOCACHE
โโโ bench/
โ โโโ profile.rs # Quick / Full test profiles (the spec)
โ โโโ runner.rs # Time-windowed test execution
โ โโโ score.rs # Logarithmic UBS scoring formula
โ โโโ report.rs # Signed JSON report (SHA-256)
โโโ disk/ # Drive detection (Windows: WMI, macOS: diskutil)
โโโ test/ # Legacy quality tests (capacity, badblock, thermal)
โโโ cli/ # Command-line interface
โโโ report/ # HTML report generation
โโโ db.rs # SQLite report history
MIT. Use it, fork it, build a startup on top of it. Just don't claim "UBench-compliant" if you broke the spec.
Issues and PRs welcome at https://github.com/dongsheng123132/ubench
The spec (SPEC.md) is the source of truth. If a measurement disagrees with the spec, the measurement is wrong, not the spec.
- Microsoft DiskSpd team โ for proving direct I/O is the right way
- CrystalDiskMark โ for popularizing benchmarking; UBench started by reading its source
- The U-Claw project โ the workload that made it obvious how broken existing benchmarks are
Run ubench test E:\ --capacity for a full write-verify scan across the drive. Any block that reads back with the wrong identifier proves capacity is fake. ่ทๅฎน้้ช่ฏๅฝไปค,ๅฆๆๅ่ฏปๆฐๆฎๆ้ไฝๅฐฑๆฏๆฉๅฎนๅ็ใ
Why does my USB drive show 5000+ MB/s in CrystalDiskMark but only 400 MB/s in UBench? / ไธบไปไน CrystalDiskMark ๆตๅบ 5000+ MB/s ไฝ UBench ๅชๆ 400 MB/s?
Because CrystalDiskMark's default settings can hit the OS file cache (RAM) instead of the actual flash chip. UBench uses FILE_FLAG_NO_BUFFERING to bypass cache entirely. The UBench number is the truth. ๅ ไธบไผ ็ป่ทๅ่ฝฏไปถ่ฏปๅฐไบ OS ็ผๅญ(ๅ
ๅญ้ๅบฆ),UBench ๅผบๅถ็ป่ฟ็ผๅญๅชๆต็ๅฎ้ชๅญใ
Can UBench numbers be compared to AS SSD Benchmark? / UBench ็ๆฐๅญ่ฝ่ท AS SSD ๆชๅพๅฏนๆฏๅ?
Yes โ run ubench bench E:\ --asssd for the 6-test AS SSD compatibility profile. Direct comparison with merchant screenshots. ็จ --asssd ๆจกๅผๅฏไปฅ็ดๆฅๅฏนๆฏ AS SSD ๆชๅพใ
- 85+ : Premium tier (SanDisk Extreme Pro, Samsung Bar Plus level)
- 70-84 : Good daily driver
- 50-69 : Document storage only
- 25-49 : Painful for many small files (e.g. running U-Claw)
- 0-24 : Likely fake or defective
UBench --quick mode: ~1 minute. AS SSD compat: ~3 minutes. Full: ~10 minutes. CrystalDiskMark default 5ร1GB: ~3-5 minutes. Similar.
- Sequential 1MB: large file transfer (movies, ISOs)
- Random 4K Q1T1: small files (U-Claw boot, photo browsing, Git operations)
- Random 4K-64Thrd: heavy parallel load (virtual machines, video editing)
- Sustained 60s write: SLC cache exhaustion (catches drives that look fast for 5 sec then collapse)
- U-Claw small files: real workload of opening N small files in sequence
Yes. UBench classifies the device automatically (USB flash / portable SSD / NVMe / SATA SSD / HDD) and uses the same scoring formula across all of them โ so a USB stick scoring 86 means absolute performance similar to an NVMe scoring 86. The classification is shown in the report only as a label.
See the comparison table above. Key differences: only UBench bypasses OS cache by default, detects fake capacity, tests SLC cache exhaustion, and produces signed reports.
Yes โ uses F_NOCACHE fcntl on macOS for direct I/O. Build with cargo build --release.
udiskbench.org scoreboard is in development. Until then, submit your JSON report via GitHub Issues using the drive-result template.
- Microsoft DiskSpd โ the gold-standard low-level disk benchmark for Windows
- CrystalDiskMark โ popular GUI front-end for DiskSpd
- fio โ Linux/Unix flexible I/O tester
- AS SSD Benchmark โ SSD-focused benchmark popular in Chinese market
USB benchmark ยท USB speed test ยท USB IOPS test ยท 4K random read test ยท fake USB detection ยท portable SSD benchmark ยท flash drive quality test ยท disk benchmark CLI ยท CrystalDiskMark alternative ยท AS SSD alternative ยท Rust disk benchmark ยท direct I/O benchmark ยท Windows storage benchmark ยท macOS storage benchmark ยท U็่ทๅ ยท U็้ๅบฆๆต่ฏ ยท U็่ดจ้ๆฃๆต ยท U็็ๅ ยท ๆฉๅฎน็ๆฃๆต ยท ๅU็่ฏๅซ ยท ็งปๅจๅบๆๆต้ ยท 4K้ๆบ่ฏปๅ ยท ่กไธๆ ๅ่ทๅ ยท ๅผๆบ่ทๅๅทฅๅ
ท
