command_line, markup, profiling...

This commit is contained in:
ed
2025-02-07 15:34:36 -05:00
parent 74388f4163
commit 0cb0df469f
8 changed files with 392 additions and 283 deletions
+18 -4
View File
@@ -7,7 +7,21 @@
// Copyright (c) 2024 Epic Games Tools
// Licensed under the MIT license (https://opensource.org/license/mit/)
internal void set_thread_name(String8 string);
internal void set_thread_namef(char *fmt, ...);
#define ThreadNameF(...) (set_thread_namef(__VA_ARGS__))
#define ThreadName(str) (set_thread_name(str))
MD_API void set_thread_name(String8 string);
inline void
set_thread_namef(char *fmt, ...)
{
TempArena scratch = scratch_begin(0, 0);
va_list args;
va_start(args, fmt);
String8 string = push_str8fv(scratch.arena, fmt, args);
set_thread_name(string);
va_end(args);
scratch_end(scratch);
}
#define thread_namef(...) (set_thread_namef(__VA_ARGS__))
#define thraed_name(str) (set_thread_name(str))