Showcase/Request for Feedback Achieving 0.31ns Pathfinding on M1 for Search & Rescue Drones – Seeking advice on further optimization.]
Hi everyone,
I’m a student and student pilot from Vietnam, currently obsessed with combining Physics and C++ to solve real-world problems. My current project, H.A.L.O. Aegis, is a 600-700KB core designed for search-and-rescue drones operating in catastrophic environments (like collapsed buildings).
My goal was to create a "zero-latency" escape route identifier that can fit into the tiny L2 cache of embedded systems.
Current Specs:
Performance: \~0.326 ns per op on Apple M1 (measured via Google Benchmark).
Throughput: 3.0679G/s.
Memory Safety: Verified with AddressSanitizer (ASan).
The "Elephant in the room": Since I wanted to move fast on the rescue logic, I used AI to help generate some of the boilerplate and the bilingual interface (about 30-40% of the code). I manually hand-tuned the core physics-based logic to hit the sub-nanosecond mark.
Why I'm here: I’m planning to share this with NGOs like the Red Cross, but before I do, I want to make sure the code is truly "bulletproof."
Is my benchmarking methodology sound?
Are there any C++20 features I missed that could make this even more efficient for ARM64?
Please be kind—I'm still learning and I'm aware some of my internal comments might be messy (working on English-izing them!).
I'm ready for the "code review of a lifetime." If there’s anything not quite right, please let me know so I can fix it before it actually goes into a drone to save lives.
Project Link: https://github.com/Nguyenidkskibidi/halo-aegis-core
Thank you for your time and expertise!
https://redd.it/1t1h0do
@r_cpp
Post #25107
15