| Dimension | Shared | Only in A | Only in B | Overlap |
|---|---|---|---|---|
| Sections | 0 | 6 | 7 | 0% |
| Commands | 0 | 0 | 3 | 0% |
| Section tags | 1 | 1 | 5 | 14% |
What each file covers
Sections
0 shared · 6 only in A · 7 only in B- − Performance Rules for Fasten
- − Targets
- − Benchmarking
- − Memory
- − Optimization
- − Monitoring
- + Development Rules for Fasten
- + Environment
- + Build
- + Testing
- + Debugging
- + CI/CD
- + Workflow
Commands
0 shared · 0 only in A · 3 only in B- + zig build
- + zig build clean
- + zig build test
Section tags
1 shared · 1 only in A · 5 only in B- − performance
- + setup
- + build
- + test
- + deployment
- + agent-behaviour
- do-not
Line diff
v1truv1us/fasten · .cursor/rules/performance.mdc
@@ −3 @@
3globs:
4alwaysApply: true
5---
6# Performance Rules for Fasten
7
8## Targets
9- Small: <100ms, <10MB; Medium: <500ms, <50MB; Large: <2s, <200MB; XL: <10s, <500MB.
10- Lexer: >1MB/s; Parser: >500KB/s; Optimizer: >2MB/s; Codegen: >5MB/s.
11- Cold start <50ms; base memory <5MB.
12
13## Benchmarking
14- Use provided benchmark framework; warmup, multiple iterations, throughput checks.
15- Assert performance targets in tests; fail on regression >10%.
16
17## Memory
18- Use ArenaAllocator for temp data; Pool for frequent allocations.
19- Profile memory; zero tolerance for leaks; peak usage <2x input size.
20
21## Optimization
22- Minimize allocations in hot paths; use stack allocation when possible.
23- Profile before optimizing; document all optimizations.
24- Use efficient data structures (interning, compact AST).
25
26## Monitoring
27- Collect and log metrics (time, memory, compression ratio).
28- Alert on slow bundling, high memory, poor compression.
29- Run performance and memory tests in CI.
30
v1truv1us/fasten · .cursor/rules/development.mdc
@@ +3 @@
3globs:
4alwaysApply: true
5---
6# Development Rules for Fasten
7
8## Environment
9- Use Zig 0.11.0+; set up with Homebrew, direct download, or package manager.
10- Recommended: VS Code with ziglang extension, or Vim/Neovim with zig.vim.
11
12## Build
13- Use `zig build` for standard, debug, release, and safe builds.
14- Use build options for features and target platforms.
15- Clean with `zig build clean`.
16
17## Testing
18- Run all tests with `zig build test`.
19- Organize tests: unit, integration, performance, regression.
20- Use memory leak detection and verbose output as needed.
21
22## Debugging
23- Use debug builds and Zig's logging.
24- Use Valgrind, AddressSanitizer, or platform profilers for memory/perf issues.
25
26## CI/CD
27- Use GitHub Actions for build, test, benchmark, security, docs.
28- Simulate CI locally with provided scripts.
29
30## Workflow
31- Feature: branch, test, implement, benchmark, document, PR.
32- Bugfix: reproduce, fix, verify, regression test, PR.
33- Review: self-review, CI, peer review, address feedback, merge.
34
@@ −3 +3 @@
33 globs:
44 alwaysApply: true
55 ---
6−# Performance Rules for Fasten
6+# Development Rules for Fasten
77
8−## Targets
9−- Small: <100ms, <10MB; Medium: <500ms, <50MB; Large: <2s, <200MB; XL: <10s, <500MB.
10−- Lexer: >1MB/s; Parser: >500KB/s; Optimizer: >2MB/s; Codegen: >5MB/s.
11−- Cold start <50ms; base memory <5MB.
8+## Environment
9+- Use Zig 0.11.0+; set up with Homebrew, direct download, or package manager.
10+- Recommended: VS Code with ziglang extension, or Vim/Neovim with zig.vim.
1211
13−## Benchmarking
14−- Use provided benchmark framework; warmup, multiple iterations, throughput checks.
15−- Assert performance targets in tests; fail on regression >10%.
12+## Build
13+- Use `zig build` for standard, debug, release, and safe builds.
14+- Use build options for features and target platforms.
15+- Clean with `zig build clean`.
1616
17−## Memory
18−- Use ArenaAllocator for temp data; Pool for frequent allocations.
19−- Profile memory; zero tolerance for leaks; peak usage <2x input size.
17+## Testing
18+- Run all tests with `zig build test`.
19+- Organize tests: unit, integration, performance, regression.
20+- Use memory leak detection and verbose output as needed.
2021
21−## Optimization
22−- Minimize allocations in hot paths; use stack allocation when possible.
23−- Profile before optimizing; document all optimizations.
24−- Use efficient data structures (interning, compact AST).
22+## Debugging
23+- Use debug builds and Zig's logging.
24+- Use Valgrind, AddressSanitizer, or platform profilers for memory/perf issues.
2525
26−## Monitoring
27−- Collect and log metrics (time, memory, compression ratio).
28−- Alert on slow bundling, high memory, poor compression.
29−- Run performance and memory tests in CI.
26+## CI/CD
27+- Use GitHub Actions for build, test, benchmark, security, docs.
28+- Simulate CI locally with provided scripts.
29+
30+## Workflow
31+- Feature: branch, test, implement, benchmark, document, PR.
32+- Bugfix: reproduce, fix, verify, regression test, PR.
33+- Review: self-review, CI, peer review, address feedback, merge.
3034
