Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions ai/memory-bank/tasks/TASK_1_CCD_GITHUB_ISSUE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Title
Continuous Collision Detection (CCD) Implementation

## Labels
enhancement, physics

## Body
Implement Continuous Collision Detection to prevent "tunneling" at high velocities. This involves calculating time of impact (TOI) between moving bodies.

**Acceptance Criteria**:
- 0% tunneling observed at velocities up to 1000m/s.
- CCD pipeline integrates with the existing collision detection system.
- Performance impact remains within acceptable bounds for high-speed simulations.

Continuous Collision Detection (CCD) Implementation needs to be resolved/issued/tested by the Physics Engineer.
15 changes: 15 additions & 0 deletions ai/memory-bank/tasks/TASK_2_DOD_GITHUB_ISSUE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Title
Data-Oriented Design (DOD) & ECS Refactoring

## Labels
architecture, refactoring

## Body
Refactor core engine structures to support Data-Oriented Design, making it compatible with modern ECS architectures like Bevy and Flecs.

**Acceptance Criteria**:
- Memory layout is optimized for cache coherency.
- API allows integration with a standard ECS in under 2 hours.
- Core systems (e.g., rigid body updates) operate on flat arrays or similar DOD structures.

Data-Oriented Design (DOD) & ECS Refactoring needs to be resolved/issued/tested by the Architecture Lead.
16 changes: 16 additions & 0 deletions ai/memory-bank/tasks/TASK_3_SIMD_GITHUB_ISSUE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Title
Multithreading and SIMD Vectorization

## Labels
performance, optimization

## Body
Integrate `rayon` for task-based parallelism and the `wide` crate (instead of std::simd) for vectorizing math operations in the physics pipeline over Data-Oriented Design (DOD) Structure of Arrays (SoA) layouts.

**Acceptance Criteria**:
- Engine scales linearly up to 16 threads on supported hardware.
- Core math operations (vector additions, dot products, cross products) utilize SIMD instructions via the `wide` crate.
- Thread synchronization does not introduce unresolvable latency.
- Parallel iteration over multiple mutable arrays must be chained using `.par_iter_mut().zip(...)` instead of passing tuples.

Multithreading and SIMD Vectorization needs to be resolved/issued/tested by the Systems Engineer.
15 changes: 15 additions & 0 deletions ai/memory-bank/tasks/TASK_4_DETERMINISM_GITHUB_ISSUE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Title
Cross-Platform Determinism Setup

## Labels
determinism, ci

## Body
Implement strict floating-point math control and deterministic solver execution across multiple architectures using `libm`.

**Acceptance Criteria**:
- Simulation yields identical results across different CPU architectures.
- CI testing pipeline includes deterministic behavior checks.
- Fallback mechanisms for non-deterministic math functions are implemented.

Cross-Platform Determinism Setup needs to be resolved/issued/tested by the Systems Engineer.
17 changes: 17 additions & 0 deletions ai/memory-bank/tasks/TASK_5_GPU_GITHUB_ISSUE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Title
GPU Acceleration (Compute Shaders) Integration

## Labels
gpu, wgpu

## Body
Future-proof the engine by integrating `wgpu` (~v0.19) for GPU-accelerated compute shaders, targeting massive scale simulations like soft-bodies or fluids.

**Acceptance Criteria**:
- Basic WGPU context is established and integrated into the build.
- A prototype compute shader runs and passes data back to the CPU physics pipeline.
- CPU pipeline remains stable during GPU execution.
- WGSL shaders must avoid 16-byte alignment crashes by using flat `array<f32>` (indexing by 3) instead of `array<vec3<f32>>`.
- `Vector3d` sent via `bytemuck` must use `#[repr(C)]` with `Pod` and `Zeroable` derives.

GPU Acceleration (Compute Shaders) Integration needs to be resolved/issued/tested by the Graphics Engineer.
5 changes: 1 addition & 4 deletions ai/memory-bank/tasks/worm-engine-tasklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
### [ ] Task 4: SIMD Vectorization Implementation
**Description**: Integrate `wide` for vectorizing math operations in the physics pipeline. Defer until DOD refactoring is complete to use a Structure of Arrays (SoA) approach. Avoid applying Array of Structures (AoS) SIMD to individual math primitives like `Vector3d`.
**Acceptance Criteria**:
- Core math operations (vector additions, dot products, cross products) utilize SIMD instructions.
- Core math operations (vector additions, dot products, cross products) utilize SIMD instructions via the `wide` crate.
- SIMD implementation leverages SoA approach exclusively without overhead on individual primitives.

**Files to Create/Edit**:
Expand Down Expand Up @@ -95,9 +95,6 @@
**Assignment**: GPU Acceleration (Compute Shaders) Integration needs to be resolved/issued/tested by the Graphics Engineer

## Quality Requirements
- [ ] Must pass `cargo check` cleanly
- [ ] Must pass `cargo test` suite
- [ ] No background processes in any commands - NEVER append `&`
- [ ] Iterating multiple mutable SoA arrays in `rayon` must chain `.par_iter_mut().zip(...)`
- [ ] WGSL shaders must avoid 16-byte alignment crashes by using flat `array<f32>` and Rust structs must use `#[repr(C)]`, `Pod`, and `Zeroable`.

Expand Down