diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000..205362e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,60 @@ +name: Bug report +description: Report a reproducible CacheVis-RV problem using sanitized information. +title: "[Bug]: " +labels: [bug] +body: + - type: markdown + attributes: + value: | + Thanks for helping improve CacheVis-RV. Remove tokens, passwords, private paths, and personal information before submitting. + - type: input + id: environment + attributes: + label: Environment + description: Windows version, Python version, and PySide6 version. + placeholder: Windows 11, Python 3.12.x, PySide6 6.x + validations: + required: true + - type: dropdown + id: lab + attributes: + label: Affected area + options: + - Platform shell / navigation + - Address Explorer + - Miss Type Lab + - Locality Lab + - Policy Lab + - Performance Lab + - Write Policy Lab + - Single Experiment + - Compare Experiment + - CLI / reports + validations: + required: true + - type: textarea + id: steps + attributes: + label: Reproduction steps + description: Use synthetic inputs and remove local absolute paths. + validations: + required: true + - type: textarea + id: expected + attributes: + label: Expected behavior + validations: + required: true + - type: textarea + id: actual + attributes: + label: Actual behavior + validations: + required: true + - type: checkboxes + id: sanitized + attributes: + label: Data safety + options: + - label: I removed tokens, passwords, private paths, personal information, and confidential traces. + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..e3c1310 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Security guidance + url: https://github.com/Yucheng-art/CacheVis-RV/blob/main/SECURITY.md + about: Read this before reporting a concern; never disclose secrets or personal data. diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..fae51f0 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,30 @@ +name: Tests + +on: + push: + branches: [main, "release/**"] + pull_request: + branches: [main] + workflow_dispatch: + +permissions: + contents: read + +jobs: + unittest: + runs-on: windows-latest + timeout-minutes: 15 + env: + QT_QPA_PLATFORM: offscreen + steps: + - name: Check out repository + uses: actions/checkout@v4 + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + cache: pip + - name: Install dependencies + run: python -m pip install -r requirements.txt + - name: Run 720-test regression suite + run: python -B -m unittest discover -s tests -v diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..adb9994 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,9 @@ +# Changelog + +## 3.0.0 — 2026-08-07 + +- Present eight available learning and classic experiment labs. +- Document the 720-test Windows verification baseline. +- Add bilingual public-facing project documentation and real application captures. +- Add repository-relative launch/test helpers and Windows CI. +- Add copyright, third-party, security, and issue-reporting safeguards. diff --git a/COPYRIGHT.md b/COPYRIGHT.md new file mode 100644 index 0000000..79e6aeb --- /dev/null +++ b/COPYRIGHT.md @@ -0,0 +1,14 @@ +# Copyright and permitted viewing + +Copyright © 2026 Yucheng Xu. All rights reserved. + +This repository is made available for portfolio review, educational evaluation, +and demonstration. It is source-available; it is not offered under an +open-source license. + +Unless Yucheng Xu gives prior written permission, no permission is granted to +copy, modify, redistribute, sublicense, use commercially, or distribute +derivative works from this repository. + +Third-party software used by this project remains subject to its own license +terms. See [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md). diff --git a/README.md b/README.md index bdb7aa6..5a2594e 100644 --- a/README.md +++ b/README.md @@ -1,57 +1,175 @@ -# CacheVis-RV V3 +# CacheVis-RV -CacheVis-RV V3 是面向计算机组成与 RISC-V Cache 教学的多实验室交互式可视化平台。当前应用身份为 `CacheVis-RV V3.0`,M0–M5 计划内功能里程碑已经完成。 +An interactive desktop platform for learning cache mapping, miss behavior, +locality, replacement policies, AMAT, and write policies. -## 版本定位 +Built with Python and PySide6 for computer architecture education and visual +experimentation. -- V1:软件著作权归档版,仅作只读参考。 -- V2:稳定 Address Visualizer 版,仅作只读参考。 -- V3:采用 Sidebar、Home、Lab Registry 与 `QStackedWidget` 的多 Lab 平台版。 +[![Tests](https://github.com/Yucheng-art/CacheVis-RV/actions/workflows/tests.yml/badge.svg)](https://github.com/Yucheng-art/CacheVis-RV/actions/workflows/tests.yml) +![Labs](https://img.shields.io/badge/labs-8_available-2563eb) +![Tests](https://img.shields.io/badge/tests-720_passing-15803d) +![Platform](https://img.shields.io/badge/tested-Windows_10%2F11-0f172a) +![Stack](https://img.shields.io/badge/Python-PySide6-7c3aed) +![Usage](https://img.shields.io/badge/source--available-all_rights_reserved-9f1239) -## 当前可用功能 +[中文说明](README.zh-CN.md) -平台共有 8 个 Available Lab,Coming Soon 为 0。 +![CacheVis-RV Home showing eight available labs](docs/assets/home-overview.webp) -Learn: +## Why CacheVis-RV -1. Address Explorer -2. Miss Type Lab -3. Locality Lab -4. Policy Lab -5. Performance Lab -6. Write Policy Lab +Cache behavior is easier to understand when addresses, cache lines, evidence, +and performance consequences are visible together. CacheVis-RV turns abstract +rules into guided, repeatable experiments while keeping the underlying models +deterministic and testable. -Classic Tools: +## What you can learn -7. Single Experiment -8. Compare Experiment +- How tag, index, and offset bits map an address into a cache. +- Why misses are compulsory, conflict, or capacity misses under the strict 3C model. +- How temporal and spatial locality change cache behavior. +- Where LRU, FIFO, and deterministic Random replacement decisions diverge. +- Why hit rate alone does not determine AMAT or total memory cost. +- How write-through/write-back and allocation choices affect dirty state and traffic. -Write Policy Lab 同步比较 Write-Through / Write-Back 与 Write-Allocate / No-Write-Allocate 四种组合,展示 dirty line、dirty eviction,以及 block fill、immediate store、bypass 和 dirty write-back 的教学流量。页面明确区分 runtime traffic 与 final dirty drain;查看历史 evidence 不会回滚当前 Cache、统计或运行位置。 +## Eight labs -平台页面按需创建并缓存,切换页面不会丢失已创建 Lab 的状态。当前回归基线为 720 项 `unittest` 全部通过、无 skip;Qt offscreen smoke、真实 GUI 入口启动、七个 Write Policy preset GUI smoke 和用户人工视觉验收均已通过。 +| Group | Lab | Focus | +| --- | --- | --- | +| Learn | Address Explorer | Address splitting, mapping, cache contents, and timeline | +| Learn | Miss Type Lab | Compulsory, conflict, and capacity evidence | +| Learn | Locality Lab | Temporal/spatial locality and block reuse | +| Learn | Policy Lab | LRU, FIFO, and deterministic Random comparison | +| Learn | Performance Lab | AMAT, timing assumptions, sweeps, and trade-offs | +| Learn | Write Policy Lab | Write propagation, allocation, dirty eviction, and traffic | +| Classic Tools | Single Experiment | Configurable trace simulation and report export | +| Classic Tools | Compare Experiment | Side-by-side cache parameter comparison | -Write Policy Lab 不模拟 store buffer、write combining、coherence、memory consistency、实际 L2、pipeline CPI、energy model、动画或专用报告导出。当前 trace 的结果只适用于给定 Cache 配置和流量假设,不代表任一策略普遍最优。 +All eight labs are available. Pages are created lazily and cached so navigation +preserves an experiment's state. -## 文档 +## Visual tour -- [产品与技术架构](docs/V3_PRODUCT_AND_TECH_ARCHITECTURE.md) -- [M0 平台外壳总结](docs/V3_M0_PLATFORM_SHELL_SUMMARY.md) -- [M0 Smoke Checklist](docs/V3_M0_SMOKE_CHECKLIST.md) -- [M1 Miss Type Lab 总结](docs/V3_M1_MISS_TYPE_LAB_SUMMARY.md) -- [M1 Miss Type Lab Smoke Checklist](docs/V3_M1_MISS_TYPE_LAB_SMOKE_CHECKLIST.md) -- [M2 Locality Lab 总结](docs/V3_M2_LOCALITY_LAB_SUMMARY.md) -- [M2 Locality Lab Smoke Checklist](docs/V3_M2_LOCALITY_LAB_SMOKE_CHECKLIST.md) -- [M3 Policy Lab 总结](docs/V3_M3_POLICY_LAB_SUMMARY.md) -- [M3 Policy Lab Smoke Checklist](docs/V3_M3_POLICY_LAB_SMOKE_CHECKLIST.md) -- [M4 Performance Lab 总结](docs/V3_M4_PERFORMANCE_LAB_SUMMARY.md) -- [M4 Performance Lab Smoke Checklist](docs/V3_M4_PERFORMANCE_LAB_SMOKE_CHECKLIST.md) -- [M5 Write Policy Lab 总结](docs/V3_M5_WRITE_POLICY_LAB_SUMMARY.md) -- [M5 Write Policy Lab Smoke Checklist](docs/V3_M5_WRITE_POLICY_LAB_SMOKE_CHECKLIST.md) -- [项目交接上下文](docs/PROJECT_HANDOFF_CONTEXT.md) -- [V2 继承计划](docs/V2_INHERITANCE_PLAN.md) -- [路线图](docs/ROADMAP.md) -- [决策记录](docs/DECISIONS.md) +### Miss Type Lab — strict 3C evidence -## 仓库约束 +![Miss Type Lab showing 3C evidence](docs/assets/miss-type-lab.webp) -V1/V2 始终只读。不得上传 `Cache*.pdf`、环境目录、缓存或构建输出;未经明确许可不得提交、推送、创建 tag 或 PR。 +### Policy Lab — LRU, FIFO, and Random side by side + +![Policy Lab replacement comparison](docs/assets/policy-lab.webp) + +### Performance Lab — hit rate is not AMAT + +![Performance Lab AMAT sweep](docs/assets/performance-lab.webp) + +### Write Policy Lab — four synchronized policy lanes + +![Write Policy Lab showing dirty state and traffic](docs/assets/write-policy-lab.webp) + +## Quick start + +Officially verified on Windows 10 and Windows 11. Other platforms have not yet +completed formal verification. + +```powershell +git clone https://github.com/Yucheng-art/CacheVis-RV.git +cd CacheVis-RV +python -m venv .venv +.\.venv\Scripts\python.exe -m pip install --upgrade pip +.\.venv\Scripts\python.exe -m pip install -r requirements.txt +.\.venv\Scripts\python.exe -B .\src\main.py --gui +``` + +After setup, the repository-relative helpers are also available: + +```powershell +.\scripts\run_gui.ps1 +.\scripts\run_tests.ps1 +``` + +## Example experiments + +- Use Address Explorer to follow `0, 4, 8, 0` one step at a time. +- Run the three Miss Type presets and inspect the actual-cache/reference-cache evidence. +- Contrast row-major and column-major matrix access in Locality Lab. +- Find the first divergence among LRU, FIFO, and Random in Policy Lab. +- Run **Hit Rate Is Not AMAT** and compare timing assumptions in Performance Lab. +- Compare all four write-policy lanes, then separate runtime traffic from final dirty drain. + +## Architecture + +The platform shell owns navigation and lazy page creation. Each teaching lab has +its own controller, immutable page state/view models, and PySide6 widget tree. +Shared cache behavior lives in a GUI-free core package. Compatibility facades +keep the established flat imports working for existing callers. + +```text +src/main.py +└── cachevis_rv/ + ├── core/ cache configuration, lines, simulator, policies, statistics + ├── experiments/ reusable runners, parsing, reporting, and services + ├── gui/ platform shell, registry, Home, sidebar, and theme + └── labs/ one independent package per lab +``` + +## Verification + +- 720 `unittest` tests pass with no skips. +- Windows clean-environment installation and Quick Start are verified. +- Qt offscreen creation/navigation smoke tests pass. +- The real GUI entry reaches the Qt event loop without a traceback. +- Core, controller, view-model, registry, parser, invariants, and platform boundaries are tested. + +Run the same suite locally: + +```powershell +.\.venv\Scripts\python.exe -B -m unittest discover -s tests -v +``` + +## Project structure + +```text +.github/ Windows CI and issue forms +docs/ architecture, milestone notes, checklists, and screenshots +scripts/ repository-relative PowerShell launchers +src/ application, core, experiments, GUI, and lab packages +tests/ unittest regression and boundary tests +``` + +## Supported scope + +CacheVis-RV is an educational, deterministic cache-learning platform. It covers +address mapping, 3C miss classification, locality evidence, replacement-policy +comparison, analytical performance modeling, and write-policy traffic under the +explicit assumptions displayed by each lab. + +## Current limitations + +- It is not a cycle-accurate or RTL simulator. +- It is not a complete memory-hierarchy or industrial performance model. +- The write-policy model does not simulate store buffers, write combining, + coherence, memory consistency, energy, or pipeline CPI. +- EXE packaging and formal validation outside Windows 10/11 are not provided. +- Results apply to the selected configuration, trace, and stated assumptions; + they do not establish a universally optimal policy. + +## Project status + +CacheVis-RV V3.0 is the current public release. The application exposes eight +available labs, and the v3.0.0 release is verified by 720 automated tests. See +[CHANGELOG.md](CHANGELOG.md) and the +[showcase release notes](docs/V3_PUBLIC_SHOWCASE_RELEASE_NOTES.md). + +## Copyright and usage + +Copyright © 2026 Yucheng Xu. All rights reserved. The code is source-available +for portfolio review, educational evaluation, and demonstration. No standard +open-source license is granted. See [COPYRIGHT.md](COPYRIGHT.md) and +[THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md). + +## Author / portfolio note + +Designed and implemented by Yucheng Xu as a computer architecture education and +software-engineering portfolio project. Responsible security reports should +follow [SECURITY.md](SECURITY.md) and must not include secrets or personal data. diff --git a/README.zh-CN.md b/README.zh-CN.md new file mode 100644 index 0000000..7936d03 --- /dev/null +++ b/README.zh-CN.md @@ -0,0 +1,163 @@ +# CacheVis-RV + +CacheVis-RV 是一个用于学习 Cache 地址映射、缺失行为、局部性、替换策略、 +AMAT 与写策略的交互式桌面平台。 + +项目使用 Python 与 PySide6 构建,面向计算机组成教学与可视化实验。 + +[![测试](https://github.com/Yucheng-art/CacheVis-RV/actions/workflows/tests.yml/badge.svg)](https://github.com/Yucheng-art/CacheVis-RV/actions/workflows/tests.yml) +![实验室](https://img.shields.io/badge/labs-8_available-2563eb) +![测试数](https://img.shields.io/badge/tests-720_passing-15803d) +![平台](https://img.shields.io/badge/tested-Windows_10%2F11-0f172a) +![技术栈](https://img.shields.io/badge/Python-PySide6-7c3aed) +![使用模式](https://img.shields.io/badge/source--available-all_rights_reserved-9f1239) + +[English](README.md) + +![显示八个可用 Lab 的 CacheVis-RV Home](docs/assets/home-overview.webp) + +## 为什么做 CacheVis-RV + +当地址、Cache 行、判定证据和性能影响同时可见时,抽象的 Cache 规则更容易理解。 +CacheVis-RV 将这些规则组织为可重复的引导实验,同时保持底层模型确定、可测试。 + +## 可以学到什么 + +- Tag、Index、Offset 如何把地址映射到 Cache。 +- 严格 3C 模型中 compulsory、conflict、capacity miss 的证据链。 +- 时间局部性与空间局部性怎样影响命中行为。 +- LRU、FIFO 与确定性 Random 的替换决定何时分歧。 +- 为什么命中率不能单独决定 AMAT 或总内存代价。 +- 写直达/写回以及写分配选择怎样影响 dirty 状态和流量。 + +## 八个 Lab + +| 分组 | Lab | 重点 | +| --- | --- | --- | +| Learn | Address Explorer | 地址拆分、映射、Cache 内容和时间线 | +| Learn | Miss Type Lab | Compulsory、conflict、capacity 证据 | +| Learn | Locality Lab | 时间/空间局部性和数据块复用 | +| Learn | Policy Lab | LRU、FIFO、确定性 Random 对比 | +| Learn | Performance Lab | AMAT、时序假设、参数扫描和权衡 | +| Learn | Write Policy Lab | 写传播、分配、脏驱逐和流量 | +| Classic Tools | Single Experiment | 可配置 trace 仿真和报告导出 | +| Classic Tools | Compare Experiment | Cache 参数并排对比 | + +八个 Lab 均已 Available。页面按需创建并缓存,因此切换页面会保留实验状态。 + +## 界面导览 + +### Miss Type Lab:严格 3C 证据 + +![Miss Type Lab 的 3C 证据](docs/assets/miss-type-lab.webp) + +### Policy Lab:并排比较 LRU、FIFO 与 Random + +![Policy Lab 替换策略比较](docs/assets/policy-lab.webp) + +### Performance Lab:命中率不等于 AMAT + +![Performance Lab AMAT 参数扫描](docs/assets/performance-lab.webp) + +### Write Policy Lab:四条同步策略 lane + +![Write Policy Lab 的 dirty 状态与流量](docs/assets/write-policy-lab.webp) + +## 快速开始 + +项目已在 Windows 10 与 Windows 11 上正式验证;其他平台尚未完成正式验证。 + +```powershell +git clone https://github.com/Yucheng-art/CacheVis-RV.git +cd CacheVis-RV +python -m venv .venv +.\.venv\Scripts\python.exe -m pip install --upgrade pip +.\.venv\Scripts\python.exe -m pip install -r requirements.txt +.\.venv\Scripts\python.exe -B .\src\main.py --gui +``` + +完成环境配置后,也可使用仓库相对路径脚本: + +```powershell +.\scripts\run_gui.ps1 +.\scripts\run_tests.ps1 +``` + +## 示例实验 + +- 在 Address Explorer 中逐步执行 `0, 4, 8, 0`。 +- 运行三个 Miss Type preset,检查实际 Cache 与全相联参考 Cache 的证据。 +- 在 Locality Lab 中比较矩阵按行与按列访问。 +- 在 Policy Lab 中寻找 LRU、FIFO、Random 首次产生分歧的位置。 +- 运行 Performance Lab 的 **Hit Rate Is Not AMAT**,比较时序假设。 +- 对比四条写策略 lane,并区分 runtime traffic 与 final dirty drain。 + +## 架构 + +平台外壳负责导航和页面延迟创建。每个教学 Lab 拥有独立 controller、不可变页面 +状态/view model 与 PySide6 widget 树。共享 Cache 行为位于不依赖 GUI 的 core package; +兼容 facade 继续支持既有扁平导入。 + +```text +src/main.py +└── cachevis_rv/ + ├── core/ Cache 配置、Cache 行、模拟器、策略与统计 + ├── experiments/ 可复用 runner、解析、报告与服务 + ├── gui/ 平台外壳、Registry、Home、Sidebar 与主题 + └── labs/ 每个 Lab 一个独立 package +``` + +## 验证 + +- 720 项 `unittest` 全部通过,无 skip。 +- Windows 干净环境安装与 Quick Start 已验证。 +- Qt offscreen 创建和导航 smoke 通过。 +- 正式 GUI 入口能够进入 Qt event loop,且无 traceback。 +- Core、controller、view model、registry、parser、不变量与平台边界均有测试。 + +本地运行同一套回归: + +```powershell +.\.venv\Scripts\python.exe -B -m unittest discover -s tests -v +``` + +## 项目结构 + +```text +.github/ Windows CI 与 issue 表单 +docs/ 架构、里程碑总结、checklist 与截图 +scripts/ 使用仓库相对路径的 PowerShell 脚本 +src/ 应用、core、experiments、GUI 与 Lab package +tests/ unittest 回归与边界测试 +``` + +## 支持范围 + +CacheVis-RV 是确定性的 Cache 教学平台,覆盖地址映射、3C 缺失分类、局部性证据、 +替换策略比较、分析式性能模型,以及在每个 Lab 明示假设下的写策略流量。 + +## 当前限制 + +- 不是 cycle-accurate 或 RTL simulator。 +- 不是完整内存层次或工业级性能模型。 +- 写策略模型不模拟 store buffer、write combining、coherence、memory consistency、 + energy 或 pipeline CPI。 +- 当前不提供 EXE 打包;Windows 10/11 之外尚未正式验证。 +- 结果只适用于所选配置、trace 与明示假设,不能证明某策略普遍最优。 + +## 项目状态 + +CacheVis-RV V3.0 是当前正式公开版本。应用包含 8 个 Available Lab,v3.0.0 +版本已通过 720 项自动化测试。参见 [CHANGELOG.md](CHANGELOG.md) 与 +[V3.0 发布说明](docs/V3_PUBLIC_SHOWCASE_RELEASE_NOTES.md)。 + +## 版权与使用 + +Copyright © 2026 Yucheng Xu. All rights reserved. 源码仅为作品集审阅、教育评估和 +演示而公开可查看;未授予标准开源许可证。详见 [COPYRIGHT.md](COPYRIGHT.md) 与 +[THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md)。 + +## 作者 / 作品集说明 + +本项目由 Yucheng Xu 设计与实现,用于计算机组成教学与软件工程作品集展示。 +安全问题请按 [SECURITY.md](SECURITY.md) 提交,报告中不得包含秘密或个人信息。 diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 0000000..b9e296b --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,13 @@ +# Security policy + +CacheVis-RV is educational demonstration software, not a production security +system. Please report reproducible security concerns through a GitHub issue +without including sensitive data. + +Before submitting, remove tokens, passwords, API keys, private repository or +filesystem paths, personal information, and any real confidential trace data. +Use minimal synthetic examples. If safe public disclosure is not possible, do +not post the sensitive material in an issue. + +Only the current showcase candidate is actively reviewed. No response-time or +security-support guarantee is offered. diff --git a/THIRD_PARTY_NOTICES.md b/THIRD_PARTY_NOTICES.md new file mode 100644 index 0000000..d030eba --- /dev/null +++ b/THIRD_PARTY_NOTICES.md @@ -0,0 +1,20 @@ +# Third-party notices + +CacheVis-RV depends on third-party software that remains subject to its own +license terms. This notice is informational and is not legal advice. + +## PySide6 + +- Requirement in this repository: `PySide6` (no version constraint) +- Version used for the clean-environment validation: `6.11.1` +- Project homepage reported by installed package metadata: +- License identifier reported by installed package metadata: + `LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only` + +PySide6 is not vendored in this repository. The repository contains application +code that calls PySide6 APIs; it does not contain PySide6 or Qt source code. + +Before distributing a binary bundle that includes Qt/PySide6, the distributor +must separately review and satisfy the applicable third-party distribution +obligations. This project's all-rights-reserved notice does not replace or +restrict rights granted by third-party licenses for their own software. diff --git a/docs/V3_PUBLIC_SHOWCASE_RELEASE_NOTES.md b/docs/V3_PUBLIC_SHOWCASE_RELEASE_NOTES.md new file mode 100644 index 0000000..911cff9 --- /dev/null +++ b/docs/V3_PUBLIC_SHOWCASE_RELEASE_NOTES.md @@ -0,0 +1,41 @@ +# CacheVis-RV V3.0 + +CacheVis-RV is a Python/PySide6 desktop platform for visual computer architecture +education. This release presents eight available labs covering address mapping, +strict 3C miss classification, locality, replacement policies, performance/AMAT, +write policies, and two classic experiment workflows. + +## Verification baseline + +- 720 automated `unittest` tests pass with no skips. +- Clean installation and launch are verified on Windows 10/11. +- Qt offscreen navigation and the real GUI event loop complete smoke checks. + +## Quick start + +```powershell +git clone https://github.com/Yucheng-art/CacheVis-RV.git +cd CacheVis-RV +python -m venv .venv +.\.venv\Scripts\python.exe -m pip install --upgrade pip +.\.venv\Scripts\python.exe -m pip install -r requirements.txt +.\.venv\Scripts\python.exe -B .\src\main.py --gui +``` + +## Current boundaries + +This is an educational deterministic model, not a cycle-accurate simulator, RTL +simulator, complete memory hierarchy, or industrial performance model. Formal +platform verification currently covers Windows 10/11 only. Results are scoped to +the selected trace, cache configuration, and explicit model assumptions. + +## Copyright mode + +The repository is source-available for portfolio review, educational evaluation, +and demonstration. Copyright © 2026 Yucheng Xu. All rights reserved. No standard +open-source license is granted; third-party components keep their own licenses. + +## Release + +Version `3.0.0` was released on 2026-08-07. The release includes the eight labs +and the verified Windows baseline described above. diff --git a/docs/assets/home-overview.webp b/docs/assets/home-overview.webp new file mode 100644 index 0000000..ba764ce Binary files /dev/null and b/docs/assets/home-overview.webp differ diff --git a/docs/assets/miss-type-lab.webp b/docs/assets/miss-type-lab.webp new file mode 100644 index 0000000..2095bd4 Binary files /dev/null and b/docs/assets/miss-type-lab.webp differ diff --git a/docs/assets/performance-lab.webp b/docs/assets/performance-lab.webp new file mode 100644 index 0000000..f1207a6 Binary files /dev/null and b/docs/assets/performance-lab.webp differ diff --git a/docs/assets/policy-lab.webp b/docs/assets/policy-lab.webp new file mode 100644 index 0000000..b51d949 Binary files /dev/null and b/docs/assets/policy-lab.webp differ diff --git a/docs/assets/social-preview.png b/docs/assets/social-preview.png new file mode 100644 index 0000000..f3c88c7 Binary files /dev/null and b/docs/assets/social-preview.png differ diff --git a/docs/assets/write-policy-lab.webp b/docs/assets/write-policy-lab.webp new file mode 100644 index 0000000..33ce1d7 Binary files /dev/null and b/docs/assets/write-policy-lab.webp differ diff --git a/scripts/run_gui.ps1 b/scripts/run_gui.ps1 new file mode 100644 index 0000000..68208b1 --- /dev/null +++ b/scripts/run_gui.ps1 @@ -0,0 +1,16 @@ +$ErrorActionPreference = "Continue" + +$repoRoot = (Resolve-Path (Join-Path $PSScriptRoot "..")).Path +$python = Join-Path $repoRoot ".venv\Scripts\python.exe" + +if (-not (Test-Path -LiteralPath $python -PathType Leaf)) { + Write-Error "Project virtual environment not found. Run: python -m venv .venv" + exit 1 +} + +$main = Join-Path $repoRoot "src\main.py" +$quotedMain = '"' + $main + '"' +$process = Start-Process -FilePath $python ` + -ArgumentList @("-B", $quotedMain, "--gui") ` + -NoNewWindow -Wait -PassThru +exit $process.ExitCode diff --git a/scripts/run_tests.ps1 b/scripts/run_tests.ps1 new file mode 100644 index 0000000..e874f7e --- /dev/null +++ b/scripts/run_tests.ps1 @@ -0,0 +1,21 @@ +$ErrorActionPreference = "Continue" + +$repoRoot = (Resolve-Path (Join-Path $PSScriptRoot "..")).Path +$python = Join-Path $repoRoot ".venv\Scripts\python.exe" + +if (-not (Test-Path -LiteralPath $python -PathType Leaf)) { + Write-Error "Project virtual environment not found. Run: python -m venv .venv" + exit 1 +} + +Push-Location $repoRoot +try { + $process = Start-Process -FilePath $python ` + -ArgumentList @("-B", "-m", "unittest", "discover", "-s", "tests", "-v") ` + -NoNewWindow -Wait -PassThru + $testExitCode = $process.ExitCode +} +finally { + Pop-Location +} +exit $testExitCode