blob: f511712362e35c21f824c3c61ab1de718c112099 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#if 0
internal Profile *x86_start_profile(Arena *arena, void (*callback)(), void *callback_arg)
{
ScratchArena scratch = scratch_start(arena);
Unused(scratch);
u64 start_high, start_low, end_high, end_low;
// GetCycles(start_high, start_low);
Profile *p = PushStruct(arena, Profile);
p->start = start_high - start_low;
// callback(arg);
// GetCycles(end_high, end_low);
p->end = end_high - end_low;
return p;
// do the logging inline
{
Log("log the profile or something");
}
scratch_end(&scratch);
}
#endif
|