Files
hakmem/benchmarks/results/comprehensive_comparison.md
Moe Charm (CI) 52386401b3 Debug Counters Implementation - Clean History
Major Features:
- Debug counter infrastructure for Refill Stage tracking
- Free Pipeline counters (ss_local, ss_remote, tls_sll)
- Diagnostic counters for early return analysis
- Unified larson.sh benchmark runner with profiles
- Phase 6-3 regression analysis documentation

Bug Fixes:
- Fix SuperSlab disabled by default (HAKMEM_TINY_USE_SUPERSLAB)
- Fix profile variable naming consistency
- Add .gitignore patterns for large files

Performance:
- Phase 6-3: 4.79 M ops/s (has OOM risk)
- With SuperSlab: 3.13 M ops/s (+19% improvement)

This is a clean repository without large log files.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-05 12:31:14 +09:00

98 lines
3.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 📊 包括的ベンチマーク結果: HAKMEM vs System
## Test 1-6 詳細比較 (6パターン × 4サイズ = 24テスト)
### 16B サイズクラス
| Test Pattern | HAKMEM | System | vs System |
|--------------|--------|--------|-----------|
| 1. Sequential LIFO | 66.00 M/s | 161.15 M/s | **-59.0%** ❌ |
| 2. Sequential FIFO | 66.38 M/s | 159.71 M/s | **-58.4%** ❌ |
| 3. Random Free | 54.03 M/s | 102.09 M/s | **-47.1%** ❌ |
| 4. Interleaved | 66.28 M/s | 141.72 M/s | **-53.2%** ❌ |
| 6. Long/Short-lived | 65.30 M/s | 160.62 M/s | **-59.3%** ❌ |
**平均**: 63.60 M/s vs 145.06 M/s → **-56.2%** 💀
---
### 32B サイズクラス
| Test Pattern | HAKMEM | System | vs System |
|--------------|--------|--------|-----------|
| 1. Sequential LIFO | 60.22 M/s | 163.51 M/s | **-63.2%** ❌ |
| 2. Sequential FIFO | 61.13 M/s | 155.76 M/s | **-60.8%** ❌ |
| 3. Random Free | 50.30 M/s | 106.87 M/s | **-52.9%** ❌ |
| 4. Interleaved | 61.00 M/s | 166.53 M/s | **-63.4%** ❌ |
| 6. Long/Short-lived | 59.40 M/s | 174.06 M/s | **-65.9%** ❌ |
**平均**: 58.41 M/s vs 153.35 M/s → **-61.9%** 💀
---
### 64B サイズクラス
| Test Pattern | HAKMEM | System | vs System |
|--------------|--------|--------|-----------|
| 1. Sequential LIFO | 51.83 M/s | 168.55 M/s | **-69.2%** ❌ |
| 2. Sequential FIFO | 51.76 M/s | 169.14 M/s | **-69.4%** ❌ |
| 3. Random Free | 43.96 M/s | 107.04 M/s | **-58.9%** ❌ |
| 4. Interleaved | 51.94 M/s | 158.50 M/s | **-67.2%** ❌ |
| 6. Long/Short-lived | 51.14 M/s | 162.62 M/s | **-68.6%** ❌ |
**平均**: 50.13 M/s vs 153.17 M/s → **-67.3%** 💀💀
---
### 128B サイズクラス
| Test Pattern | HAKMEM | System | vs System |
|--------------|--------|--------|-----------|
| 1. Sequential LIFO | 39.54 M/s | 75.34 M/s | **-47.5%** ❌ |
| 2. Sequential FIFO | 39.54 M/s | 80.91 M/s | **-51.1%** ❌ |
| 3. Random Free | 35.49 M/s | 48.50 M/s | **-26.8%** 🤔 |
| 4. Interleaved | 39.96 M/s | 81.28 M/s | **-50.8%** ❌ |
| 6. Long/Short-lived | 40.20 M/s | 86.92 M/s | **-53.7%** ❌ |
**平均**: 38.95 M/s vs 74.59 M/s → **-47.8%** ❌
---
### Mixed Sizes (8B, 16B, 32B, 64B)
| Test Pattern | HAKMEM | System | vs System |
|--------------|--------|--------|-----------|
| 5. Mixed Sizes | 62.37 M/s | 161.77 M/s | **-61.4%** ❌ |
---
## 📉 全体サマリー (21テスト)
| Metric | HAKMEM | System | Ratio |
|--------|--------|--------|-------|
| **全体平均** | **52.59 M/s** | **135.94 M/s** | **-61.3%** 💀💀 |
| 最高値 | 66.38 M/s | 174.06 M/s | -61.9% |
| 最低値 | 35.49 M/s | 48.50 M/s | -26.8% |
---
## 🔥 フラグメンテーションストレス
| Allocator | Throughput | vs System |
|-----------|------------|-----------|
| HAKMEM | **4.68 M/s** | **-74.6%** 💥💥💥 |
| System | **18.43 M/s** (推定) | 100% |
**重大な問題**: フラグメンテーション耐性が極めて弱い!
---
## 🎯 結論
### HAKMEM の弱点が明確化:
1. **Tiny (≤1KB)**: System の 1/3 以下 (-60~-70%) 💀
2. **フラグメンテーション**: System の 1/4 (-75%) 💥
3. **パターン感度**: LIFO/FIFO/Random すべてで劣る
### HAKMEM が強い領域:
1. **Mid-Large (8-32KB)**: System の 2.08倍 (+108%) ✅
2. **専用最適化 (HAKX 8-32KB)**: System の 2.71倍 (+171%) 🏆
### 戦略的判断:
**Tiny を諦め、Mid-Large に集中すべき**