Repository navigation
Tech Stack and Build
MasterLaplace edited this page Jul 14, 2026
·
5 revisions
| Language / Tool | Usage |
|---|---|
| C++23 | Full engine β all 20 static-library modules (-fno-rtti, -fno-exceptions; lpl-bci re-enables -fexceptions) |
| C17 | Linux kernel module (lpl_kmod.c), network protocol |
| Vulkan | Vulkan rendering backend, ImGui integration (optional, --renderer) |
| CUDA | GPU physics kernels (PhysicsKernel.cu) β optional (--cuda), automatic CPU fallback |
| xmake | Build system β orchestrates all modules as static libraries |
- Linux with kernel headers (for the kernel module)
- xmake β₯ 2.9.0
- GCC 13+ or Clang 17+ (C++23 support)
- Vulkan SDK (vulkan-headers, vulkan-loader, vulkan-hpp)
- ImGui (auto-fetched by xmake with GLFW + Vulkan backends)
- NVIDIA CUDA Toolkit (optional β automatic CPU fallback)
-
BCI dependencies (
eigen,liblsl,brainflow) are auto-fetched by xmake from the official xmake-repo;brainflowis optional
LplPlugin/
βββ xmake.lua # Root orchestrator (project settings, module includes)
βββ core/ # Platform abstraction, types, assertions
β βββ include/lpl/core/ # Public headers
β βββ src/ # Implementation
β βββ xmake.lua # Module build config (lpl-core)
βββ math/ # Vec3, Quat, Fixed32, CORDIC, BoundaryBox
βββ memory/ # PinnedAllocator, pool allocators
βββ container/ # FlatAtomicsHashMap, Morton encoding
βββ concurrency/ # ThreadPool, SpinLock
βββ gpu/ # CUDA lifecycle, physics kernels (inline stubs w/o nvcc)
βββ ecs/ # EntityRegistry, Partition (SoA chunks)
βββ physics/ # WorldPartition, collision, octree
βββ net/ # transport (kernel / socket), protocol, session, netcode
βββ input/ # InputManager (keys, axes, neural)
βββ platform/ # HW backends (clock/display/gpu-memory/input)
βββ render/ # software + Vulkan renderer, ImGui (optional)
βββ shaders/ # shader sources
βββ image/ # 2D software imaging (Surface, Painter, Codec)
βββ scene/ # scene graph (Scene, Transform2D)
βββ audio/ # Spatial audio (stub)
βββ haptic/ # Haptic feedback (stub)
βββ bci/ # OpenBCI driver, FFT, SignalMetrics, Riemannian, calibration
β βββ include/lpl/bci/
β βββ src/
β βββ tests/
βββ serial/ # state serialization & deterministic replay
βββ bench/ # benchmark harness (Harness, SystemInfo)
βββ engine/ # Top-level facade (depends on ALL modules)
βββ kernel/ # Linux kernel module (lpl_kmod.c)
βββ apps/ # Executables
β βββ server/ # lpl-server (headless, authoritative)
β βββ client/ # lpl-client (desktop / VR)
β βββ benchmark/ # lpl-benchmark (micro-benchmark suite)
βββ samples/ # example codeEach module follows the pattern: <module>/include/lpl/<module>/ for public headers, <module>/src/ for implementations, with .inl files for inline function bodies.
| Target | Command | Description |
|---|---|---|
| All | xmake build -j$(nproc) |
Build all 20 modules + 3 executables |
| Server | xmake build lpl-server |
Headless authoritative server |
| Client | xmake build lpl-client |
Vulkan desktop client |
| Benchmark | xmake build lpl-benchmark |
CPU benchmark (ECS, physics, containers) |
| Clean | xmake clean |
Remove all build artifacts |
| Reconfigure | xmake f -c |
Clean configuration and cache |
xmake f -m debug # Debug symbols, no optimization, LPL_DEBUG
xmake f -m release # -O fastest, stripped, NDEBUG
xmake f -m profile # Debug symbols + -O fastest, LPL_PROFILE| Option | Description |
|---|---|
--renderer=y/n |
Enable/disable Vulkan renderer (useful for headless server) |
--cuda=y/n |
Enable/disable CUDA GPU physics kernels |
xmake kmod-build # Build the lpl_kmod.ko module
xmake kmod-install # Load the module (insmod) and set /dev/lpl0 permissions
xmake kmod-uninstall # Unload the module (rmmod)
xmake kmod-logs # Show recent kernel logs
xmake kmod-clean # Clean kernel build artifactsxmake run lpl-server
xmake run lpl-client
xmake run lpl-benchmark| Flag | Rationale |
|---|---|
-fno-rtti |
No runtime type information β smaller binary, faster dispatch |
-fno-exceptions |
No C++ exceptions β deterministic control flow, zero overhead |
VULKAN_HPP_NO_EXCEPTIONS |
Vulkan C++ bindings without exceptions |
-std=c++23 |
Concepts, std::expected, consteval, structured bindings |
-Werror -Wall -Wextra |
Zero-tolerance for warnings |
β Architecture | Next: Modules β
LplPlugin β Zero-Copy Real-Time VR Engine | Author: MasterLaplace | License: GPL-3.0 | Source Code
This project is a marathon, not a sprint.