Re: [PATCH 2/2] hexdump: add a new dump prefix DUMP_PREFIX_ADDRESS_LOW16

From: Steven Rostedt
Date: Mon Aug 07 2023 - 21:14:22 EST


On Sat, 5 Aug 2023 15:21:16 +0800
thunder.leizhen@xxxxxxxxxxxxxxx wrote:

> For example:
> dump memory at sp=ffff800080883a90:
> ffff800080883a90: 80883ac0 ffff8000 3d8e936c ffffbd5b
> ffff800080883aa0: 5833f000 ffff3580 00000001 00000000
> ffff800080883ab0: 40299840 ffff3580 590dfa00 ffff3580
> ffff800080883ac0: 80883b30 ffff8000 3d938b28 ffffbd5b
> ffff800080883ad0: 40877180 ffff3580 590dfa00 ffff3580
> ffff800080883ae0: 4090f600 ffff3580 80883cb0 ffff8000
> ffff800080883af0: 00000010 00000000 00000000 00000000
> ffff800080883b00: 4090f700 ffff3580 00000001 00000000
>
> Generally, we do not dump more than 64 KB memory. It is sufficient to
> print only the lower 16 bits of the address.
>
> dump memory at sp=ffff800080883a90:
> 3a90: 80883ac0 ffff8000 3d8e936c ffffbd5b
> 3aa0: 5833f000 ffff3580 00000001 00000000
> 3ab0: 40299840 ffff3580 590dfa00 ffff3580
> 3ac0: 80883b30 ffff8000 3d938b28 ffffbd5b
> 3ad0: 40877180 ffff3580 590dfa00 ffff3580
> 3ae0: 4090f600 ffff3580 80883cb0 ffff8000
> 3af0: 00000010 00000000 00000000 00000000
> 3b00: 4090f700 ffff3580 00000001 00000000

I find the "before" much easier to read than the "after".


-- Steve