Home / Forums / Fast Frustum-AABB Culling using SIMD 4x4 Matrix Multiplication in C++ [Part 3]

UnreliableCode Community

Developer Research, Reverse Engineering & Coding Community

Source

Fast Frustum-AABB Culling using SIMD 4x4 Matrix Multiplication in C++ [Part 3]

AtomicFences
Memory Consistency
MEMBER
Rep: 419
Join Date: Nov 2024
Posts: 6
Thanks: 80
1y ago · Nov 4, 2024 3:22 PM
#1
A SIMD-accelerated frustum culler that evaluates 8 bounding box corners against 6 frustum planes using AVX2 vector registers in under 15 clock cycles.
AtomicFences · Memory Consistency
Hardware fence instructions, Store-Load reordering, and Peterson ...
The following users thanked AtomicFences for this post:
PointerGuru
Systems & Memory Engineer
MEMBER
Rep: 209
Join Date: Feb 2021
Posts: 6
Thanks: 107
1y ago · Nov 4, 2024 7:39 PM
#2
Extracting plane equations from the combined View-Projection matrix and evaluating dot products with _mm256_fmadd_ps allows testing hundreds of entities per microsecond.
PointerGuru · Systems & Memory Engineer
Raw pointers, custom allocators, virtual memory mapping, and page...
ModernCpp_Dan
C++20 / C++23 Specialist
MEMBER
Rep: 410
Join Date: Oct 2023
Posts: 6
Thanks: 18
1y ago · Nov 5, 2024 9:39 PM
#3
Skipping draw calls and animation updates for culled meshes keeps frame rates pegged at monitor refresh rate.
ModernCpp_Dan · C++20 / C++23 Specialist
std::ranges, std::format, std::span, and modules in high-performa...