| 1 | #include "include/UTL/profiler.hpp" |
| 2 | |
| 3 | void recursive(int depth = 0) { |
| 4 | if (depth > 4) { |
| 5 | std::this_thread::sleep_for(std::chrono::milliseconds(50)); |
| 6 | return; |
| 7 | } |
| 8 | |
| 9 | UTL_PROFILER("1st recursion branch") recursive(depth + 1); |
| 10 | UTL_PROFILER("2nd recursion branch") recursive(depth + 2); |
| 11 | } |
| 12 | |
| 13 | int main() { |
| 14 | recursive(); |