Debian Codegraph @

third_party/rust/profiling/src/puffin_impl.rs

raw
1 #[macro_export]
2 macro_rules! scope {
3 ($name:expr) => {
4 $crate::puffin::profile_scope!($name);
5 };
6 ($name:expr, $data:expr) => {
7 $crate::puffin::profile_scope!($name, $data);
8 };
9 }
10
11 #[macro_export]
12 macro_rules! register_thread {
13 () => {};
14 ($name:expr) => {
15 // puffin uses the thread name
16 };
17 }
18
19 /// Finishes the frame. This isn't strictly necessary for some kinds of applications but a pretty
20 /// normal thing to track in games.
21 #[macro_export]
22 macro_rules! finish_frame {
23 () => {
24 $crate::puffin::GlobalProfiler::lock().new_frame();
25 };
26 }