Re: [PATCH] tracing: Fix trace entry and trace common fields for preempt_lazy_count

Sebastian Andrzej Siewior
2020-02-21T16:37:38Z

On 2020-02-21 11:21:52 [-0500], Steven Rostedt wrote:
…
> struct trace_entry {
> unsigned short type;
> unsigned char flags;
> unsigned char preempt_count;
> int pid;
> unsigned short migrate_disable;
> unsigned short padding;
> unsigned char preempt_lazy_count;
> };
>
> Which adds a ton of bloat.
…
> Why is migrate disable a short? Is there going to be more that 256
> nesting?

I don't think so. We go now and then > 10 and the trace file shows only
one digit. So I think that migrate_disable can use a byte field
here.
So we make migrate_disable and preempt_lazy_count a `char' type and keep
the `short' padding later on?

> -- Steve

Sebastian