feat(docs): add comprehensive dependency architecture and build optimization document
- Introduced a new document detailing YAZE's dependency architecture, identifying optimization opportunities, and proposing a roadmap for reducing build times and improving maintainability. - Included a complete dependency graph, key findings, and a detailed refactoring plan to enhance modularity and reduce circular dependencies. - Document serves as a reference for future development and architectural decisions, aiming for 40-60% faster incremental builds. Benefits: - Provides a clear understanding of the current state and future direction for YAZE's architecture. - Facilitates better decision-making for developers regarding library organization and build optimization strategies.
This commit is contained in:
@@ -22,6 +22,8 @@
|
||||
- `WIN32_LEAN_AND_MEAN` - Reduce Windows header pollution
|
||||
- `NOMINMAX` - Prevent min/max macro conflicts
|
||||
- `NOGDI` - Prevent GDI macro conflicts (DWORD, etc.)
|
||||
- `__PRFCHWINTRIN_H` - Work around Clang 20 `_m_prefetchw` linkage clash with
|
||||
Windows SDK headers
|
||||
|
||||
**Build Times:**
|
||||
- First build with FetchContent: ~45-60 minutes (compiles gRPC)
|
||||
@@ -133,6 +135,21 @@ Before merging platform-specific changes:
|
||||
- ✅ Cross-platform code uses SDL2/ImGui only
|
||||
- ⏳ Validate CI builds pass on next push
|
||||
|
||||
### CI/CD Performance Roadmap
|
||||
|
||||
- **Dependency caching**: Cache vcpkg installs on Windows plus Homebrew/apt
|
||||
archives to trim 5-10 minutes per job; track cache keys via OS + lockfiles.
|
||||
- **Compiler caching**: Enable `ccache`/`sccache` across the matrix using the
|
||||
`hendrikmuhs/ccache-action` with 500 MB per-run limits for 3-5 minute wins.
|
||||
- **Conditional work**: Add a path-filter job that skips emulator builds or
|
||||
full test runs when only docs or CLI code change; fall back to full matrix on
|
||||
shared components.
|
||||
- **Reusable workflows**: Centralize setup steps (checking out submodules,
|
||||
restoring caches, configuring presets) to reduce duplication between `ci.yml`
|
||||
and `release.yml`.
|
||||
- **Release optimizations**: Use lean presets without test targets, run platform
|
||||
builds in parallel, and reuse cached artifacts from CI when hashes match.
|
||||
|
||||
---
|
||||
|
||||
## Testing Strategy
|
||||
|
||||
Reference in New Issue
Block a user