Skip to content

Reduce size of MicroProfiler #2725

Open
@andresovela

Description

@andresovela

The MicroProfiler class has these buffers:

const char* tags_[kMaxEvents];
uint32_t start_ticks_[kMaxEvents];
uint32_t end_ticks_[kMaxEvents];

struct TicksPerTag {
  const char* tag;
  uint32_t ticks;
};

TicksPerTag total_ticks_per_tag[kMaxEvents];

We need 20 bytes per event, so an instance of MicroProfiler uses 80 KB of RAM, even if the model you're profiling has only a few nodes.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions