Skip to content

Conversation

@JeanPhilippeKernel
Copy link
Owner

@JeanPhilippeKernel JeanPhilippeKernel commented Jul 7, 2025

This PR integrates an Arena Allocator into the rendering engine to improve memory management, allocation efficiency, and performance across multiple subsystems. The changes touch core rendering paths, UI components, and data handling infrastructure.

Key Changes

  • Arena Allocator Adoption: Core engine and UI code paths now use arena-based memory allocation, reducing fragmentation and improving performance.
  • Editor Scene Refactoring: Significant restructuring of the editor scene for improved clarity, modularity, and maintainability.
  • AssetManager Added: Introduction of an AssetManager to centralize and streamline asset loading, tracking, and management.
  • GPU Buffer Pre-allocation: Pre-allocation strategies for GPU buffers implemented to minimize runtime allocations and stutter during scene loading or asset streaming.
  • UI & Windowing: Updates and optimizations to UI components (log, inspector, hierarchy views) with arena-backed data structures.
  • Drag-and-Drop Support: You can now drag and drop scene files and mesh files directly into the viewport to open them.

@JeanPhilippeKernel JeanPhilippeKernel moved this to In Progress in ZEngine Board Jul 11, 2025
@JeanPhilippeKernel JeanPhilippeKernel marked this pull request as ready for review July 11, 2025 17:22
@JeanPhilippeKernel JeanPhilippeKernel added enhancement New feature or request Feature request New feature vulkan-api labels Jul 11, 2025
TEST_F(HashMapTest, InitialState)
{
HashMap<int, int> array;
array.init(&allocator, 10, 0);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe in void init(Memory::ArenaAllocator* allocator, size_type initial_capacity, size_type initial_size) we can set initial_size to default to 0 so it can be optional

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do/did we ever use that initial_size ? AFAIK I didn't see us using it - that's the reason I decided to drop it

Comment on lines +94 to +95
static value_type temp = **this;
return &temp;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

static variable shared by ALL iterators wont this cause problem?

@jnyfah jnyfah merged commit 794ce0d into develop Jul 14, 2025
17 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in ZEngine Board Jul 14, 2025
@jnyfah jnyfah deleted the user/kernel/scene-draw branch July 14, 2025 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-macOS Work on macOS system area-rendering area-ui area-window Work on Window system enhancement New feature or request Feature request New feature vulkan-api

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants