diff --git a/src/lib.rs b/src/lib.rs index aec54d1..cfab2d3 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,3 +1,6 @@ +#[global_allocator] +static GLOBAL: tracy_client::ProfiledAllocator = tracy_client::ProfiledAllocator::new(std::alloc::System, 100); + use std::{ops::Deref, sync::Arc}; use cgmath::prelude::*; @@ -136,6 +139,9 @@ pub async fn run() { #[cfg(not(target_arch = "wasm32"))] tracy_client::Client::start(); + #[cfg(not(target_arch = "wasm32"))] + tracy_client::Client::running().unwrap().set_thread_name("MAIN THREAD"); + let event_loop = EventLoop::new(); let title = env!("CARGO_PKG_NAME"); let window = winit::window::WindowBuilder::new()